Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F146363338
D1530.id3187.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
5 KB
Referenced Files
None
Subscribers
None
D1530.id3187.diff
View Options
Index: sys/conf/kmod.mk
===================================================================
--- sys/conf/kmod.mk
+++ sys/conf/kmod.mk
@@ -331,6 +331,10 @@
opt_inet6.h:
@echo "#define INET6 1" > ${.TARGET}
.endif
+.if ${MK_EISA} != "no"
+opt_eisa.h:
+ @echo "#define DEV_EISA 1" > ${.TARGET}
+.endif
opt_mrouting.h:
echo "#define MROUTING 1" > ${.TARGET}
opt_natm.h:
@@ -341,7 +345,28 @@
echo "#define IEEE80211_DEBUG 1" > ${.TARGET}
echo "#define IEEE80211_AMPDU_AGE 1" >> ${.TARGET}
echo "#define IEEE80211_SUPPORT_MESH 1" >> ${.TARGET}
+KERN_OPTS.i386=NEW_PCIB DEV_PCI
+KERN_OPTS.pc98=NEW_PCIB DEV_PCI
+KERN_OPTS.amd64=NEW_PCIB DEV_PCI
+KERN_OPTS.powerpc=NEW_PCIB DEV_PCI
+KERN_OPTS=MROUTING NATM IEEE80211_DEBUG \
+ IEEE80211_AMPDU_AGE IEEE80211_SUPPORT_MESH DEV_BPF \
+ ${KERN_OPTS.${MACHINE}} ${KERN_OPTS_EXTRA}
+.if ${MK_INET_SUPPORT} != "no"
+KERN_OPTS+= INET TCP_OFFLOAD
.endif
+.if ${MK_INET6_SUPPORT} != "no"
+KERN_OPTS+= INET6
+.endif
+.if ${MK_EISA} != "no"
+KERN_OPTS+= DEV_EISA
+.endif
+.else
+KERN_OPTS!=cat ${KERNBUILDDIR}/opt*.h | awk '{print $2;}' | sort -u
+.endif
+.for _o in ${KERN_OPTS}
+SRCS+=${SRCS.${_o}}
+.endfor
.if defined(KERNBUILDDIR)
.PATH: ${KERNBUILDDIR}
Index: sys/conf/options
===================================================================
--- sys/conf/options
+++ sys/conf/options
@@ -397,6 +397,7 @@
BOOTP_WIRED_TO opt_bootp.h
DEVICE_POLLING
DEV_ENC opt_enc.h
+DEV_PCI opt_global.h
DEV_PF opt_pf.h
DEV_PFLOG opt_pf.h
DEV_PFSYNC opt_pf.h
Index: sys/modules/dpt/Makefile
===================================================================
--- sys/modules/dpt/Makefile
+++ sys/modules/dpt/Makefile
@@ -11,24 +11,6 @@
opt_cam.h opt_scsi.h \
device_if.h bus_if.h
-.if ${MK_EISA} == "no"
-# Create an empty opt_eisa.h in order to keep kmod.mk from linking in an
-# existing one from KERNBUILDDIR which possibly has DEV_EISA defined so
-# dpt.ko is always built without EISA support.
-opt_eisa.h:
- :> ${.TARGET}
-.else
-.if !defined(KERNBUILDDIR)
-SRCS+= dpt_eisa.c eisa_if.h
-
-opt_eisa.h:
- echo "#define DEV_EISA 1" > ${.TARGET}
-.else
-DEV_EISA!= sed -n '/DEV_EISA/p' ${KERNBUILDDIR}/opt_eisa.h
-.if !empty(DEV_EISA)
-SRCS+= dpt_eisa.c eisa_if.h
-.endif
-.endif
-.endif
+SRCS.DEV_EISA= dpt_eisa.c eisa_if.h
.include <bsd.kmod.mk>
Index: sys/modules/ed/Makefile
===================================================================
--- sys/modules/ed/Makefile
+++ sys/modules/ed/Makefile
@@ -8,10 +8,13 @@
.if ${MACHINE} == "pc98"
SRCS+= if_ed_cbus.c
.else
-SRCS+= if_ed_isa.c if_ed_3c503.c if_ed_hpp.c if_ed_sic.c
+SRCS+= if_ed_isa.c
+SRCS.ED_HPP=if_ed_hpp.c
+SRCS.ED_SIC=if_ed_sic.c
+SRCS.ED_3C503=if_ed_3c503.c
.endif
SRCS+= if_ed_pccard.c pccarddevs.h card_if.h
-SRCS+= if_ed_pci.c pci_if.h
+SRCS.DEV_PCI=if_ed_pci.c pci_if.h
SRCS+= opt_ed.h bus_if.h device_if.h miibus_if.h
Index: sys/modules/ep/Makefile
===================================================================
--- sys/modules/ep/Makefile
+++ sys/modules/ep/Makefile
@@ -9,10 +9,7 @@
SRCS= if_ep.c
SRCS+= if_ep_pccard.c pccarddevs.h card_if.h
SRCS+= if_ep_isa.c isa_if.h
-.if ${MK_EISA} != "no"
-SRCS+= if_ep_eisa.c eisa_if.h
-.endif
-#SRCS+= if_ep_mca.c
+SRCS.DEV_EISA= if_ep_eisa.c eisa_if.h
SRCS+= bus_if.h device_if.h
.include <bsd.kmod.mk>
Index: sys/modules/if_gif/Makefile
===================================================================
--- sys/modules/if_gif/Makefile
+++ sys/modules/if_gif/Makefile
@@ -8,12 +8,12 @@
KMOD= if_gif
SRCS= if_gif.c opt_inet.h opt_inet6.h
-.if ${MK_INET_SUPPORT} != "no"
+.include <bsd.kmod.mk>
+
+.if ${KERN_OPTS:MINET} != ""
SRCS+= in_gif.c
.endif
-.if ${MK_INET6_SUPPORT} != "no"
+.if ${KERN_OPTS:MINET6} != ""
SRCS+= in6_gif.c
.endif
-
-.include <bsd.kmod.mk>
Index: sys/modules/if_gre/Makefile
===================================================================
--- sys/modules/if_gre/Makefile
+++ sys/modules/if_gre/Makefile
@@ -6,13 +6,7 @@
KMOD= if_gre
SRCS= if_gre.c opt_inet.h opt_inet6.h
-
-.if ${MK_INET_SUPPORT} != "no"
-SRCS+= ip_gre.c
-.endif
-
-.if ${MK_INET6_SUPPORT} != "no"
-SRCS+= ip6_gre.c
-.endif
+SRCS.INET= ip_gre.c
+SRCS.INET6= ip6_gre.c
.include <bsd.kmod.mk>
Index: sys/modules/si/Makefile
===================================================================
--- sys/modules/si/Makefile
+++ sys/modules/si/Makefile
@@ -3,8 +3,9 @@
.PATH: ${.CURDIR}/../../dev/si
KMOD= si
-SRCS= si.c si2_z280.c si3_t225.c si_eisa.c si_isa.c si_pci.c
-SRCS+= bus_if.h device_if.h eisa_if.h isa_if.h pci_if.h
+SRCS= si.c si2_z280.c si3_t225.c si_isa.c si_pci.c
+SRCS+= bus_if.h device_if.h isa_if.h pci_if.h
SRCS+= opt_compat.h opt_debug_si.h opt_eisa.h
+SRCS.DEV_EISA=si_eisa.c eisa_if.h
.include <bsd.kmod.mk>
Index: sys/modules/vx/Makefile
===================================================================
--- sys/modules/vx/Makefile
+++ sys/modules/vx/Makefile
@@ -7,9 +7,7 @@
KMOD= if_vx
SRCS= if_vx.c if_vx_pci.c
-.if ${MK_EISA} != "no"
-SRCS+= if_vx_eisa.c
-.endif
-SRCS+= device_if.h bus_if.h pci_if.h eisa_if.h
+SRCS.DEV_EISA= if_vx_eisa.c eisa_if.h
+SRCS+= device_if.h bus_if.h pci_if.h
.include <bsd.kmod.mk>
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Mar 3, 2:30 AM (3 h, 4 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29178513
Default Alt Text
D1530.id3187.diff (5 KB)
Attached To
Mode
D1530: Make kernel config options available to module load, and use them to solve some problems.
Attached
Detach File
Event Timeline
Log In to Comment