Subject: [nfsv4] LAYOUTRRETURN and current stateid

From: "Mike Eisler" <[email-masked]>
Date: Wed, 30 Apr 2008 16:34:43 -0700 (PDT)

If the operation specified lr_returntype of LAYOUTRETURN4_FILE, then
  lrs_stateid will represent the layout stateid as updated for this
  operation's processing; the current stateid will also be updated to
  match the returned value.  If the last byte of any layout for the
  current file, client ID, and layout type is being returned and there
  are no remaining pending CB_LAYOUTRECALL operations for which a
  LAYOUTRETURN operation must be done as a completing operation,
  lrs_present MUST be FALSE, and thus no stateid will be returned.

Unless there are objections, I will add to the last sentence of the above
paragraph:

  and the current stateid will be cleared.

-- 
Mike Eisler, Senior Technical Director, NetApp, 719 599 9026,
http://blogs.netapp.com/eislers_nfs_blog/

_______________________________________________
nfsv4 mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/nfsv4

---

From: Benny Halevy <[email-masked]>
Date: Thu, 01 May 2008 09:21:09 +0300

>   and the current stateid will be cleared.

I understand where this is coming from but the wording
is a bit terse IMO. By "current stateid" you mean the
COMPOUND RPC's current stateid, right?
Now, what does "clear" mean?
Set to zero, become invalid?
I think it should be invalidated such that any further
use of the current stateid in that COMPOUND will result in 
NFS4ERR_BAD_STATEID (as required by section 8.2.3, third bullet
point).

Therefore, I suggest this instead:

	and the RPC's current stateid will be invalidated.
	The server MUST reject any further use of the current
	stateid in that COMPOUND with NFS4ERR_BAD_STATEID
	Any further use of the current stateid in that COMPOUND
	until the current stateid is re-established by another
	stateid-returning operation.

Benny