* inverse mmap() available?
@ 2001-09-28 15:16 Norbert Roos
2001-09-28 15:28 ` Tommy Reynolds
2001-09-28 15:30 ` Christoph Hellwig
0 siblings, 2 replies; 5+ messages in thread
From: Norbert Roos @ 2001-09-28 15:16 UTC (permalink / raw)
To: linux-kernel
Hello!
Is there a way to map user space memory into kernel address space, e.g.
that i don't have to call get_user(var,...) but simply use var =
*user_space_ptr?
What i intend to do (as the next step) is to DMA-transfer data directly
between a PCI device and user space memory. The buffer in user space
should be allocated with malloc(), so allocating a buffer in kernel and
mmap()-ping it to user space is not the solution..
I guess this has been asked before, any links to further information
would be great.
Thanks
Norbert
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: inverse mmap() available?
2001-09-28 15:16 inverse mmap() available? Norbert Roos
@ 2001-09-28 15:28 ` Tommy Reynolds
2001-09-28 15:30 ` Christoph Hellwig
1 sibling, 0 replies; 5+ messages in thread
From: Tommy Reynolds @ 2001-09-28 15:28 UTC (permalink / raw)
To: Norbert Roos; +Cc: linux-kernel
Norbert Roos <n.roos@berlin.de> was pleased to say:
>
> Hello!
>
> Is there a way to map user space memory into kernel address space, e.g.
> that i don't have to call get_user(var,...) but simply use var =
> *user_space_ptr?
>
> What i intend to do (as the next step) is to DMA-transfer data directly
> between a PCI device and user space memory. The buffer in user space
> should be allocated with malloc(), so allocating a buffer in kernel and
> mmap()-ping it to user space is not the solution..
>
> I guess this has been asked before, any links to further information
> would be great.
Look at the KIOBUF stuff in <linux/iobuf.h> for how to do this.
---------------------------------------------+-----------------------------
Tommy Reynolds | mailto: <reynolds@redhat.com>
Red Hat, Inc., Embedded Development Services | Phone: +1.256.704.9286
307 Wynn Drive NW, Huntsville, AL 35805 USA | FAX: +1.236.837.3839
Senior Software Developer | Mobile: +1.919.641.2923
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: inverse mmap() available?
2001-09-28 15:16 inverse mmap() available? Norbert Roos
2001-09-28 15:28 ` Tommy Reynolds
@ 2001-09-28 15:30 ` Christoph Hellwig
2001-09-28 16:50 ` putting a user program to sleep till interrupted Anil Kumar
1 sibling, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2001-09-28 15:30 UTC (permalink / raw)
To: Norbert Roos; +Cc: linux-kernel, kernelnewbies
In article <3BB49438.1F2C59B3@berlin.de> you wrote:
> Hello!
>
> Is there a way to map user space memory into kernel address space, e.g.
> that i don't have to call get_user(var,...) but simply use var =
> *user_space_ptr?
>
> What i intend to do (as the next step) is to DMA-transfer data directly
> between a PCI device and user space memory. The buffer in user space
> should be allocated with malloc(), so allocating a buffer in kernel and
> mmap()-ping it to user space is not the solution..
>
> I guess this has been asked before, any links to further information
> would be great.
map_user_kiobuf is what you want :) Some more explanation at:
ftp://ftp.openlinux.org/pub/people/hch/kio/kiobuf.txt
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2001-10-01 7:39 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-09-28 15:16 inverse mmap() available? Norbert Roos
2001-09-28 15:28 ` Tommy Reynolds
2001-09-28 15:30 ` Christoph Hellwig
2001-09-28 16:50 ` putting a user program to sleep till interrupted Anil Kumar
2001-10-01 7:39 ` Martin Maletinsky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox