Subject: Re: Vnode access from devices
To: None <tech-kern@NetBSD.ORG>
From: Robert Black <firstname.lastname@example.org>
Date: 01/28/1998 15:03:46
On Jan 26, 11:00am, Jason Thorpe wrote:
> Subject: Re: Vnode access from devices
> On Mon, 26 Jan 1998 15:35:34 +0000
> "Robert Black" <email@example.com> wrote:
> > I want to use it as a handle for installing a pager. vm_mmap() appears to
> > expect the handle to be a vnode or NULL (for MAP_ANON).
> Why do you want to do this? Just provide an mmap entry point in the
> device driver...
I need to tidy up when it is unmapped.... The mmap device entrypoint doesn't
allow you enough control. Anyway, it turns out its only about 5 lines of code.
It works and the only assumption it makes about the vm system is the interface
to vm_mmap() (also used by sys_mmap, exec et al).