ldlinux: Fix serial output and delete eprintf()
commit75e2b7c282fc3b5c4f5314717f1b224f489b507e
authorMatt Fleming <matt.fleming@intel.com>
Thu, 24 Jan 2013 16:47:44 +0000 (24 16:47 +0000)
committerMatt Fleming <matt.fleming@intel.com>
Thu, 24 Jan 2013 17:22:45 +0000 (24 17:22 +0000)
tree5f428f170ced2ae70395ce0eedba510b24e23a63
parent40a6839c9ed17518e5984f4ea3e5530cbcfeb4c3
ldlinux: Fix serial output and delete eprintf()

Tagging __syslinux_get_serial_info() with __constructor is pretty
useless when the global variables it uses, such as SerialPort, etc,
are assigned *after* the constructor has run. This constructor made
sense when config parsing was done by the core, but parsing is now
performed by ldlinux. We need to explicitly invoke the function to
initialise __syslinux_serial_console_info once we've parsed any config
files.

eprintf.c was introduced in commit 086d698c642f ("ldlinux: Add
eprintf() to print to VGA and serial") because printf() output wasn't
appearing on the serial console. It turns out that the above
__constructor confusion was the real bug.

Signed-off-by: Matt Fleming <matt.fleming@intel.com>
com32/elflink/ldlinux/Makefile
com32/elflink/ldlinux/cli.c
com32/elflink/ldlinux/config.h
com32/elflink/ldlinux/eprintf.c [deleted file]
com32/elflink/ldlinux/ldlinux.c
com32/elflink/ldlinux/msg.c
com32/elflink/ldlinux/readconfig.c
com32/include/syslinux/config.h
com32/lib/syslinux/serial.c
core/conio.c