[lkml]   [2019]   [Dec]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 3/3] kasan: don't assume percpu shadow allocations will succeed

On 12/5/19 5:04 PM, Daniel Axtens wrote:
> syzkaller and the fault injector showed that I was wrong to assume
> that we could ignore percpu shadow allocation failures.
> Handle failures properly. Merge all the allocated areas back into the free
> list and release the shadow, then clean up and return NULL. The shadow
> is released unconditionally, which relies upon the fact that the release
> function is able to tolerate pages not being present.
> Also clean up shadows in the recovery path - currently they are not
> released, which leaks a bit of memory.
> Fixes: 3c5c3cfb9ef4 ("kasan: support backing vmalloc space with real shadow memory")
> Reported-by:
> Reported-by:
> Cc: Dmitry Vyukov <>
> Cc: Andrey Ryabinin <>
> Signed-off-by: Daniel Axtens <>
> ---

Reviewed-by: Andrey Ryabinin <>

 \ /
  Last update: 2019-12-06 17:25    [W:0.137 / U:0.904 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site