Skip to content

Commit be0c00f

Browse files
committed
Merge fix/9p-fid-refcounts/5.15 into v5.15.57
* commit '6bf7a2374418e370cabb63fcfb53fd1abd2939cd': net/9p: Initialize the iounit field during fid creation 9p: Fix refcounting during full path walks for fid lookups 9p: fix fid refcount leak in v9fs_vfs_get_link 9p: fix fid refcount leak in v9fs_vfs_atomic_open_dotl
2 parents 11a019c + 6bf7a23 commit be0c00f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

net/9p/client.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -897,16 +897,13 @@ static struct p9_fid *p9_fid_create(struct p9_client *clnt)
897897
struct p9_fid *fid;
898898

899899
p9_debug(P9_DEBUG_FID, "clnt %p\n", clnt);
900-
fid = kmalloc(sizeof(struct p9_fid), GFP_KERNEL);
900+
fid = kzalloc(sizeof(struct p9_fid), GFP_KERNEL);
901901
if (!fid)
902902
return NULL;
903903

904-
memset(&fid->qid, 0, sizeof(struct p9_qid));
905904
fid->mode = -1;
906905
fid->uid = current_fsuid();
907906
fid->clnt = clnt;
908-
fid->rdir = NULL;
909-
fid->fid = 0;
910907
refcount_set(&fid->count, 1);
911908

912909
idr_preload(GFP_KERNEL);

0 commit comments

Comments
 (0)