Skip to content
This repository was archived by the owner on Nov 8, 2023. It is now read-only.

Commit 10211b4

Browse files
ColinIanKingericvh
authored andcommitted
fs/9p: remove redundant pointer v9ses
Pointer v9ses is being assigned the value from the return of inlined function v9fs_inode2v9ses (which just returns inode->i_sb->s_fs_info). The pointer is not used after the assignment, so the variable is redundant and can be removed. Cleans up clang scan warnings such as: fs/9p/vfs_inode_dotl.c:300:28: warning: variable 'v9ses' set but not used [-Wunused-but-set-variable] Signed-off-by: Colin Ian King <colin.i.king@gmail.com> Reviewed-by: Dominique Martinet <asmadeus@codewreck.org> Signed-off-by: Eric Van Hensbergen <ericvh@kernel.org>
1 parent 11763a8 commit 10211b4

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

fs/9p/vfs_inode_dotl.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,6 @@ static int v9fs_vfs_mkdir_dotl(struct mnt_idmap *idmap,
297297
umode_t omode)
298298
{
299299
int err;
300-
struct v9fs_session_info *v9ses;
301300
struct p9_fid *fid = NULL, *dfid = NULL;
302301
kgid_t gid;
303302
const unsigned char *name;
@@ -307,7 +306,6 @@ static int v9fs_vfs_mkdir_dotl(struct mnt_idmap *idmap,
307306
struct posix_acl *dacl = NULL, *pacl = NULL;
308307

309308
p9_debug(P9_DEBUG_VFS, "name %pd\n", dentry);
310-
v9ses = v9fs_inode2v9ses(dir);
311309

312310
omode |= S_IFDIR;
313311
if (dir->i_mode & S_ISGID)
@@ -739,7 +737,6 @@ v9fs_vfs_mknod_dotl(struct mnt_idmap *idmap, struct inode *dir,
739737
kgid_t gid;
740738
const unsigned char *name;
741739
umode_t mode;
742-
struct v9fs_session_info *v9ses;
743740
struct p9_fid *fid = NULL, *dfid = NULL;
744741
struct inode *inode;
745742
struct p9_qid qid;
@@ -749,7 +746,6 @@ v9fs_vfs_mknod_dotl(struct mnt_idmap *idmap, struct inode *dir,
749746
dir->i_ino, dentry, omode,
750747
MAJOR(rdev), MINOR(rdev));
751748

752-
v9ses = v9fs_inode2v9ses(dir);
753749
dfid = v9fs_parent_fid(dentry);
754750
if (IS_ERR(dfid)) {
755751
err = PTR_ERR(dfid);

0 commit comments

Comments
 (0)