PCI DMA
From: Hans (hans_at_whatever.com)
Date: 10/22/04
- Next message: Roman Mashak: "driver for IrDA keyboard"
- Previous message: Peter Pearson: "Re: kernel man pages"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 22 Oct 2004 00:44:31 +0100
Hello
I want to make a PCI card perform a DMA transaction (DMA data from the card
to the PC). I've no trouble in setting the card up to perform the DMA. But
I'm not sure how to set Linux up to receive the data. I only want to do the
DMA for testing purposes (make sure the card is sending the correct data) so
I only need a general purpose DMA setup. Here's how I'm thinking of doing
it:
* In the device driver I use kmalloc() to create a buffer (hold the DMA
data).
* I then use pci_map_single() to set Linux up.
* Finally I tell the PCI card to do it's DMA (to the address returned by
pci_map_single()).
Does this sound the correct way of doing it? Knowing I have working code
will really help when it comes to finding the cause of any bugs.
TIA
- Next message: Roman Mashak: "driver for IrDA keyboard"
- Previous message: Peter Pearson: "Re: kernel man pages"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|