aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/mlx4/alias_GUID.c
diff options
context:
space:
mode:
authorDave Young <[email protected]>2018-12-28 01:12:47 +0000
committerBorislav Petkov <[email protected]>2019-01-15 11:12:50 +0000
commit993a110319a4a60aadbd02f6defdebe048f7773b (patch)
tree78b869e89c2972f7304a87f676e3fc8486cdf9d1 /drivers/infiniband/hw/mlx4/alias_GUID.c
parentx86/mm/mem_encrypt: Fix erroneous sizeof() (diff)
downloadkernel-993a110319a4a60aadbd02f6defdebe048f7773b.tar.gz
kernel-993a110319a4a60aadbd02f6defdebe048f7773b.zip
x86/kexec: Fix a kexec_file_load() failure
Commit b6664ba42f14 ("s390, kexec_file: drop arch_kexec_mem_walk()") changed the behavior of kexec_locate_mem_hole(): it will try to allocate free memory only when kbuf.mem is initialized to zero. However, x86's kexec_file_load() implementation reuses a struct kexec_buf allocated on the stack and its kbuf.mem member gets set by each kexec_add_buffer() invocation. The second kexec_add_buffer() will reuse the same kbuf but not reinitialize kbuf.mem. Therefore, explictily reset kbuf.mem each time in order for kexec_locate_mem_hole() to locate a free memory region each time. [ bp: massage commit message. ] Fixes: b6664ba42f14 ("s390, kexec_file: drop arch_kexec_mem_walk()") Signed-off-by: Dave Young <[email protected]> Signed-off-by: Borislav Petkov <[email protected]> Acked-by: Baoquan He <[email protected]> Cc: "Eric W. Biederman" <[email protected]> Cc: "H. Peter Anvin" <[email protected]> Cc: AKASHI Takahiro <[email protected]> Cc: Andrew Morton <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Martin Schwidefsky <[email protected]> Cc: Philipp Rudo <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Vivek Goyal <[email protected]> Cc: Yannik Sembritzki <[email protected]> Cc: Yi Wang <[email protected]> Cc: [email protected] Cc: x86-ml <[email protected]> Link: https://lkml.kernel.org/r/[email protected]
Diffstat (limited to 'drivers/infiniband/hw/mlx4/alias_GUID.c')
0 files changed, 0 insertions, 0 deletions