Skip to contentSkip to conversation

PCIe device driver question

DISCUSSION Sanka Piyaratna 3 participants 3 messages Jul 30, 2008

lore
Share & tools
lore
#0 lore raw

Hi Alan,

Actually the failures occur at addresses lot higher than this range, I am noticing the failure at dma address 0x0000000037845000. This would be at around 900MB ?

Thanks

Sanka

----- Original Message ----
From: Alan Cox <[email protected]>
To: Sanka Piyaratna <[email protected]>
Cc: [email protected]
Sent: Thursday, 31 July, 2008 1:17:18 AM
Subject: Re: PCIe device driver question

Quoted 11 lines · On Wed, 30 Jul 2008 09:00:58 -0700 (PDT) Sanka Piyaratna <[email protected]>…

Hi,

I am currently developing a PCIe data capture card hardware and the device drivers to drive this. I have implemented DMA on the data capture and the scatter-gather DMA is implemented in the hardware. I am testing this in an X86_64 architecture machine with 4 GB of RAM. I am able to successfully dma data into any memory (dma) address > 0x0000_0001_0000_0000. However, my problem is to dma data to any address less than this. When I try to DMA data to an address less than 0x0000_0001_0000_0000, the hardware device hangs indicating that the address does not exist.

Assuming the failures are in the range 640K-1MB then I would imagine your bridge doesn't permit transfers via DMA to the ISA hole.

Find a better answer, faster with the new Yahoo!7 Search. www.yahoo7.com.au/search

#1 lore raw
Quoted 4 lines
Quoted 4 lines

am testing this in an X86_64 architecture machine with 4 GB of RAM. I am able to successfully dma data into any memory (dma) address > 0x0000_0001_0000_0000.

How can you DMA "successfully" into this address which is > 4 GB when you have only 4 GB RAM ? Or am I missing something ?

V. Radhakrishnan
http://www.atr-labs.com

Quoted 43 lines · Sanka Piyaratna

Hi Alan,

Actually the failures occur at addresses lot higher than this range, I am noticing the failure at dma address 0x0000000037845000. This would be at around 900MB ?

Thanks

Sanka

----- Original Message ----
From: Alan Cox <[email protected]>
To: Sanka Piyaratna <[email protected]>
Cc: [email protected]
Sent: Thursday, 31 July, 2008 1:17:18 AM
Subject: Re: PCIe device driver question

Quoted 11 lines · On Wed, 30 Jul 2008 09:00:58 -0700 (PDT) Sanka Piyaratna <[email protected]>…

Hi,

I am currently developing a PCIe data capture card hardware and the device drivers to drive this. I have implemented DMA on the data capture and the scatter-gather DMA is implemented in the hardware. I am testing this in an X86_64 architecture machine with 4 GB of RAM. I am able to successfully dma data into any memory (dma) address > 0x0000_0001_0000_0000. However, my problem is to dma data to any address less than this. When I try to DMA data to an address less than 0x0000_0001_0000_0000, the hardware device hangs indicating that the address does not exist.

Assuming the failures are in the range 640K-1MB then I would imagine your bridge doesn't permit transfers via DMA to the ISA hole.

Find a better answer, faster with the new Yahoo!7 Search. www.yahoo7.com.au/search
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#2 lore raw
In reply to Sanka Piyaratna
Quoted 3 lines · On Wed, 30 Jul 2008 09:09:36 -0700 (PDT) Sanka Piyaratna <[email protected]>…

Hi Alan,

Actually the failures occur at addresses lot higher than this range, I am noticing the failure at dma address 0x0000000037845000. This would be at around 900MB ?

For x86 we don't do anything special and if your hardware is flagging the memory as absent perhaps you should consult the hardware/bridge documentation firt ?

In some cases (over 4GB and 32bit DMA masks set) we will use the GART on x86-64 but that will still see addresses below 4GB being sent to the device.

Alan