summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorWeston Andros Adamson <dros@monkey.org>2017-08-01 23:25:01 +0300
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2017-08-09 00:18:10 +0300
commit1feb26162bee7b2f110facfec71b5c7bdbc7d14d (patch)
tree641e11300f9ee4d77c50b7ddd231c390183f7f87 /fs
parentd9cb73300ac0001832c048a489c592263fc28193 (diff)
downloadlinux-1feb26162bee7b2f110facfec71b5c7bdbc7d14d.tar.xz
nfs/flexfiles: fix leak of nfs4_ff_ds_version arrays
The client was freeing the nfs4_ff_layout_ds, but not the contained nfs4_ff_ds_version array. Signed-off-by: Weston Andros Adamson <dros@primarydata.com> Cc: stable@vger.kernel.org # v4.0+ Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfs/flexfilelayout/flexfilelayoutdev.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/nfs/flexfilelayout/flexfilelayoutdev.c b/fs/nfs/flexfilelayout/flexfilelayoutdev.c
index 6df7a0cf5660..f32c58bbe556 100644
--- a/fs/nfs/flexfilelayout/flexfilelayoutdev.c
+++ b/fs/nfs/flexfilelayout/flexfilelayoutdev.c
@@ -32,6 +32,7 @@ void nfs4_ff_layout_free_deviceid(struct nfs4_ff_layout_ds *mirror_ds)
{
nfs4_print_deviceid(&mirror_ds->id_node.deviceid);
nfs4_pnfs_ds_put(mirror_ds->ds);
+ kfree(mirror_ds->ds_versions);
kfree_rcu(mirror_ds, id_node.rcu);
}