aboutsummaryrefslogtreecommitdiffstats
path: root/com32/elflink/ldlinux
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2013-05-29 15:01:12 +0100
committerMatt Fleming <matt.fleming@intel.com>2013-05-29 15:27:28 +0100
commit4e682dcc05b0911365aa92c4f848daf013d3a635 (patch)
tree6ade4155e5dfbe7848b4a59aa25a6950d318882f /com32/elflink/ldlinux
parent5c04bb1ad89553c1541a527bf105a86e3a31e1a5 (diff)
downloadsyslinux-4e682dcc05b0911365aa92c4f848daf013d3a635.tar.gz
syslinux-4e682dcc05b0911365aa92c4f848daf013d3a635.tar.xz
syslinux-4e682dcc05b0911365aa92c4f848daf013d3a635.zip
serial: fix SERIAL directive for ports > 0
There is a bug in the SERIAL directive parsing code that means that using a port other than the first (SERIAL 0) results in a non-working serial console. We need to use the serial port number from the config file to offset the BIOS I/O port base address, otherwise we always lookup the I/O port address for the first serial port instead of the one the user specified. Signed-off-by: Matt Fleming <matt.fleming@intel.com>
Diffstat (limited to 'com32/elflink/ldlinux')
-rw-r--r--com32/elflink/ldlinux/readconfig.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/com32/elflink/ldlinux/readconfig.c b/com32/elflink/ldlinux/readconfig.c
index 9d50c2f3..7ac216b0 100644
--- a/com32/elflink/ldlinux/readconfig.c
+++ b/com32/elflink/ldlinux/readconfig.c
@@ -1286,7 +1286,7 @@ do_include:
if (port <= 3) {
/* Get the I/O port from the BIOS */
port <<= 1;
- port = *(volatile uint16_t *)serial_base;
+ port = *(volatile uint16_t *)(serial_base + port);
}