* BUG: invalid MAX_DMA_ADDRESS macro for i386?
@ 2001-08-01 5:16 Paul
2001-08-02 14:19 ` Alan Cox
0 siblings, 1 reply; 2+ messages in thread
From: Paul @ 2001-08-01 5:16 UTC (permalink / raw)
To: linux-kernel
Dear All;
2.4.6-ac5 kernel, i486.
Well, I have tracked down my problem. We see a comparison
like this to determine whether to use a bounce buffer:
if ( virt_to_bus(addr+buflen) >= MAX_DMA_ADDRESS) {
...(use a bounce buffer 'cause that addr is not dma-able)...
This is not working, because MAX_DMA_ADDRESS is defined
so:
./include/asm-i386/dma.h:
#define MAX_DMA_ADDRESS (PAGE_OFFSET+0x1000000)
This looks to come out to 0xc1000000. This does not seem
to be comparable to a bus address. eg. 0x100000 == 16M, the DMA
limit on ISA bus.
This driver doesnt work on ISA machine with > 16M, as the
bounce buffer never gets used. (forcing its unconditional use
makes it work fine)
So, what is wrong here? Macro, or conditional? Clue me in
so I can fix it correctly.
Paul
set@pobox.com
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: BUG: invalid MAX_DMA_ADDRESS macro for i386?
2001-08-01 5:16 BUG: invalid MAX_DMA_ADDRESS macro for i386? Paul
@ 2001-08-02 14:19 ` Alan Cox
0 siblings, 0 replies; 2+ messages in thread
From: Alan Cox @ 2001-08-02 14:19 UTC (permalink / raw)
To: Paul; +Cc: linux-kernel
> Well, I have tracked down my problem. We see a comparison
> like this to determine whether to use a bounce buffer:
>
> if ( virt_to_bus(addr+buflen) >= MAX_DMA_ADDRESS) {
> ...(use a bounce buffer 'cause that addr is not dma-able)...
>
> This is not working, because MAX_DMA_ADDRESS is defined
> so:
>
> ./include/asm-i386/dma.h:
> #define MAX_DMA_ADDRESS (PAGE_OFFSET+0x1000000)
MAX_DMA_ADDRESS is intended for checking virtual addresses not bus
addresses.
Alan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-08-02 14:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-01 5:16 BUG: invalid MAX_DMA_ADDRESS macro for i386? Paul
2001-08-02 14:19 ` Alan Cox
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®