提交 0f24b79b 编写于 作者: P Pekka Enberg 提交者: Mike Snitzer

dm stats: Use kvfree() in dm_kvfree()

Use kvfree() instead of open-coding it.
Signed-off-by: NPekka Enberg <penberg@kernel.org>
Signed-off-by: NMike Snitzer <snitzer@redhat.com>
上级 fba10109
...@@ -160,10 +160,7 @@ static void dm_kvfree(void *ptr, size_t alloc_size) ...@@ -160,10 +160,7 @@ static void dm_kvfree(void *ptr, size_t alloc_size)
free_shared_memory(alloc_size); free_shared_memory(alloc_size);
if (is_vmalloc_addr(ptr)) kvfree(ptr);
vfree(ptr);
else
kfree(ptr);
} }
static void dm_stat_free(struct rcu_head *head) static void dm_stat_free(struct rcu_head *head)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册