提交 200f1ce3 编写于 作者: P Pekka Enberg 提交者: Linus Torvalds

kernel/relay.c: use kvfree() in relay_free_page_array()

Use kvfree() instead of open-coding it.
Signed-off-by: NPekka Enberg <penberg@kernel.org>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 b389645f
...@@ -81,10 +81,7 @@ static struct page **relay_alloc_page_array(unsigned int n_pages) ...@@ -81,10 +81,7 @@ static struct page **relay_alloc_page_array(unsigned int n_pages)
*/ */
static void relay_free_page_array(struct page **array) static void relay_free_page_array(struct page **array)
{ {
if (is_vmalloc_addr(array)) kvfree(array);
vfree(array);
else
kfree(array);
} }
/** /**
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册