lkml.org 
[lkml]   [2020]   [Jul]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v3] mm, slab: Check GFP_SLAB_BUG_MASK before alloc_pages in kmalloc_order
On Wed, Jul 1, 2020 at 6:19 PM Long Li <lonuxli.64@gmail.com> wrote:
>
> kmalloc cannot allocate memory from HIGHMEM. Allocating large amounts
> of memory currently bypasses the check and will simply leak the memory
> when page_address() returns NULL. To fix this, factor the
> GFP_SLAB_BUG_MASK check out of slab & slub, and call it from
> kmalloc_order() as well. In order to make the code clear, the warning
> message is put in one place.
>
> Signed-off-by: Long Li <lonuxli.64@gmail.com>

Reviewed-by: Pekka Enberg <penberg@kernel.org>

\
 
 \ /
  Last update: 2020-07-01 17:48    [W:0.048 / U:0.520 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site