summaryrefslogtreecommitdiffstats
path: root/sys/modules/bktr
diff options
context:
space:
mode:
authorroger <roger@FreeBSD.org>1999-06-12 15:00:19 +0000
committerroger <roger@FreeBSD.org>1999-06-12 15:00:19 +0000
commit33418bb41d2c52fd4fdae9602722521ed20585e7 (patch)
treeba386d37f6831d13d6869871b3bc06e84a150c39 /sys/modules/bktr
parente92ea963e1051fd6928e889d8a240a0ee4286aaf (diff)
downloadFreeBSD-src-33418bb41d2c52fd4fdae9602722521ed20585e7.zip
FreeBSD-src-33418bb41d2c52fd4fdae9602722521ed20585e7.tar.gz
Makefile to build a loadable bktr Bt848/Bt878 device driver
This allows the bt848 grabber to be loaded in the boot loader or after bootup without the need for a custom kernel
Diffstat (limited to 'sys/modules/bktr')
-rw-r--r--sys/modules/bktr/Makefile47
1 files changed, 47 insertions, 0 deletions
diff --git a/sys/modules/bktr/Makefile b/sys/modules/bktr/Makefile
new file mode 100644
index 0000000..82ca729
--- /dev/null
+++ b/sys/modules/bktr/Makefile
@@ -0,0 +1,47 @@
+# Makefile for the bktr Brooktree Bt848/Bt878 PCI video capture device
+# Using the new FreeBSD 4.x device driver API (newbus) the Bt848 driver
+# can be loaded dynamically both in the boot loader phase and once
+# the system has booted.
+# The driver can also be unloaded, recompiled and reloaded.
+#
+# Use kldload bktr and kldunload bktr to load/unload the driver
+#
+# Note - as the driver requires contiguous memory, loading the driver once
+# memory has filled or become fragmented may fail.
+
+# $Id$
+
+S = ${.CURDIR}/../..
+.PATH: $S/pci
+KMOD = bktr
+SRCS = brooktree848.c bktr.h opt_devfs.h opt_bktr.h pci.h smbus.h bus_if.h device_if.h pci_if.h
+CLEANFILES += bktr.h opt_devfs.h opt_bktr.h pci.h smbus.h bus_if.h device_if.h pci_if.h
+FLAGS += ${DEBUG_FLAGS}
+
+bktr.h:
+ echo "#define NBKTR 1" > bktr.h
+
+pci.h:
+ echo "#define NPCI 1" > pci.h
+
+smbus.h:
+ # Do not use SMBUS/IICBUS. Use the old i2c code self contained in
+ # the bt848 driver.
+ echo "#define NSMBUS 0" > smbus.h
+
+opt_devfs.h:
+ touch opt_devfs.h
+
+opt_bktr.h:
+ touch opt_bktr.h
+
+device_if.h: $S/kern/makedevops.pl $S/kern/device_if.m
+ perl5 $S/kern/makedevops.pl -h $S/kern/device_if.m
+
+bus_if.h: $S/kern/makedevops.pl $S/kern/bus_if.m
+ perl5 $S/kern/makedevops.pl -h $S/kern/bus_if.m
+
+pci_if.h: $S/kern/makedevops.pl $S/pci/pci_if.m
+ perl5 $S/kern/makedevops.pl -h $S/pci/pci_if.m
+
+.include <bsd.kmod.mk>
OpenPOWER on IntegriCloud