Re: mmap RAM?

Stephen Williams (steve@icarus.icarus.com)
Tue, 24 Mar 1998 10:18:07 -0800


neal@ctd.comsat.com said:
> I am trying to write a driver for a new device. It is an MPEG2 video
> *encoder*. The device sits on a PCI bus. It wants to DMA encoded
> video to the host RAM.

ftp://ft.picturel.com/pub/source/mmap.tgz

It works a page at a time because the kernel does lazy mapping, and anyhow
may choose to forget random pages at random times. You also need to go
through some of the other hoops to keep module reference counts correct.
Take a look at the example at the above ftp site.

Also, note that you cannot either the device must scatter-gather, or
you use something like bigphysarea to get large contiguous buffers.

-- 
Steve Williams                "The woods are lovely, dark and deep.
steve@icarus.com              But I have promises to keep,
steve@picturel.com            and lines to code before I sleep,
http://www.picturel.com       And lines to code before I sleep."

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu