>>>>> "Maciej" == Maciej Przybycien <[EMAIL PROTECTED]> writes:
Maciej> Hi, I write device driver for PCI board.
Maciej> I read the following adresses from Base Address0 ...4
Maciej> registers: 0xb800, 0xcc000, 0xce000, 0xb400, 0xb000 Addresses
Maciej> 0xb800, 0xb400, 0xb000 are I/O ports and 0xcc000, 0xce000 are
Maciej> memory. However if I access memory addresses (0xcc000,
Maciej> 0xce000) the system crashes. Should I first map memory
Maciej> addresses in the kernel virtual space and then access it? How
Maciej> to do it?
ioremap() - read Documentation/IO-mapping.txt for details or maybe my
slides from Sydney
http://home.cern.ch/~jes/slides/sydney-kernel-print.ps.gz
Maciej> Are all the PCI boards allowed to generate interrupt or do we
Maciej> need to allow it eg. by writing to the PCI command register ?
They are but you need to register a handler with request_irq() and
remember to check the card first whether it actually generated the
interrupt. Using shared interrupts is highly recommended.
Jes
-
Linux SMP list: FIRST see FAQ at http://www.irisa.fr/prive/dmentre/smp-howto/
To Unsubscribe: send "unsubscribe linux-smp" to [EMAIL PROTECTED]