Commit 18598195 authored by David Howells's avatar David Howells

cachefiles: Use file_inode() rather than accessing ->f_inode

Use the file_inode() helper rather than accessing ->f_inode directly.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
Reviewed-by: default avatarJeff Layton <jlayton@redhat.com>
cc: linux-cachefs@redhat.com
Link: https://lore.kernel.org/r/162431192403.2908479.4590814090994846904.stgit@warthog.procyon.org.uk/
parent a7e20e31
...@@ -70,7 +70,7 @@ static int cachefiles_read(struct netfs_cache_resources *cres, ...@@ -70,7 +70,7 @@ static int cachefiles_read(struct netfs_cache_resources *cres,
_enter("%pD,%li,%llx,%zx/%llx", _enter("%pD,%li,%llx,%zx/%llx",
file, file_inode(file)->i_ino, start_pos, len, file, file_inode(file)->i_ino, start_pos, len,
i_size_read(file->f_inode)); i_size_read(file_inode(file)));
/* If the caller asked us to seek for data before doing the read, then /* If the caller asked us to seek for data before doing the read, then
* we should do that now. If we find a gap, we fill it with zeros. * we should do that now. If we find a gap, we fill it with zeros.
...@@ -194,7 +194,7 @@ static int cachefiles_write(struct netfs_cache_resources *cres, ...@@ -194,7 +194,7 @@ static int cachefiles_write(struct netfs_cache_resources *cres,
_enter("%pD,%li,%llx,%zx/%llx", _enter("%pD,%li,%llx,%zx/%llx",
file, file_inode(file)->i_ino, start_pos, len, file, file_inode(file)->i_ino, start_pos, len,
i_size_read(file->f_inode)); i_size_read(file_inode(file)));
ki = kzalloc(sizeof(struct cachefiles_kiocb), GFP_KERNEL); ki = kzalloc(sizeof(struct cachefiles_kiocb), GFP_KERNEL);
if (!ki) if (!ki)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment