1. 14 7月, 2012 6 次提交
  2. 04 5月, 2012 1 次提交
    • I
      cifs - check S_AUTOMOUNT in revalidate · 936ad909
      Ian Kent 提交于
      When revalidating a dentry, if the inode wasn't known to be a dfs
      entry when the dentry was instantiated, such as when created via
      ->readdir(), the DCACHE_NEED_AUTOMOUNT flag needs to be set on the
      dentry in ->d_revalidate().
      
      The false return from cifs_d_revalidate(), due to the inode now
      being marked with the S_AUTOMOUNT flag, might not invalidate the
      dentry if there is a concurrent unlazy path walk. This is because
      the dentry reference count will be at least 2 in this case causing
      d_invalidate() to return EBUSY. So the asumption that the dentry
      will be discarded then correctly instantiated via ->lookup() might
      not hold.
      Signed-off-by: NIan Kent <raven@themaw.net>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Cc: Steve French <smfrench@gmail.com>
      Cc: linux-cifs@vger.kernel.org
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      936ad909
  3. 20 3月, 2012 1 次提交
  4. 27 2月, 2012 1 次提交
  5. 08 2月, 2012 1 次提交
  6. 04 1月, 2012 2 次提交
  7. 18 10月, 2011 1 次提交
  8. 13 10月, 2011 2 次提交
    • S
      cifs: Add mount options for backup intent (try #6) · 3d3ea8e6
      Shirish Pargaonkar 提交于
      Add mount options backupuid and backugid.
      
      It allows an authenticated user to access files with the intent to back them
      up including their ACLs, who may not have access permission but has
      "Backup files and directories user right" on them (by virtue of being part
      of the built-in group Backup Operators.
      
      When mount options backupuid is specified, cifs client restricts the
      use of backup intents to the user whose effective user id is specified
      along with the mount option.
      
      When mount options backupgid is specified, cifs client restricts the
      use of backup intents to the users whose effective user id belongs to the
      group id specified along with the mount option.
      
      If an authenticated user is not part of the built-in group Backup Operators
      at the server, access to such files is denied, even if allowed by the client.
      Signed-off-by: NShirish Pargaonkar <shirishpargaonkar@gmail.com>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSteve French <smfrench@gmail.com>
      3d3ea8e6
    • S
      add new module parameter 'enable_oplocks' · e7504734
      Steve French 提交于
      Thus spake Jeff Layton:
      
      "Making that a module parm would allow you to set that parameter at boot
      time without needing to add special startup scripts. IMO, all of the
      procfile "switches" under /proc/fs/cifs should be module parms
      instead."
      
      This patch doesn't alter the default behavior (Oplocks are enabled by
      default).
      
      To disable oplocks when loading the module, use
      
         modprobe cifs enable_oplocks=0
      
      (any of '0' or 'n' or 'N' conventions can be used).
      
      To disable oplocks at runtime using the new interface, use
      
         echo 0 > /sys/module/cifs/parameters/enable_oplocks
      
      The older /proc/fs/cifs/OplockEnabled interface will be deprecated
      after two releases. A subsequent patch will add an warning message
      about this deprecation.
      
      Changes since v2:
         - make enable_oplocks a 'bool'
      
      Changes since v1:
         - eliminate the use of extra variable by renaming the old one to
           enable_oplocks and make it an 'int' type.
      Reported-by: NAlexander Swen <alex@swen.nu>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSuresh Jayaraman <sjayaraman@suse.de>
      Signed-off-by: NSteve French <smfrench@gmail.com>
      e7504734
  9. 16 8月, 2011 1 次提交
    • J
      cifs: demote cERROR in build_path_from_dentry to cFYI · fa71f447
      Jeff Layton 提交于
      Running the cthon tests on a recent kernel caused this message to pop
      occasionally:
      
          CIFS VFS: did not end path lookup where expected namelen is 0
      
      Some added debugging showed that namelen and dfsplen were both 0 when
      this occurred. That means that the read_seqretry returned true.
      
      Assuming that the comment inside the if statement is true, this should
      be harmless and just means that we raced with a rename. If that is the
      case, then there's no need for alarm and we can demote this to cFYI.
      
      While we're at it, print the dfsplen too so that we can see what
      happened here if the message pops during debugging.
      
      Cc: stable@kernel.org
      Cc: Al Viro <viro@ZenIV.linux.org.uk>
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      fa71f447
  10. 26 7月, 2011 3 次提交
  11. 20 7月, 2011 3 次提交
  12. 17 7月, 2011 1 次提交
  13. 27 5月, 2011 3 次提交
  14. 31 3月, 2011 1 次提交
  15. 16 1月, 2011 1 次提交
  16. 13 1月, 2011 1 次提交
  17. 10 1月, 2011 2 次提交
  18. 07 1月, 2011 6 次提交
    • N
      fs: rcu-walk aware d_revalidate method · 34286d66
      Nick Piggin 提交于
      Require filesystems be aware of .d_revalidate being called in rcu-walk
      mode (nd->flags & LOOKUP_RCU). For now do a simple push down, returning
      -ECHILD from all implementations.
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      34286d66
    • N
      fs: dcache reduce branches in lookup path · fb045adb
      Nick Piggin 提交于
      Reduce some branches and memory accesses in dcache lookup by adding dentry
      flags to indicate common d_ops are set, rather than having to check them.
      This saves a pointer memory access (dentry->d_op) in common path lookup
      situations, and saves another pointer load and branch in cases where we
      have d_op but not the particular operation.
      
      Patched with:
      
      git grep -E '[.>]([[:space:]])*d_op([[:space:]])*=' | xargs sed -e 's/\([^\t ]*\)->d_op = \(.*\);/d_set_d_op(\1, \2);/' -e 's/\([^\t ]*\)\.d_op = \(.*\);/d_set_d_op(\&\1, \2);/' -i
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      fb045adb
    • N
      fs: change d_hash for rcu-walk · b1e6a015
      Nick Piggin 提交于
      Change d_hash so it may be called from lock-free RCU lookups. See similar
      patch for d_compare for details.
      
      For in-tree filesystems, this is just a mechanical change.
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      b1e6a015
    • N
      fs: change d_compare for rcu-walk · 621e155a
      Nick Piggin 提交于
      Change d_compare so it may be called from lock-free RCU lookups. This
      does put significant restrictions on what may be done from the callback,
      however there don't seem to have been any problems with in-tree fses.
      If some strange use case pops up that _really_ cannot cope with the
      rcu-walk rules, we can just add new rcu-unaware callbacks, which would
      cause name lookup to drop out of rcu-walk mode.
      
      For in-tree filesystems, this is just a mechanical change.
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      621e155a
    • N
      cifs: dont overwrite dentry name in d_revalidate · 79eb4dde
      Nick Piggin 提交于
      Use vfat's method for dealing with negative dentries to preserve case,
      rather than overwrite dentry name in d_revalidate, which is a bit ugly
      and also gets in the way of doing lock-free path walking.
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      79eb4dde
    • N
      cifs: don't overwrite dentry name in d_revalidate · 262f86ad
      Nick Piggin 提交于
      Instead, use fatfs's method for dealing with negative dentries to
      preserve case, rather than overwrite dentry name in d_revalidate, which
      is a bit ugly and also gets in the way of doing lock-free path walking.
      Signed-off-by: NNick Piggin <npiggin@kernel.dk>
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      262f86ad
  19. 18 10月, 2010 3 次提交