All of lore.kernel.org
 help / color / mirror / Atom feed
* Question about LAYOUTRETURN stateid
@ 2010-10-12 11:09 P.B.Shelley
  2010-10-12 13:11 ` Fred Isaman
  0 siblings, 1 reply; 6+ messages in thread
From: P.B.Shelley @ 2010-10-12 11:09 UTC (permalink / raw)
  To: linux-nfs

Hi, all

While reading Linux pnfs code, I have a question in layoutreturn code path.

nfs4_layoutreturn_release() only invalidate layout stateid when
res.lrs_present is FALSE. If it is TRUE, client is supposed to set it
to res.stateid, is it? But I do not see somewhere the layout stateid
is updated. Am I missing something?

5683 static void nfs4_layoutreturn_release(void *calldata)
5684 {
5685         struct nfs4_layoutreturn *lrp = calldata;
5686         struct pnfs_layout_hdr *lo = NFS_I(lrp->args.inode)->layout;
5687
5688         dprintk("--> %s return_type %d lo %p\n", __func__,
5689                 lrp->args.return_type, lo);
5690
5691         if (lrp->args.return_type == RETURN_FILE) {
5692                 if (!lrp->res.lrs_present)
5693                         pnfs_invalidate_layout_stateid(lo);
5694                 pnfs_layoutreturn_release(lo, &lrp->args.range);
5695         }
5696         kfree(calldata);
5697         dprintk("<-- %s\n", __func__);
5698 }

-- 
Thanks,
Shelley

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2010-10-12 15:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-12 11:09 Question about LAYOUTRETURN stateid P.B.Shelley
2010-10-12 13:11 ` Fred Isaman
     [not found]   ` <AANLkTik6WBUJrSW5GY+i-iERxU-rMz5D0oWFa-n8HhH+-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-10-12 14:40     ` Benny Halevy
2010-10-12 15:29       ` William A. (Andy) Adamson
2010-10-12 15:38         ` Fred Isaman
     [not found]           ` <AANLkTinv9OZ1M9ykACYYavT57W69er_uTYXRiQA_aon9-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-10-12 15:41             ` William A. (Andy) Adamson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.