PCI DMA

From: Hans (hans_at_whatever.com)
Date: 10/22/04


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



Relevant Pages

  • Re: Reading audio samples immediately
    ... driver assembly code for my particular soundcard and set up, ... stopped the card and the DMA controller myself. ... wishing some special mode would be created for use of real-time sound. ...
    (microsoft.public.win32.programmer.directx.audio)
  • Re: Zip Chip programming info / disk image?
    ... the tech.details file is sufficiently detailed to explain the inner workings. ... Does it actually work with DMA devices? ... bits track a RamWorks-style AUX RAM card bank, ... at least 1MB of "AUX RAM" would also be a good idea. ...
    (comp.sys.apple2)
  • Re: Udp sending performance in Gbit Ethernet
    ... > saw a sudden drop of perfromance for certain packet sizes. ... > there can be just so many reasons like interrupts and DMA. ... > such as the maximum DMA block size or alike, which forces the driver to ... Try different versions of the driver for the card. ...
    (microsoft.public.development.device.drivers)
  • BCM4312 Fails when xdm is started
    ... This card is known to work with the b43 ... about the "Zone PFN" settings. ... Zone PFN ranges: ... Certainly all the memory is available to 32-bit DMA. ...
    (Linux-Kernel)
  • Re: Testing Sirius RAM card at 8MB?
    ... What SCSI card are you using? ... support DMA within the first 4 MB of a memory expansion card, ... doesn't supply the bank address during a DMA cycle. ...
    (comp.sys.apple2)