mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-24 12:44:11 +08:00
hfsplus: atomically read inode size
See i_size_read() comments in include/linux/fs.h Link: http://lkml.kernel.org/r/20170123175338.3840-1-fabf@skynet.be Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
092a53452b
commit
a3f2235012
@ -132,7 +132,7 @@ static int hfsplus_get_last_session(struct super_block *sb,
|
||||
|
||||
/* default values */
|
||||
*start = 0;
|
||||
*size = sb->s_bdev->bd_inode->i_size >> 9;
|
||||
*size = i_size_read(sb->s_bdev->bd_inode) >> 9;
|
||||
|
||||
if (HFSPLUS_SB(sb)->session >= 0) {
|
||||
te.cdte_track = HFSPLUS_SB(sb)->session;
|
||||
|
Loading…
Reference in New Issue
Block a user