summaryrefslogtreecommitdiff
path: root/fs/ecryptfs/file.c
diff options
context:
space:
mode:
authorTyler Hicks <tyhicks@linux.vnet.ibm.com>2009-11-04 08:48:01 (GMT)
committerTyler Hicks <tyhicks@linux.vnet.ibm.com>2010-01-20 04:32:09 (GMT)
commitf8f484d1b6677dd5cd5e7e605db747e8c30bbd47 (patch)
tree67acfc58f5e952e4fd2720d2e5e77409db40b6b8 /fs/ecryptfs/file.c
parent5f3ef64f4da1c587cdcfaaac72311225b7df094c (diff)
downloadlinux-f8f484d1b6677dd5cd5e7e605db747e8c30bbd47.tar.xz
eCryptfs: Add getattr function
The i_blocks field of an eCryptfs inode cannot be trusted, but generic_fillattr() uses it to instantiate the blocks field of a stat() syscall when a filesystem doesn't implement its own getattr(). Users have noticed that the output of du is incorrect on newly created files. This patch creates ecryptfs_getattr() which calls into the lower filesystem's getattr() so that eCryptfs can use its kstat.blocks value after calling generic_fillattr(). It is important to note that the block count includes the eCryptfs metadata stored in the beginning of the lower file plus any padding used to fill an extent before encryption. https://bugs.launchpad.net/ecryptfs/+bug/390833 Reported-by: Dominic Sacré <dominic.sacre@gmx.de> Signed-off-by: Tyler Hicks <tyhicks@linux.vnet.ibm.com>
Diffstat (limited to 'fs/ecryptfs/file.c')
0 files changed, 0 insertions, 0 deletions