bitkeeper revision 1.458 (3f6f7435Or79x1vh5ypTVbN9G7OJUg)

config.h, xen_serial.c, kernel.c, README.CD:
  Allow serial I/O to be entirely disabled, and make this teh default. Enable by specifying a ser_baud during boot.
This commit is contained in:
kaf24@scramble.cl.cam.ac.uk committed 2003-09-22 22:14:13 +00:00
1 parent 3c64421304
commit 4cbc390bba
4 files changed
+32 -18

No files matched your search

+16 -16
View File
@@ -45,13 +45,12 @@ Because of the demo CD's use of RAM disks, make sure you have plenty
of RAM (256MB+).
To try out the Demo, boot from CD (you may need to change your BIOS
configuration to do this), hit a key on either the keyboard or serial
line to pull up the Grub boot menu, then select one of the four boot
options:
configuration to do this), then select one of the four boot options
from the Grub menu:
Xen / linux-2.4.22
Xen / linux-2.4.22 using cmdline IP configuration
Xen ? linux-2.4.22 in "safe mode"
Xen / linux-2.4.22 in "safe mode"
linux-2.4.22
The last option is a plain linux kernel that runs on the bare machine,
@@ -77,9 +76,9 @@ sequentially for subsequent domains unless told otherwise.
After selecting the kernel to boot, stand back and watch Xen boot,
closely followed by "domain 0" running the XenoLinux kernel. The boot
messages are also sent to the serial line (the baud rate can be set on
the Xen cmdline, but defaults to 115200), which can be very useful for
debugging should anything important scroll off the screen. Xen's
messages can also sent to the serial line by specifying the baud rate
on the Xen cmdline (e.g., 'ser_baud=9600'); this can be very useful
for debugging should anything important scroll off the screen. Xen's
startup messages will look quite familiar as much of the hardware
initialisation (SMP boot, apic setup) and device drivers are derived
from Linux.
@@ -284,7 +283,7 @@ that may be able to help diagnose problems:
ifname=dummy Don't use any network interface.
ser_baud=xxx Set serial line baud rate for console.
ser_baud=xxx Enable serial I/O and set the baud rate.
dom0_mem=xxx Set the initial amount of memory for domain0.
@@ -358,12 +357,12 @@ title Xen / XenoLinux 2.4.22
module /boot/xenolinux.gz root=/dev/sda4 ro console=tty0
The first line specifies which Xen image to use, and what command line
arguments to pass to Xen. In this case, we set the maximum amount of
memory to allocate to domain0, and the serial baud rate (the default
is 9600 baud). We could also disable smp support (nosmp) or disable
hyper-threading support (noht). If you have multiple network interface
you can use ifname=ethXX to select which one to use. If your network
card is unsupported, use ifname=dummy
arguments to pass to Xen. In this case we set the maximum amount of
memory to allocate to domain0, and enable serial I/O at 9600 baud.
We could also disable smp support (nosmp) or disable hyper-threading
support (noht). If you have multiple network interface you can use
ifname=ethXX to select which one to use. If your network card is
unsupported, use ifname=dummy
The second line specifies which xenolinux image to use, and the
standard linux command line arguments to pass to the kernel. In this
@@ -416,8 +415,9 @@ Debugging
---------
Xen has a set of debugging features that can be useful to try and
figure out what's going on. Hit 'h' on the serial line or ScrollLock-h
on the keyboard to get a list of supported commands.
figure out what's going on. Hit 'h' on the serial line (if you
specified a baud rate on the Xen command line) or ScrollLock-h on the
keyboard to get a list of supported commands.
If you have a crash you'll likely get a crash dump containing an EIP
(PC) which, along with an 'objdump -d image', can be useful in
+7 -1
View File
@@ -48,7 +48,8 @@ void start_of_day(void);
/* opt_console: If true, Xen sends logging to the VGA console. */
int opt_console = 1;
/* opt_ser_baud: Baud rate at which logging is sent to COM1. */
unsigned int opt_ser_baud = 9600;
/* NB. Default (0) means that serial I/O is disabled. */
unsigned int opt_ser_baud = 0;
/* opt_dom0_mem: Kilobytes of memory allocated to domain 0. */
unsigned int opt_dom0_mem = 16000;
/* opt_ifname: Name of physical network interface to use. */
@@ -232,6 +233,9 @@ void cmain (unsigned long magic, multiboot_info_t *mbi)
void init_serial(void)
{
if ( !SERIAL_ENABLED )
return;
/* 'opt_ser_baud' baud, no parity, 1 stop bit, 8 data bits. */
outb(0x83, SERIAL_BASE+DATA_FORMAT);
outb(115200/opt_ser_baud, SERIAL_BASE+DIVISOR_LO);
@@ -249,6 +253,8 @@ void init_serial(void)
#ifdef CONFIG_OUTPUT_SERIAL
void putchar_serial(unsigned char c)
{
if ( !SERIAL_ENABLED )
return;
if ( c == '\n' ) putchar_serial('\r');
while ( !(inb(SERIAL_BASE+LINE_STATUS)&(1<<5)) ) barrier();
outb(c, SERIAL_BASE+TX_HOLD);
+3
View File
@@ -71,6 +71,9 @@ static void serial_rx_int(int irq, void *dev_id, struct pt_regs *regs)
void initialize_serial()
{
int rc;
if ( !SERIAL_ENABLED )
return;
/* setup key handler */
add_key_handler('~', toggle_echo, "toggle serial echo");
+6 -1
View File
@@ -146,9 +146,14 @@
#define capable(_c) 0
#ifndef __ASSEMBLY__
extern unsigned long _end; /* standard ELF symbol */
extern void __out_of_line_bug(int line) __attribute__((noreturn));
#define out_of_line_bug() __out_of_line_bug(__LINE__)
#endif
extern unsigned int opt_ser_baud;
#define SERIAL_ENABLED (opt_ser_baud != 0)
#endif /* __ASSEMBLY__ */
#endif /* __XENO_CONFIG_H__ */
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.