CLASS="SECTION" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#840084" ALINK="#0000FF" >

10.3. Linux kernel version 2.2

The later Linux 2.2 kernels use the same build parameters and parameter syntax as the Linux version 2.4 kernels.

For earlier kernels see the article by Francesco Conti in issue 36 of Linux Journal published in April 1997.

This article included some patches for the kernel, which have been extended in the notes below to use a broader range of serial port speeds.

Choose to use the serial console by adding a couple of #defines at the start of /usr/src/linux/drivers/char/console.c:

#define CONFIG_SERIAL_ECHO
#define SERIAL_ECHO_PORT 0x3f8  /* COM1 port address */

Alternatively, to use ttyS1 use these lines:

#define CONFIG_SERIAL_ECHO
#define SERIAL_ECHO_PORT 0x2f8  /* COM2 port address */

The kernel assumes a serial link speed of 9600bps. If you are using a differing bit rate then find these two lines:

serial_echo_outb(0x00, UART_DLM); /* 9600 baud */
serial_echo_outb(0x0c, UART_DLL);

and change 0x0c to one of the values in Table 10-1.

Table 10-1. IBM-PC/AT serial port bit rates and their bit-clock divisors

Bit RateDivisor
115200bps0x01
57600bps0x02
38400bps0x03
19200bps0x06
9600bps0x0c
4800bps0x18
2400bps0x30
1200bps0x60