mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-26 07:10:51 +07:00
893f38d144
Jens found the following crash/regression:
[ 0.000000] found SMP MP-table at [ffff8800000fdd80] fdd80
[ 0.000000] Kernel panic - not syncing: Overlapping early reservations 12-f011 MP-table mpc to 0-fff BIOS data page
and
[ 0.000000] Kernel panic - not syncing: Overlapping early reservations 12-f011 MP-table mpc to 6000-7fff TRAMPOLINE
and bisected it to b24c2a9
("x86: Move find_smp_config()
earlier and avoid bootmem usage").
It turns out the BIOS is using the first 64k for mptable,
without reserving it.
So try to find good range for the real-mode trampoline instead of
hard coding it, in case some bios tries to use that range for sth.
Reported-by: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Tested-by: Jens Axboe <jens.axboe@oracle.com>
Cc: Randy Dunlap <randy.dunlap@oracle.com>
LKML-Reference: <4B21630A.6000308@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
29 lines
728 B
C
29 lines
728 B
C
#ifndef _ASM_X86_TRAMPOLINE_H
|
|
#define _ASM_X86_TRAMPOLINE_H
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
#ifdef CONFIG_X86_TRAMPOLINE
|
|
/*
|
|
* Trampoline 80x86 program as an array.
|
|
*/
|
|
extern const unsigned char trampoline_data [];
|
|
extern const unsigned char trampoline_end [];
|
|
extern unsigned char *trampoline_base;
|
|
|
|
extern unsigned long init_rsp;
|
|
extern unsigned long initial_code;
|
|
extern unsigned long initial_gs;
|
|
|
|
#define TRAMPOLINE_SIZE roundup(trampoline_end - trampoline_data, PAGE_SIZE)
|
|
|
|
extern unsigned long setup_trampoline(void);
|
|
extern void __init reserve_trampoline_memory(void);
|
|
#else
|
|
static inline void reserve_trampoline_memory(void) {};
|
|
#endif /* CONFIG_X86_TRAMPOLINE */
|
|
|
|
#endif /* __ASSEMBLY__ */
|
|
|
|
#endif /* _ASM_X86_TRAMPOLINE_H */
|