diff options
author | Jan Kara <jack@suse.cz> | 2014-09-04 10:26:19 -0400 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2014-09-04 15:37:40 -0400 |
commit | 470cca56c366428d4d5785a0a5a291619c332c7f (patch) | |
tree | 5b534bf2084b6021fcfb96fb92ec923bbd67442c /fs/udf/inode.c | |
parent | 4071b913622316970d0e1919f7d82b4403fec5f2 (diff) |
udf: Set i_generation field
Currently UDF doesn't initialize i_generation in any way and thus NFS
can easily get reallocated inodes from stale file handles. Luckily UDF
already has a unique object identifier associated with each inode -
i_unique. Use that for initialization of i_generation.
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/udf/inode.c')
-rw-r--r-- | fs/udf/inode.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/udf/inode.c b/fs/udf/inode.c index 3a44d9187aad..08598843288f 100644 --- a/fs/udf/inode.c +++ b/fs/udf/inode.c | |||
@@ -1484,6 +1484,7 @@ reread: | |||
1484 | iinfo->i_lenAlloc = le32_to_cpu(efe->lengthAllocDescs); | 1484 | iinfo->i_lenAlloc = le32_to_cpu(efe->lengthAllocDescs); |
1485 | iinfo->i_checkpoint = le32_to_cpu(efe->checkpoint); | 1485 | iinfo->i_checkpoint = le32_to_cpu(efe->checkpoint); |
1486 | } | 1486 | } |
1487 | inode->i_generation = iinfo->i_unique; | ||
1487 | 1488 | ||
1488 | switch (fe->icbTag.fileType) { | 1489 | switch (fe->icbTag.fileType) { |
1489 | case ICBTAG_FILE_TYPE_DIRECTORY: | 1490 | case ICBTAG_FILE_TYPE_DIRECTORY: |