Page MenuHomeFreeBSD

D2327.diff
No OneTemporary

D2327.diff

Index: head/sys/conf/kmod.mk
===================================================================
--- head/sys/conf/kmod.mk
+++ head/sys/conf/kmod.mk
@@ -28,9 +28,6 @@
#
# KMODUNLOAD Command to unload a kernel module [/sbin/kldunload]
#
-# MFILES Optionally a list of interfaces used by the module.
-# This file contains a default list of interfaces.
-#
# PROG The name of the kernel module to build.
# If not supplied, ${KMOD}.ko is used.
#
@@ -72,7 +69,7 @@
.include <bsd.compiler.mk>
.include "config.mk"
-.SUFFIXES: .out .o .c .cc .cxx .C .y .l .s .S
+.SUFFIXES: .out .o .c .cc .cxx .C .y .l .s .S .m
# amd64 and mips use direct linking for kmod, all others use shared binaries
.if ${MACHINE_CPUARCH} != amd64 && ${MACHINE_CPUARCH} != mips
@@ -339,37 +336,6 @@
# Respect configuration-specific C flags.
CFLAGS+= ${CONF_CFLAGS}
-MFILES?= dev/acpica/acpi_if.m dev/acpi_support/acpi_wmi_if.m \
- dev/agp/agp_if.m dev/ata/ata_if.m dev/eisa/eisa_if.m \
- dev/fb/fb_if.m dev/gpio/gpio_if.m dev/gpio/gpiobus_if.m \
- dev/iicbus/iicbb_if.m dev/iicbus/iicbus_if.m \
- dev/mbox/mbox_if.m dev/mmc/mmcbr_if.m dev/mmc/mmcbus_if.m \
- dev/mii/miibus_if.m dev/mvs/mvs_if.m dev/ofw/ofw_bus_if.m \
- dev/pccard/card_if.m dev/pccard/power_if.m dev/pci/pci_if.m \
- dev/pci/pci_iov_if.m dev/pci/pcib_if.m dev/ppbus/ppbus_if.m \
- dev/sdhci/sdhci_if.m dev/smbus/smbus_if.m dev/spibus/spibus_if.m \
- dev/sound/pci/hda/hdac_if.m \
- dev/sound/pcm/ac97_if.m dev/sound/pcm/channel_if.m \
- dev/sound/pcm/feeder_if.m dev/sound/pcm/mixer_if.m \
- dev/sound/midi/mpu_if.m dev/sound/midi/mpufoi_if.m \
- dev/sound/midi/synth_if.m dev/usb/usb_if.m isa/isa_if.m \
- kern/bus_if.m kern/clock_if.m \
- kern/cpufreq_if.m kern/device_if.m kern/serdev_if.m \
- libkern/iconv_converter_if.m opencrypto/cryptodev_if.m \
- pc98/pc98/canbus_if.m dev/etherswitch/mdio_if.m
-
-.for _srcsrc in ${MFILES}
-.for _ext in c h
-.for _src in ${SRCS:M${_srcsrc:T:R}.${_ext}}
-CLEANFILES+= ${_src}
-.if !target(${_src})
-${_src}: ${SYSDIR}/tools/makeobjops.awk ${SYSDIR}/${_srcsrc}
- ${AWK} -f ${SYSDIR}/tools/makeobjops.awk ${SYSDIR}/${_srcsrc} -${_ext}
-.endif
-.endfor # _src
-.endfor # _ext
-.endfor # _srcsrc
-
.if !empty(SRCS:Mvnode_if.c)
CLEANFILES+= vnode_if.c
vnode_if.c: ${SYSDIR}/tools/vnode_if.awk ${SYSDIR}/kern/vnode_if.src
@@ -388,6 +354,21 @@
${AWK} -f ${SYSDIR}/tools/vnode_if.awk ${SYSDIR}/kern/vnode_if.src -q
.endif
+# Build _if.[ch] from _if.m, and clean them when we're done.
+__MPATH!=find ${SYSDIR:tA}/ -name \*_if.m
+_MPATH=${__MPATH:H:O:u}
+.PATH.m: ${_MPATH}
+.for _s in ${SRCS:M*_if.[ch]}
+.if eixsts(${_s:R}.m})
+CLEANFILES+= ${_s}
+.endif
+.endfor # _s
+.m.c: ${SYSDIR}/tools/makeobjops.awk
+ ${AWK} -f ${SYSDIR}/tools/makeobjops.awk ${.IMPSRC} -c
+
+.m.h: ${SYSDIR}/tools/makeobjops.awk
+ ${AWK} -f ${SYSDIR}/tools/makeobjops.awk ${.IMPSRC} -h
+
.for _i in mii pccard
.if !empty(SRCS:M${_i}devs.h)
CLEANFILES+= ${_i}devs.h
Index: head/sys/modules/agp/Makefile
===================================================================
--- head/sys/modules/agp/Makefile
+++ head/sys/modules/agp/Makefile
@@ -19,7 +19,6 @@
.endif
SRCS+= device_if.h bus_if.h agp_if.h pci_if.h
SRCS+= opt_agp.h
-MFILES= kern/device_if.m kern/bus_if.m dev/agp/agp_if.m dev/pci/pci_if.m
EXPORT_SYMS= agp_find_device \
agp_state \
Index: head/sys/modules/geom/geom_part/geom_part_apm/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_apm/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_apm/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_bsd/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_bsd/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_bsd/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_bsd64/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_bsd64/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_bsd64/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_ebr/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_ebr/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_ebr/Makefile
@@ -8,6 +8,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
SRCS+= opt_geom.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_gpt/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_gpt/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_gpt/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_ldm/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_ldm/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_ldm/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_mbr/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_mbr/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_mbr/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_pc98/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_pc98/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_pc98/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_part/geom_part_vtoc8/Makefile
===================================================================
--- head/sys/modules/geom/geom_part/geom_part_vtoc8/Makefile
+++ head/sys/modules/geom/geom_part/geom_part_vtoc8/Makefile
@@ -7,6 +7,4 @@
SRCS+= bus_if.h device_if.h g_part_if.h
-MFILES= kern/bus_if.m kern/device_if.m geom/part/g_part_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/geom/geom_raid/Makefile
===================================================================
--- head/sys/modules/geom/geom_raid/Makefile
+++ head/sys/modules/geom/geom_raid/Makefile
@@ -13,7 +13,4 @@
SRCS+= tr_concat.c tr_raid0.c tr_raid1.c tr_raid1e.c tr_raid5.c
-MFILES= kern/bus_if.m kern/device_if.m
-MFILES+= geom/raid/g_raid_md_if.m geom/raid/g_raid_tr_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/kgssapi/Makefile
===================================================================
--- head/sys/modules/kgssapi/Makefile
+++ head/sys/modules/kgssapi/Makefile
@@ -36,7 +36,6 @@
svc_rpcsec_gss.c
SRCS+= kgss_if.h kgss_if.c
-MFILES= kgssapi/kgss_if.m
SRCS+= gssd.h gssd_xdr.c gssd_clnt.c
CLEANFILES= gssd.h gssd_xdr.c gssd_clnt.c
Index: head/sys/modules/kgssapi_krb5/Makefile
===================================================================
--- head/sys/modules/kgssapi_krb5/Makefile
+++ head/sys/modules/kgssapi_krb5/Makefile
@@ -12,7 +12,6 @@
opt_inet6.h
SRCS+= kgss_if.h gssd.h
-MFILES= kgssapi/kgss_if.m
CLEANFILES= gssd.h
S= ${.CURDIR}/../..
Index: head/sys/modules/ksyms/Makefile
===================================================================
--- head/sys/modules/ksyms/Makefile
+++ head/sys/modules/ksyms/Makefile
@@ -5,6 +5,4 @@
KMOD= ksyms
SRCS= ksyms.c linker_if.h
-MFILES= kern/linker_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/libiconv/Makefile
===================================================================
--- head/sys/modules/libiconv/Makefile
+++ head/sys/modules/libiconv/Makefile
@@ -6,7 +6,6 @@
SRCS= iconv.c iconv_ucs.c iconv_xlat.c iconv_xlat16.c
SRCS+= iconv.h
SRCS+= iconv_converter_if.c iconv_converter_if.h
-MFILES= libkern/iconv_converter_if.m
EXPORT_SYMS= iconv_add \
iconv_open \
Index: head/sys/modules/mvs/Makefile
===================================================================
--- head/sys/modules/mvs/Makefile
+++ head/sys/modules/mvs/Makefile
@@ -5,6 +5,4 @@
KMOD= mvs
SRCS= mvs.c mvs_pci.c mvs.h mvs_if.c mvs_if.h device_if.h bus_if.h pci_if.h opt_cam.h
-MFILES= kern/bus_if.m kern/device_if.m dev/pci/pci_if.m dev/mvs/mvs_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/nand/Makefile
===================================================================
--- head/sys/modules/nand/Makefile
+++ head/sys/modules/nand/Makefile
@@ -7,7 +7,4 @@
nand_id.c nandbus.c nandbus_if.c nand_if.c nfc_if.c \
nand_if.h device_if.h bus_if.h nfc_if.h nandbus_if.h
-MFILES= kern/bus_if.m kern/device_if.m dev/nand/nfc_if.m \
- dev/nand/nand_if.m dev/nand/nandbus_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/nandsim/Makefile
===================================================================
--- head/sys/modules/nandsim/Makefile
+++ head/sys/modules/nandsim/Makefile
@@ -5,7 +5,5 @@
KMOD= nandsim
SRCS= nandsim.c nandsim_chip.c nandsim_swap.c nandsim_ctrl.c nandsim_log.c\
bus_if.h device_if.h vnode_if.h nfc_if.h nand_if.h
-MFILES= kern/bus_if.m kern/device_if.m\
- dev/nand/nfc_if.m dev/nand/nand_if.m
.include <bsd.kmod.mk>
Index: head/sys/modules/proto/Makefile
===================================================================
--- head/sys/modules/proto/Makefile
+++ head/sys/modules/proto/Makefile
@@ -15,10 +15,4 @@
isa_if.h \
pci_if.h
-MFILES= \
- dev/pci/pci_if.m \
- isa/isa_if.m \
- kern/bus_if.m \
- kern/device_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/puc/Makefile
===================================================================
--- head/sys/modules/puc/Makefile
+++ head/sys/modules/puc/Makefile
@@ -8,7 +8,4 @@
SRCS+= bus_if.h device_if.h serdev_if.c serdev_if.h \
card_if.h pci_if.h
-MFILES= kern/bus_if.m kern/device_if.m kern/serdev_if.m \
- dev/pccard/card_if.m dev/pci/pci_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/scc/Makefile
===================================================================
--- head/sys/modules/scc/Makefile
+++ head/sys/modules/scc/Makefile
@@ -14,7 +14,4 @@
scc_dev_sab82532.c scc_dev_z8530.c
SRCS+= bus_if.h device_if.h ofw_bus_if.h serdev_if.c serdev_if.h
-MFILES= dev/ofw/ofw_bus_if.m dev/scc/scc_if.m \
- kern/bus_if.m kern/device_if.m kern/serdev_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/uart/Makefile
===================================================================
--- head/sys/modules/uart/Makefile
+++ head/sys/modules/uart/Makefile
@@ -36,8 +36,4 @@
power_if.h pccarddevs.h serdev_if.h
SRCS+= opt_platform.h
-MFILES= dev/pccard/card_if.m dev/pccard/power_if.m dev/pci/pci_if.m \
- dev/ofw/ofw_bus_if.m dev/uart/uart_if.m isa/isa_if.m kern/bus_if.m \
- kern/device_if.m kern/serdev_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/balloon/Makefile
===================================================================
--- head/sys/modules/virtio/balloon/Makefile
+++ head/sys/modules/virtio/balloon/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/block/Makefile
===================================================================
--- head/sys/modules/virtio/block/Makefile
+++ head/sys/modules/virtio/block/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/console/Makefile
===================================================================
--- head/sys/modules/virtio/console/Makefile
+++ head/sys/modules/virtio/console/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/network/Makefile
===================================================================
--- head/sys/modules/virtio/network/Makefile
+++ head/sys/modules/virtio/network/Makefile
@@ -31,7 +31,4 @@
SRCS+= bus_if.h device_if.h
SRCS+= opt_inet.h opt_inet6.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/pci/Makefile
===================================================================
--- head/sys/modules/virtio/pci/Makefile
+++ head/sys/modules/virtio/pci/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h pci_if.h
-MFILES= kern/bus_if.m kern/device_if.m dev/pci/pci_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/random/Makefile
===================================================================
--- head/sys/modules/virtio/random/Makefile
+++ head/sys/modules/virtio/random/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/scsi/Makefile
===================================================================
--- head/sys/modules/virtio/scsi/Makefile
+++ head/sys/modules/virtio/scsi/Makefile
@@ -30,7 +30,4 @@
SRCS+= virtio_bus_if.h virtio_if.h
SRCS+= bus_if.h device_if.h opt_scsi.h opt_cam.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>
Index: head/sys/modules/virtio/virtio/Makefile
===================================================================
--- head/sys/modules/virtio/virtio/Makefile
+++ head/sys/modules/virtio/virtio/Makefile
@@ -32,7 +32,4 @@
SRCS+= virtio_if.c virtio_if.h
SRCS+= bus_if.h device_if.h
-MFILES= kern/bus_if.m kern/device_if.m \
- dev/virtio/virtio_bus_if.m dev/virtio/virtio_if.m
-
.include <bsd.kmod.mk>

File Metadata

Mime Type
text/plain
Expires
Mon, Feb 3, 2:40 PM (20 h, 37 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16436156
Default Alt Text
D2327.diff (14 KB)

Event Timeline