Message ID | 20241111111822.6795-1-frediano.ziglio@cloud.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | [v2] x86/boot: Setup correctly fs segment for bogus_real_magic | expand |
On 11.11.2024 12:18, Frediano Ziglio wrote: > --- a/xen/arch/x86/boot/wakeup.S > +++ b/xen/arch/x86/boot/wakeup.S > @@ -20,6 +20,8 @@ ENTRY(wakeup_start) > movw %ax, %ds > movw %ax, %ss # A stack required for BIOS call > movw $wakesym(wakeup_stack), %sp > + movw $0xb800, %ax > + movw %ax, %fs > > pushl $0 # Kill dangerous flag early > popfl If put here, I think it needs to be accompanied by a comment, to avoid it (wrongly) being deemed redundant again. Personally I would prefer if it was put where it's needed, at bogus_real_magic itself (at which point no commentary would be needed). Jan
diff --git a/xen/arch/x86/boot/wakeup.S b/xen/arch/x86/boot/wakeup.S index 08447e1934..99ac8594b8 100644 --- a/xen/arch/x86/boot/wakeup.S +++ b/xen/arch/x86/boot/wakeup.S @@ -20,6 +20,8 @@ ENTRY(wakeup_start) movw %ax, %ds movw %ax, %ss # A stack required for BIOS call movw $wakesym(wakeup_stack), %sp + movw $0xb800, %ax + movw %ax, %fs pushl $0 # Kill dangerous flag early popfl
bogus_real_magic code uses fs segment so it should be initialised. Fixes: d8c8fef09054 ("Provide basic Xen PM infrastructure") Signed-off-by: Frediano Ziglio <frediano.ziglio@cloud.com> --- Changes since v1: - added "Fixes" comment; - add initialisation, do not remove old one. --- xen/arch/x86/boot/wakeup.S | 2 ++ 1 file changed, 2 insertions(+)