x86/S3: put data segment registers into known state upon resume
authorJan Beulich <jbeulich@suse.com>
Fri, 7 Aug 2020 15:09:19 +0000 (17:09 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 7 Aug 2020 15:09:19 +0000 (17:09 +0200)
commitb8c3e33a4fe4374f633b4369200731662ff1f750
treee5834d87de1b14194aff9279f0258bda4be65b50
parentf836759a7bbf095dc5b1f31a069296bcfd694b82
x86/S3: put data segment registers into known state upon resume

wakeup_32 sets %ds and %es to BOOT_DS, while leaving %fs at what
wakeup_start did set it to, and %gs at whatever BIOS did load into it.
All of this may end up confusing the first load_segments() to run on
the BSP after resume, in particular allowing a non-nul selector value
to be left in %fs.

Alongside %ss, also put all other data segment registers into the same
state that the boot and CPU bringup paths put them in.

Reported-by: M. Vefa Bicakci <m.v.b@runbox.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
master commit: 55f8c389d4348cc517946fdcb10794112458e81e
master date: 2020-07-24 10:17:26 +0200
xen/arch/x86/acpi/wakeup_prot.S