Subject: Re: XFree86
To: Mark Willey <mwilley@hillres142.cc.purdue.edu>
From: Matthieu Herrb <matthieu@laas.fr>
List: current-users
Date: 01/19/1995 09:27:30
You wrote (in your message from Wed 18)
 > > > checkDevMem: warning: failed to open /dev/mem (Operation not permitted)
 > > > 	trying aperture driver
 > > > checkDevMem: warning: failed to open /dev/xf86 (No such file or directory)
 > > > 	linear fb access unavailable
 > 
 > I am also getting this error.  The su workaround didn't seem to do
 > anything...  Does anyone else get thie /dev/mem not permitted in thier
 > error file?
 > 

Since 0.9Ç NetBSD has an security mechanism (via 'sysctl(8)') that
disable access to /dev/mem to any process (including processes
running as root).

Since XFree86 can take advantage from a linear access to the
framebuffer, there is now a loadable kernel module shipped with
XFree86 that implements a new device /dev/xf86 that allows the X
server to access the mapped memory of the display card. 

This driver was called an "aperture driver" because similar things
exist on Solaris x86 and the driver is named so.

If you want to get rid of this /dev/mem access errors, just install
the aperture driver or disable the kernel security by editing
/sys/kern/kern_sysctl.c, to initialize `securelevel' to -1.

The aperture driver sources are in xc/programs/Xserver/hw/xfree86/etc
in the XFree86 3.1 sources. If you build your own server, be sure to
#define HasNetBSDApertureDriver YES in xf86site.h. A loadable binary
module is included in lib/X11/kernel in the 3.1 binary distributions.


					Matthieu