Commit fbe5a6df authored by Alexey Dobriyan's avatar Alexey Dobriyan Committed by Juergen Gross

xen, pvh: fix unbootable VMs by inlining memset() in xen_prepare_pvh()

If this memset() is not inlined than PVH early boot code can call
into KASAN-instrumented memset() which results in unbootable VMs.
Signed-off-by: default avatarAlexey Dobriyan <adobriyan@gmail.com>
Acked-by: default avatarJuergen Gross <jgross@suse.com>
Message-ID: <20240802154253.482658-3-adobriyan@gmail.com>
Signed-off-by: default avatarJuergen Gross <jgross@suse.com>
parent 416a33c9
......@@ -130,7 +130,11 @@ void __init xen_prepare_pvh(void)
BUG();
}
memset(&pvh_bootparams, 0, sizeof(pvh_bootparams));
/*
* This must not compile to "call memset" because memset() may be
* instrumented.
*/
__builtin_memset(&pvh_bootparams, 0, sizeof(pvh_bootparams));
hypervisor_specific_init(xen_guest);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment