aboutsummaryrefslogtreecommitdiffstats
path: root/lib/mpi/longlong.h
diff options
context:
space:
mode:
authorVitaly Wool <[email protected]>2019-07-16 23:25:48 +0000
committerLinus Torvalds <[email protected]>2019-07-17 02:23:21 +0000
commitbb9a374dfa3a2f46581455ab66cd1d24c5e3d183 (patch)
tree654cb71efb841e60b08a23e1f85899eefb1f9e9c /lib/mpi/longlong.h
parentMerge tag 'backlight-next-5.3' of git://git.kernel.org/pub/scm/linux/kernel/g... (diff)
downloadkernel-bb9a374dfa3a2f46581455ab66cd1d24c5e3d183.tar.gz
kernel-bb9a374dfa3a2f46581455ab66cd1d24c5e3d183.zip
mm/z3fold: don't try to use buddy slots after free
As reported by Henry Burns: Running z3fold stress testing with address sanitization showed zhdr->slots was being used after it was freed. z3fold_free(z3fold_pool, handle) free_handle(handle) kmem_cache_free(pool->c_handle, zhdr->slots) release_z3fold_page_locked_list(kref) __release_z3fold_page(zhdr, true) zhdr_to_pool(zhdr) slots_to_pool(zhdr->slots) *BOOM* To fix this, add pointer to the pool back to z3fold_header and modify zhdr_to_pool to return zhdr->pool. Link: http://lkml.kernel.org/r/[email protected] Fixes: 7c2b8baa61fe ("mm/z3fold.c: add structure for buddy handles") Signed-off-by: Vitaly Wool <[email protected]> Reported-by: Henry Burns <[email protected]> Reviewed-by: Shakeel Butt <[email protected]> Cc: Jonathan Adams <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'lib/mpi/longlong.h')
0 files changed, 0 insertions, 0 deletions