mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* mmap() and ioctl()
@ 2005-04-04 18:27 Matthew Dharm
  2005-04-04 19:02 ` Richard B. Johnson
  0 siblings, 1 reply; 4+ messages in thread
From: Matthew Dharm @ 2005-04-04 18:27 UTC (permalink / raw)
  To: Kernel Developer List

[-- Attachment #1: Type: text/plain, Size: 656 bytes --]

This probably is a silly question, but....

Is is possible to open a file, mmap() it into memory, then pass the address
of that map via an ioctl() call to the kernel, which will copy_from_user()
that data?

Yeah, that's an odd concept, I know... I could always malloc() some
memory, read the file in, and then ioctl() it.  But, if I could get away
with a direct mmap(), that would be much better for me.

Matt

-- 
Matthew Dharm                              Home: mdharm-usb@one-eyed-alien.net 
Maintainer, Linux USB Mass Storage Driver

I say, what are all those naked people doing?
					-- Big client to Stef
User Friendly, 12/14/1997

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread
* RE: mmap() and ioctl()
@ 2005-04-05 15:30 Aleksey Gorelov
  0 siblings, 0 replies; 4+ messages in thread
From: Aleksey Gorelov @ 2005-04-05 15:30 UTC (permalink / raw)
  To: Matthew Dharm, Richard B. Johnson; +Cc: Kernel Developer List

 >-----Original Message-----
>From: linux-kernel-owner@vger.kernel.org 
>[mailto:linux-kernel-owner@vger.kernel.org] On Behalf Of Matthew Dharm
>Sent: Monday, April 04, 2005 12:20 PM
>To: Richard B. Johnson
>Cc: Kernel Developer List
>Subject: Re: mmap() and ioctl()
>

[snip]

>That's an interesting concept, and one I'm not familiar with.  
>Any useful
>pointers (beyond UTSL)?  I'll admit to being much more 
>familiar with SCSI
>and USB internals than I am with something like device-layer 
>interfacing.
Try this:

http://lwn.net/Kernel/LDD3/

Aleks.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-04-05 15:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-04 18:27 mmap() and ioctl() Matthew Dharm
2005-04-04 19:02 ` Richard B. Johnson
2005-04-04 19:19   ` Matthew Dharm
2005-04-05 15:30 Aleksey Gorelov

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®