On Wed, 16 Apr 2014 14:15:56 -0700 Andrew Morton
wrote:
> @@ -201,7 +201,9 @@ void * mempool_alloc(mempool_t *pool, gf
> wait_queue_t wait;
> gfp_t gfp_temp;
>
> - VM_BUG_ON(gfp_mask & __GFP_ZERO);
> +#ifdef CONFIG_DEBUG_VM
> + WARN_ON_ONCE(gfp_mask & __GFP_ZERO);/* Whe
On Mon, 14 Apr 2014 19:23:34 +0200 (CEST) Sebastian Ott
wrote:
> Memory obtained via mempool_alloc is not always zeroed even when
> called with __GFP_ZERO. Add a note and VM_BUG_ON statement to make
> that clear.
>
> ..
>
> @@ -200,6 +201,7 @@ void * mempool_alloc(mempool_t *pool, gf
> wa
Hello,
I recently found out the hard way, that using mempool_alloc together with
__GFP_ZERO is not a good idea since memory which comes from the pool of
preallocated elemtents is not zeroed. Fixing this doesn't seem to be trivial
since mempool is not aware of the size of the objects it manages.
L
3 matches
Mail list logo