From: Jason Andryuk Date: Wed, 24 Jun 2020 14:25:13 +0000 (-0400) Subject: serialio: Preserve Xen DebugOutputPort X-Git-Tag: rel-1.14.0~7 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=dd6a7e99b1c32ca66048673442cc7152efd08d2d;p=seabios.git serialio: Preserve Xen DebugOutputPort xen_preinit() runs early and changes DebugOutputPort. qemu_preinit() runs soon after. inb on DebugOutputPort doesn't work on Xen, so the check will always fail and DebugOutputPort will be cleared to 0 disabling output. Quick exit the function when running on Xen to preserve the modified DebugOutputPort. Signed-off-by: Jason Andryuk --- diff --git a/src/hw/serialio.c b/src/hw/serialio.c index 3163344..fa663b9 100644 --- a/src/hw/serialio.c +++ b/src/hw/serialio.c @@ -106,6 +106,10 @@ u16 DebugOutputPort VARFSEG = 0x402; void qemu_debug_preinit(void) { + /* Xen doesn't support checking if debug output is active. */ + if (runningOnXen()) + return; + /* Check if the QEMU debug output port is active */ if (CONFIG_DEBUG_IO && inb(GET_GLOBAL(DebugOutputPort)) != QEMU_DEBUGCON_READBACK)