Skip to contentSkip to conversation

Question regarding DMA xfer to user space directly

DISCUSSION Alan Shih 2 participants 3 messages Jul 8, 2003 – Jul 9, 2003

lore
Share & tools
lore

Alan Shih

author
#0 lore raw

Is there a provision in MM for DMA transfer to user space directly without allocating a kernel buffer?

TIA

Alan

#1 lore raw
Quoted 2 lines · Alan Shih

Is there a provision in MM for DMA transfer to user space directly without allocating a kernel buffer?

Yes. Its used both for O_DIRECT I/O (direct to disk I/O from userspace) and for things like tv capture cards. The kernel allows a driver to pin user pages and obtain mappings for them. Note that for large systems user pages may be above the 32bit boundary so you need DAC capable hardware to get the best results

author
#2 lore raw

Next question would be what are the steps that the driver need to ping user pages before setting up the xfer?

Thanks.

-----Original Message-----
From: Alan Cox [mailto:[email protected]]
Sent: Tuesday, July 08, 2003 8:22 AM
To: Alan Shih
Cc: Linux Kernel Mailing List
Subject: Re: Question regarding DMA xfer to user space directly

Quoted 2 lines · Alan Shih

Is there a provision in MM for DMA transfer to user space directly without allocating a kernel buffer?

Yes. Its used both for O_DIRECT I/O (direct to disk I/O from userspace) and for things like tv capture cards. The kernel allows a driver to pin user pages and obtain mappings for them. Note that for large systems user pages may be above the 32bit boundary so you need DAC capable hardware to get the best results