1. 07 2月, 2008 3 次提交
    • J
      fs/fat/: refine chmod checks · 19c561a6
      Jan Engelhardt 提交于
      Prohibit mode changes in non-quiet mode that cannot be stored reliably with
      the on-disk format.
      
      Suppose a vfat filesystem is mounted with umask=0 and [not-quiet].  Then
      all files will have mode 0777.  Trying to change the owner will fail,
      because fat does not know about owners or groups.  chmod 0770, on the other
      hand, will succeed, even though fat does not know about the permission
      triplet [user/group/other].
      
      So this patch changes fat's not-quiet behavior so that only UNIX modes are
      accepted that can be mapped lossless between the fat disk format and the
      local system.  There is only one attribute, and that is the readonly
      attribute, which is mapped to the UNIX write permission bit(s).  chmod 0555
      is therefore valid (taking away the +w bits <=> setting the readonly
      attribute).  Since chmod 0775 and chmod 0755 is an ambiguous case as to
      whether to set or clear the readonly bit, these modes are also denied.
      
      In quiet mode, chmod and chown will continue to "succeed" as they did
      before, meaning that a subsequent stat() will temporarily return the new
      mode as long as the inode is not reread from disk, and chown will silently
      do nothing, not even return the new uid/gid in stat().
      Signed-off-by: NJan Engelhardt <jengelh@computergmbh.de>
      Cc: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      19c561a6
    • A
      geode lists are subscriber only · 20292bc2
      Alan Cox 提交于
      This gave me bounces and moans when chasing CS5536 so document it.
      Signed-off-by: NAlan Cox <alan@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      20292bc2
    • A
      fix ! versus & precedence in various places · eaa0ff15
      Alexey Dobriyan 提交于
      Fix various instances of
      
      	if (!expr & mask)
      
      which should probably have been
      
      	if (!(expr & mask))
      Signed-off-by: NAlexey Dobriyan <adobriyan@gmail.com>
      Cc: Jens Axboe <jens.axboe@oracle.com>
      Cc: Peter Osterlund <petero2@telia.com>
      Cc: Karsten Keil <kkeil@suse.de>
      Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
      Cc: "Antonino A. Daplas" <adaplas@pol.net>
      Cc: Mark Fasheh <mark.fasheh@oracle.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Garzik <jeff@garzik.org>
      Cc: Al Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      eaa0ff15
  2. 06 2月, 2008 37 次提交