Subject: aperture module?
To: None <port-i386@netbsd.org>
From: Chris Jones <cjones@rupert.honors.montana.edu>
List: port-i386
Date: 07/15/1999 18:26:12
I realize that the aperture driver isn't a stylish thing to use (out
of curiosity, why not?), but I'm trying to use it, and I'm failing.
:(

First of all, it doesn't compile unless you make opt_user_ldt.h,
opt_gateway.h, etc. all available to it.  I managed this by adding
-I. to CFLAGS and copying the appropriate files from a kernel compile
directory.  Using that method, I was able to produce a working ap.o
that was good until I switched over to ELF.

Now I can modload the (ELF) ap.o.  I get:

oscar# modload -o ap -e ap -p apinstall ap.o
ap.o: In function `apopen':
ap.o(.text+0x13): undefined reference to `suser'
ap.o: In function `apmmap':
ap.o(.text+0x70): undefined reference to `physmem'
ap.o: In function `ap_load':
ap.o(.text+0xa7): undefined reference to `printf'
ap.o: In function `ap':
ap.o(.text+0xf3): undefined reference to `lkm_nofunc'
ap.o(.text+0x101): undefined reference to `lkmdispatch'
ap.o(.data+0x28): undefined reference to `enodev'
ap.o(.data+0x2c): undefined reference to `enodev'
ap.o(.data+0x30): undefined reference to `enodev'
ap.o(.data+0x34): undefined reference to `enodev'
ap.o(.data+0x3c): undefined reference to `seltrue'
modload: can't prelink `ap.o' creating `ap'

Is this a known bug?  I only just now re-subscribed to port-i386, so
I've probably missed a lot of things.  :)

Chris

-- 
-----------------------------------------------------cjones@math.montana.edu
Chris Jones                                          cjones@honors.montana.edu
           Mad scientist at large                    cjones@nervana.montana.edu
"Is this going to be a stand-up programming session, sir, or another bug hunt?"