Commit 2696526a authored by Wei Yongjun's avatar Wei Yongjun Committed by Greg Kroah-Hartman

nfsd: use kmem_cache_free() instead of kfree()

commit 2c44a234 upstream.

memory allocated by kmem_cache_alloc() should be freed using
kmem_cache_free(), not kfree().
Signed-off-by: default avatarWei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: default avatarJ. Bruce Fields <bfields@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 69aa67b1
...@@ -261,7 +261,7 @@ kmem_cache *slab) ...@@ -261,7 +261,7 @@ kmem_cache *slab)
min_stateid = 0; min_stateid = 0;
return stid; return stid;
out_free: out_free:
kfree(stid); kmem_cache_free(slab, stid);
return NULL; return NULL;
} }
......
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