1. 31 5月, 2014 2 次提交
    • J
      nfsd4: remove redundant encode buffer size checking · ea8d7720
      J. Bruce Fields 提交于
      Now that all op encoders can handle running out of space, we no longer
      need to check the remaining size for every operation; only nonidempotent
      operations need that check, and that can be done by
      nfsd4_check_resp_size.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      ea8d7720
    • J
      nfsd4: teach encoders to handle reserve_space failures · d0a381dd
      J. Bruce Fields 提交于
      We've tried to prevent running out of space with COMPOUND_SLACK_SPACE
      and special checking in those operations (getattr) whose result can vary
      enormously.
      
      However:
      	- COMPOUND_SLACK_SPACE may be difficult to maintain as we add
      	  more protocol.
      	- BUG_ON or page faulting on failure seems overly fragile.
      	- Especially in the 4.1 case, we prefer not to fail compounds
      	  just because the returned result came *close* to session
      	  limits.  (Though perfect enforcement here may be difficult.)
      	- I'd prefer encoding to be uniform for all encoders instead of
      	  having special exceptions for encoders containing, for
      	  example, attributes.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      d0a381dd
  2. 29 5月, 2014 3 次提交
  3. 27 5月, 2014 1 次提交
  4. 23 5月, 2014 8 次提交
  5. 07 5月, 2014 1 次提交
  6. 30 3月, 2014 1 次提交
    • K
      NFSD: Clear wcc data between compound ops · 2336745e
      Kinglong Mee 提交于
      Testing NFS4.0 by pynfs, I got some messeages as,
      "nfsd: inode locked twice during operation."
      
      When one compound RPC contains two or more ops that locks
      the filehandle,the second op will cause the message.
      
      As two SETATTR ops, after the first SETATTR, nfsd will not call
      fh_put() to release current filehandle, it means filehandle have
      unlocked with fh_post_saved = 1.
      The second SETATTR find fh_post_saved = 1, and printk the message.
      
      v2: introduce helper fh_clear_wcc().
      Signed-off-by: NKinglong Mee <kinglongmee@gmail.com>
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      2336745e
  7. 29 3月, 2014 2 次提交
  8. 28 3月, 2014 1 次提交
  9. 28 1月, 2014 2 次提交
  10. 26 1月, 2014 1 次提交
  11. 08 1月, 2014 1 次提交
  12. 04 1月, 2014 1 次提交
  13. 03 1月, 2014 1 次提交
  14. 08 8月, 2013 1 次提交
  15. 13 7月, 2013 1 次提交
    • J
      nfsd4: fix minorversion support interface · 35f7a14f
      J. Bruce Fields 提交于
      You can turn on or off support for minorversions using e.g.
      
      	echo "-4.2" >/proc/fs/nfsd/versions
      
      However, the current implementation is a little wonky.  For example, the
      above will turn off 4.2 support, but it will also turn *on* 4.1 support.
      
      This didn't matter as long as we only had 2 minorversions, which was
      true till very recently.
      
      And do a little cleanup here.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      35f7a14f
  16. 02 7月, 2013 1 次提交
  17. 15 5月, 2013 1 次提交
  18. 04 5月, 2013 1 次提交
  19. 01 5月, 2013 1 次提交
    • J
      nfsd4: don't remap EISDIR errors in rename · 2a6cf944
      J. Bruce Fields 提交于
      We're going out of our way here to remap an error to make rfc 3530
      happy--but the rfc itself (nor rfc 1813, which has similar language)
      gives no justification.  And disagrees with local filesystem behavior,
      with Linux and posix man pages, and knfsd's implemented behavior for v2
      and v3.
      
      And the documented behavior seems better, in that it gives a little more
      information--you could implement the 3530 behavior using the posix
      behavior, but not the other way around.
      
      Also, the Linux client makes no attempt to remap this error in the v4
      case, so it can end up just returning EEXIST to the application in a
      case where it should return EISDIR.
      
      So honestly I think the rfc's are just buggy here--or in any case it
      doesn't see worth the trouble to remap this error.
      Reported-by: NFrank S Filz <ffilz@us.ibm.com>
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      2a6cf944
  20. 09 4月, 2013 2 次提交
  21. 08 4月, 2013 1 次提交
    • J
      nfsd4: cleanup handling of nfsv4.0 closed stateid's · 9411b1d4
      J. Bruce Fields 提交于
      Closed stateid's are kept around a little while to handle close replays
      in the 4.0 case.  So we stash them in the last-used stateid in the
      oo_last_closed_stateid field of the open owner.  We can free that in
      encode_seqid_op_tail once the seqid on the open owner is next
      incremented.  But we don't want to do that on the close itself; so we
      set NFS4_OO_PURGE_CLOSE flag set on the open owner, skip freeing it the
      first time through encode_seqid_op_tail, then when we see that flag set
      next time we free it.
      
      This is unnecessarily baroque.
      
      Instead, just move the logic that increments the seqid out of the xdr
      code and into the operation code itself.
      
      The justification given for the current placement is that we need to
      wait till the last minute to be sure we know whether the status is a
      sequence-id-mutating error or not, but examination of the code shows
      that can't actually happen.
      Reported-by: NYanchuan Nian <ycnian@gmail.com>
      Tested-by: NYanchuan Nian <ycnian@gmail.com>
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      9411b1d4
  22. 04 4月, 2013 1 次提交
  23. 03 4月, 2013 2 次提交
  24. 24 1月, 2013 1 次提交
  25. 18 12月, 2012 2 次提交