diff options
author | phk <phk@FreeBSD.org> | 1999-08-23 20:59:21 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-08-23 20:59:21 +0000 |
commit | 663cbe4fc26065f7af7d10faaee492a626156145 (patch) | |
tree | 32e619fadb473bfb85ff8e06044176f2ff323cce /sys/i386/apm | |
parent | 2a5ff1f726f814a9e4717afe3f14250f8030cace (diff) | |
download | FreeBSD-src-663cbe4fc26065f7af7d10faaee492a626156145.zip FreeBSD-src-663cbe4fc26065f7af7d10faaee492a626156145.tar.gz |
Convert DEVFS hooks in (most) drivers to make_dev().
Diskslice/label code not yet handled.
Vinum, i4b, alpha, pc98 not dealt with (left to respective Maintainers)
Add the correct hook for devfs to kern_conf.c
The net result of this excercise is that a lot less files depends on DEVFS,
and devtoname() gets more sensible output in many cases.
A few drivers had minor additional cleanups performed relating to cdevsw
registration.
A few drivers don't register a cdevsw{} anymore, but only use make_dev().
Diffstat (limited to 'sys/i386/apm')
-rw-r--r-- | sys/i386/apm/apm.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/sys/i386/apm/apm.c b/sys/i386/apm/apm.c index 69c5692..eb5ed62 100644 --- a/sys/i386/apm/apm.c +++ b/sys/i386/apm/apm.c @@ -15,19 +15,14 @@ * * Sep, 1994 Implemented on FreeBSD 1.1.5.1R (Toshiba AVS001WD) * - * $Id: apm.c,v 1.101 1999/08/22 14:48:00 iwasaki Exp $ + * $Id: apm.c,v 1.102 1999/08/22 19:51:33 peter Exp $ */ -#include "opt_devfs.h" - #include <sys/param.h> #include <sys/systm.h> #include <sys/eventhandler.h> #include <sys/conf.h> #include <sys/kernel.h> -#ifdef DEVFS -#include <sys/devfsext.h> -#endif /*DEVFS*/ #include <sys/time.h> #include <sys/reboot.h> #include <sys/bus.h> @@ -79,9 +74,6 @@ struct apm_softc { int event_ptr; struct apm_event_info event_list[APM_NEVENTS]; u_char event_filter[APM_NPMEV]; -#ifdef DEVFS - void *sc_devfs_token; -#endif }; #define SCFLAG_ONORMAL 0x0000001 #define SCFLAG_OCTL 0x0000002 @@ -1131,10 +1123,7 @@ apm_attach(device_t dev) sc->initialized = 1; -#ifdef DEVFS - sc->sc_devfs_token = - devfs_add_devswf(&apm_cdevsw, 0, DV_CHR, 0, 0, 0600, "apm"); -#endif + make_dev(&apm_cdevsw, 0, 0, 0, 0600, "apm"); return 0; } |