* mmap'ing IO memory on i386
@ 2000-12-15 17:52 Anders Torger
0 siblings, 0 replies; only message in thread
From: Anders Torger @ 2000-12-15 17:52 UTC (permalink / raw)
To: linux-kernel
I'm writing an ALSA sound card driver, for a card that does not support DMA,
thus the CPU need to do the copying to and from the onboard buffer. ALSA
allows for optional mmap'd access, that is accessing the in memory dma buffer
directly from user space. However, for this card that does not support DMA,
it would be best to mmap its IO memory directly, this way I get rid of a copy
in the interrupt handler to an intermediate kernel buffer. This should be
possible on the i386 as far as I know.
I use a 2.2.14 kernel, and ioremap (also tested ioremap_nocache) to relocate
the IO memory. In kernel space it works fine to access the ioremap'd area
just like any other kernel buffer. However, when the ioremap'd area is mmap'd
from user space, problems occur. In user space: when the memory is read, all
bytes are always 0xFF, and when written to, nothing happens (the memory being
on the sound card is unchanged).
I have two questions: (1) why is this happening? (2) is it possible to make
it work?
Please reply to my address directly, since I'm not on the mailing list.
/Anders Torger
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2000-12-15 18:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-12-15 17:52 mmap'ing IO memory on i386 Anders Torger
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox