General serial adapters

By default, a serial port driver automatically detects the I/O port and IRQ.

A standard PC system uses the devc-ser8250 driver; the BSP documentation indicates the drivers specific to your target hardware.

If the driver doesn't detect all the serial ports, ensure that the ports are enabled in the BIOS. If the ports are enabled, try specifying the I/O port and IRQ of the ports when you start the driver. Use a comma to separate the I/O port and the IRQ; use a space to separate each port-IRQ pair in the command. For example:

devc-ser8250 3f8,4 2f8,3
Note: If you start a serial driver for a UART or modem when another serial driver is already running, you need to use the -u option to give the new driver a number to append to the device name so that it doesn't conflict with any existing /dev/ser entry.

The standard devc-ser8250 driver supports only the RS-232 protocol.

The serial drivers support software and hardware flow control:

Note: In edited mode (-e), flow control is disabled. Don't enable software and hardware flow control at the same time.

Heavy serial port usage can be very taxing on some systems; by default, the serial adapter triggers an interrupt for each character transmitted or received. You can use these options to reduce the number of interrupts:

-T number
Enable the transmit FIFO and set the number of characters to be transmitted at each TX interrupt to 1, 4, 8, or 14. The default is 0 (FIFO disabled).
-t number
Enable the receive FIFO and set its threshold to 1, 4, 8, or 14 characters. The default is 0 (trigger disabled).

A receive timeout guarantees that the characters won't remain buffered too long. For example, imagine that the device receives:

This sentence is coming across the serial port.

By default, the system has to service 47 interrupts to receive this sentence. If you set the receive trigger level to 14, the number of interrupts is reduced to four. This helps the overall system performance, but you're trading off reliability; the higher the receive trigger (-t), the higher the possibility of losing data.