Skip to content

Commit

Permalink
fs: 9p: remove unneeded variable
Browse files Browse the repository at this point in the history
Fix the following coccicheck review:
./fs/9p/vfs_file.c: 117: 5-8: Unneeded variable

Remove unneeded variable used to store return value.

Link: https://lkml.kernel.org/r/[email protected]
Reported-by: Zeal Robot <[email protected]>
Signed-off-by: Changcheng Deng <[email protected]>
Signed-off-by: Dominique Martinet <[email protected]>
  • Loading branch information
Changcheng Deng authored and martinetd committed Dec 18, 2021
1 parent f274566 commit 90d6cf3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions fs/9p/vfs_file.c
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ int v9fs_file_open(struct inode *inode, struct file *file)

static int v9fs_file_lock(struct file *filp, int cmd, struct file_lock *fl)
{
int res = 0;
struct inode *inode = file_inode(filp);

p9_debug(P9_DEBUG_VFS, "filp: %p lock: %p\n", filp, fl);
Expand All @@ -124,7 +123,7 @@ static int v9fs_file_lock(struct file *filp, int cmd, struct file_lock *fl)
invalidate_mapping_pages(&inode->i_data, 0, -1);
}

return res;
return 0;
}

static int v9fs_file_do_lock(struct file *filp, int cmd, struct file_lock *fl)
Expand Down

0 comments on commit 90d6cf3

Please sign in to comment.