summaryrefslogtreecommitdiffstats
path: root/sys/dev/tga
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2002-11-08 21:10:53 +0000
committerjhb <jhb@FreeBSD.org>2002-11-08 21:10:53 +0000
commiteb9c5b7d92abac243d955a5a1397f5f291b1a591 (patch)
treed91d93c3c48331c3e28d2f51110c753b6135b5d1 /sys/dev/tga
parentf47ce099d47d08b23a27b71e932f660e2007ddc4 (diff)
downloadFreeBSD-src-eb9c5b7d92abac243d955a5a1397f5f291b1a591.zip
FreeBSD-src-eb9c5b7d92abac243d955a5a1397f5f291b1a591.tar.gz
- Move opt_fb.h earlier so it covers included headers.
- Update cdevsw. Block majors are out, kqfilters are in. - No need to bzero softc's that we get from new-bus. They come that way to begin with.
Diffstat (limited to 'sys/dev/tga')
-rw-r--r--sys/dev/tga/tga_pci.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/sys/dev/tga/tga_pci.c b/sys/dev/tga/tga_pci.c
index a1b2ccf..6a78523 100644
--- a/sys/dev/tga/tga_pci.c
+++ b/sys/dev/tga/tga_pci.c
@@ -27,6 +27,8 @@
* Copyright (c) 2000 Andrew Miklic, Andrew Gallatin, and Thomas V. Crimi
*/
+#include "opt_fb.h"
+
#include <sys/cdefs.h>
__FBSDID("$FreeBSD$");
@@ -63,8 +65,6 @@ __FBSDID("$FreeBSD$");
#include <dev/fb/gfb.h>
#include <dev/gfb/gfb_pci.h>
-#include "opt_fb.h"
-
static int tga_probe(device_t);
static int tga_attach(device_t);
static void tga_intr(void *);
@@ -110,10 +110,10 @@ static struct cdevsw tga_cdevsw = {
/* dump */ nodump,
/* psize */ nopsize,
/* flags */ 0,
- /* bmaj */ -1
+ /* kqfilter */ nokqfilter
};
-#endif /*FB_INSTALL_CDEV*/
+#endif /* FB_INSTALL_CDEV */
static int
tga_probe(device_t dev)
@@ -144,7 +144,6 @@ tga_attach(device_t dev)
error = 0;
unit = device_get_unit(dev);
sc = device_get_softc(dev);
- bzero(sc, sizeof(struct gfb_softc));
sc->driver_name = TGA_DRIVER_NAME;
switch(pci_get_device(dev)) {
case DEC_DEVICEID_TGA2:
@@ -192,7 +191,7 @@ tga_attach(device_t dev)
#ifdef FB_INSTALL_CDEV
sc->cdevsw = &tga_cdevsw;
sc->devt = make_dev(sc->cdevsw, unit, 0, 0, 02660, "tga%x", unit);
-#endif /*FB_INSTALL_CDEV*/
+#endif /* FB_INSTALL_CDEV */
goto done;
fail:
if(sc->intrhand != NULL) {
OpenPOWER on IntegriCloud