IO Address, IRQ, DMA ...

IO Address (port address)

Port is a gateway between external device and the CPU.
IO Address is a way to differentiate among various installed devices. Must be unique.

Old card used fixed IO addresses: Adlib 388H-389H
Roland 330H-331H (newer cards allow 300H-301H)

Starting from SB, the address can be adjusted with a jumper or via PnP protocol.

Most of the sound cards a number IO adresses, specified by base address.

In the simplest case we have a range of addresses of length 10H (SB-1.0, GUS)
or 20H (SB Pro, SB 16, and most of other sound cards) starting from the base address

Ranges for SB16: 220H: 220 - 23F
240H: 240 - 25F
260H: 260 - 27F Some cards use extra range by incrementing the first digit of the address.

Gravis Ultrasound (Classic): 210H: 210-21F, 310-31F, 510-51F
220H: 220-22F, 320-32F, 520-52F
230H: 230-23F, 330-33F, 530-53F Default setting (220H for SB) is normally safe, unless you have two or more sound cards on same computer.

How to get list of all used IO addresses in Linux:
more /proc/ioports

DMA number

A sound card normally uses DMA during transfer only, therefore you probably can share it with another device, that is also tolerant to that. However it is alway better to have a separate DMA for a card.

DMA numbers

8 bit:
0 - Can be used with all recent motherboards
1 - Default value and the safest choice.
2 - FD controller
3 - Safe with recent motherboard

4 - Cascade for channels 5, 6, and 7
5 - Safe to use (default)
6 , 7 - Safe to use

List of used DMAs in Linux:
more /proc/dma
Linux 2.0.0 users: Some old kernels reserve DMA 0 for memory refresh.

In order to fix the problem, you need to edit file kernel/dma.c
Make sure that 'dma_chan_busy starts with {0,0}:

static struct dma_chan dma_chan_busy[MAX_DMA_CHANNELS] = {
        { 0, 0 },
        { 0, 0 },
        { 0, 0 },
        { 0, 0 },
        { 1, "cascade" },
        { 0, 0 },
        { 0, 0 },
        { 0, 0 }

IRQ number

Used for sending interrupts to CPU.

Reserved IRQs

00timer 08RTC
01keyboard 09Free
02'daisy chain' 10Free
03COM2 11Free
04COM1 12Free
05LPT2 13Coprocessor
06Floppy 14IDE-1
07LPT1 15IDE-2

For non PnP cards default setting is 5 or 7.

List of all IRQs used in Linux:
more /proc/interrupts

Back Next