linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* I/O and MM question
@ 1999-01-10 17:13 Jelle Foks
  1999-01-10 23:52 ` Ingo Oeser
  0 siblings, 1 reply; 2+ messages in thread
From: Jelle Foks @ 1999-01-10 17:13 UTC (permalink / raw)
  To: linux-mm

Hi,

I have a question about memory management in Linux and low-overhead I/O
between devices and the file system.

I have a device that has memory-mapped access. In a system with 8MB of RAM
(where the kernel reports and uses only 8MB of RAM), the device responds
to memory read and write accesses in the region 8-16MB. What I need to do
is fast I/O between the device the hard drive. Currently, I access the
device from a module that has mapped the device's I/O RAM addresses to a
pointer with vremap(). This way, I should be able to make a character
device that allows a user space process to fread() from the device and
fwrite() to the hard drive (and vice versa). However, I'd like to
eliminate the memory copy to/from the user-space process's buffer, and do
something like an fwrite() directly from the simulated-RAM provided by the
device (or probably better a memcpy() from the device to a mmap()ped file
from disk).

Can I give a user process read/write access to the RAM from the device?
(how/which function to use?). Does the mm/paging system of Linux allow me
this? Or does the mm/paging code already somehow eliminate the memory-copy
of the fread()->fwrite() combo (how?)? Or should/could I use a scheme
where the user space process gives the pointer of a mmap()ed file to the
device driver, and let the device driver itself do a memcpy() to the
mmap()ped file?

Does anybody have any hints, ideas, etc?

Greetings,
Jelle.


--
This is a majordomo managed list.  To unsubscribe, send a message with
the body 'unsubscribe linux-mm me@address' to: majordomo@kvack.org

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

end of thread, other threads:[~1999-01-10 23:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-01-10 17:13 I/O and MM question Jelle Foks
1999-01-10 23:52 ` Ingo Oeser

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox