lkml.org 
[lkml]   [1999]   [Sep]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectdo_mmap() question
Greetings, 

I need to create a user mapping to some SDRAM on a PCI board, but I can't
do it via a regular file operation like mmap() or ioctl(). Instead, the
mapping should be a side-effect of a device-specific system call I have added.

Further, I want the mapping to have its own vma so I can override the vm_ops
and wire in my SDRAM allocator.

The best way I can see is to dummy up a struct file, wire f_op->mmap to my
own mmap, pass that to do_mmap(), then override vm_ops in my mmap function.
Yuck! But neither remap_page_range() nor anonymous do_mmap() result in a
unique vma whose vm_ops I can override.

What's the right way to do this? Am I just trying to be too wierd?

Thanks in advance,

Jim


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.050 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site