]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - fs/fat/file.c
fat: Fix ATTR_RO for directory
authorOGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Thu, 6 Nov 2008 20:53:55 +0000 (12:53 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 6 Nov 2008 23:41:21 +0000 (15:41 -0800)
commitdfc209c0064efef5590f608056a48b61a5cac09c
tree1ace2df7370944dd94b3c8f6a53acf6ea76fdd79
parent9183482f5d4a2de00f66641b974e7f351d41b675
fat: Fix ATTR_RO for directory

FAT has the ATTR_RO (read-only) attribute. But on Windows, the ATTR_RO
of the directory will be just ignored actually, and is used by only
applications as flag. E.g. it's setted for the customized folder by
Explorer.

http://msdn2.microsoft.com/en-us/library/aa969337.aspx

This adds "rodir" option. If user specified it, ATTR_RO is used as
read-only flag even if it's the directory. Otherwise, inode->i_mode
is not used to hold ATTR_RO (i.e. fat_mode_can_save_ro() returns 0).

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Documentation/filesystems/vfat.txt
fs/fat/fat.h
fs/fat/file.c
fs/fat/inode.c