From 7e23685d60c2e9df4a983887b49221152ab7b5e3 Mon Sep 17 00:00:00 2001 From: Coleman Kane Date: Sat, 24 Jun 2000 06:20:55 +0000 Subject: Stupid me, I put the opt_tdfx.h underneath a test for TDFX_LINUX, which resides in opt_tdfx. I also cleand up that large define. Compile, tell me if it does, and I'll re-enable the tdfx entry in the makefile. --- sys/dev/tdfx/tdfx_linux.h | 9 ++++++--- sys/dev/tdfx/tdfx_pci.c | 4 +++- 2 files changed, 9 insertions(+), 4 deletions(-) (limited to 'sys/dev/tdfx') diff --git a/sys/dev/tdfx/tdfx_linux.h b/sys/dev/tdfx/tdfx_linux.h index f8ea75dee09f3..3684db0d5f685 100644 --- a/sys/dev/tdfx/tdfx_linux.h +++ b/sys/dev/tdfx/tdfx_linux.h @@ -42,12 +42,15 @@ */ #define LINUX_IOCTL_SET(n,low,high) \ static linux_ioctl_function_t linux_ioctl_##n; \ -static struct linux_ioctl_handler n##_handler = {linux_ioctl_##n,low, high}; \ -SYSINIT(n##register, SI_SUB_KLD, SI_ORDER_MIDDLE, \ +static struct linux_ioctl_handler n##_handler = {linux_ioctl_##n, low, high}; \ +SYSINIT(n##register, SI_SUB_KLD, SI_ORDER_MIDDLE,\ linux_ioctl_register_handler, &n##_handler); \ -SYSUNINIT(n##unregister, SI_SUB_KLD, SI_ORDER_MIDDLE, \ +SYSUNINIT(n##unregister, SI_SUB_KLD, SI_ORDER_MIDDLE,\ linux_ioctl_unregister_handler, &n##_handler); +/* Prototype for ioctl wrapper */ +static int linux_ioctl_tdfx(struct proc* p, struct linux_ioctl_args* args); + /* Values for /dev/3dfx */ /* Query IOCTLs */ #define LINUX_IOCTL_TDFX_QUERY_BOARDS 0x3302 diff --git a/sys/dev/tdfx/tdfx_pci.c b/sys/dev/tdfx/tdfx_pci.c index 9709fd5953450..d1ac6569d8c91 100644 --- a/sys/dev/tdfx/tdfx_pci.c +++ b/sys/dev/tdfx/tdfx_pci.c @@ -74,6 +74,9 @@ #include #include #include + +/* This must come first */ +#include "opt_tdfx.h" #ifdef TDFX_LINUX #include #endif @@ -82,7 +85,6 @@ #include #include -#include "opt_tdfx.h" static devclass_t tdfx_devclass; -- cgit v1.3