From: Wei Yongjun Date: Wed, 8 Jan 2014 10:13:14 +0000 (+0800) Subject: openvswitch: Use kmem_cache_free() instead of kfree() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ece37c87ab5aa65ad9c55d781c0f40092aeb49eb;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git openvswitch: Use kmem_cache_free() instead of kfree() memory allocated by kmem_cache_alloc() should be freed using kmem_cache_free(), not kfree(). Fixes: e298e5057006 ('openvswitch: Per cpu flow stats.') Signed-off-by: Wei Yongjun Acked-by: Jesse Gross Signed-off-by: David S. Miller --- diff --git a/net/openvswitch/flow_table.c b/net/openvswitch/flow_table.c index b430d42b2d0f..c58a0fe3c889 100644 --- a/net/openvswitch/flow_table.c +++ b/net/openvswitch/flow_table.c @@ -104,7 +104,7 @@ struct sw_flow *ovs_flow_alloc(bool percpu_stats) } return flow; err: - kfree(flow); + kmem_cache_free(flow_cache, flow); return ERR_PTR(-ENOMEM); }