1# $FreeBSD$ 2 3SYSDIR?=${.CURDIR}/.. 4.include "${SYSDIR}/conf/kern.opts.mk" 5 6SUBDIR_PARALLEL= 7 8# Modules that include binary-only blobs of microcode should be selectable by 9# MK_SOURCELESS_UCODE option (see below). 10 11.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES) 12SUBDIR=${MODULES_OVERRIDE} 13.else 14SUBDIR= \ 15 ${_3dfx} \ 16 ${_3dfx_linux} \ 17 ${_aac} \ 18 ${_aacraid} \ 19 accf_data \ 20 accf_dns \ 21 accf_http \ 22 acl_nfs4 \ 23 acl_posix1e \ 24 ${_acpi} \ 25 ae \ 26 ${_aesni} \ 27 age \ 28 ${_agp} \ 29 aha \ 30 ${_ahb} \ 31 ahci \ 32 ${_aic} \ 33 aic7xxx \ 34 aio \ 35 alc \ 36 ale \ 37 alq \ 38 ${_amdsbwd} \ 39 ${_amdtemp} \ 40 amr \ 41 ${_an} \ 42 ${_aout} \ 43 ${_apm} \ 44 ${_arcmsr} \ 45 ${_arcnet} \ 46 ${_asmc} \ 47 ${_asr} \ 48 ata \ 49 ath \ 50 ath_pci \ 51 autofs \ 52 ${_auxio} \ 53 ${_bce} \ 54 bfe \ 55 bge \ 56 ${_bxe} \ 57 ${_bios} \ 58 ${_bktr} \ 59 ${_bm} \ 60 bridgestp \ 61 bwi \ 62 bwn \ 63 cam \ 64 ${_canbepm} \ 65 ${_canbus} \ 66 ${_cardbus} \ 67 ${_carp} \ 68 cas \ 69 ${_cbb} \ 70 cc \ 71 cd9660 \ 72 cd9660_iconv \ 73 ${_ce} \ 74 ${_cfi} \ 75 ${_ciss} \ 76 ${_cm} \ 77 ${_cmx} \ 78 ${_coff} \ 79 ${_coretemp} \ 80 ${_cp} \ 81 ${_cpsw} \ 82 ${_cpuctl} \ 83 ${_cpufreq} \ 84 ${_crypto} \ 85 ${_cryptodev} \ 86 ${_cs} \ 87 ${_ct} \ 88 ${_ctau} \ 89 ctl \ 90 cuse \ 91 ${_cxgb} \ 92 ${_cxgbe} \ 93 ${_cyclic} \ 94 dc \ 95 dcons \ 96 dcons_crom \ 97 de \ 98 ${_dpms} \ 99 ${_dpt} \ 100 ${_drm} \ 101 ${_drm2} \ 102 ${_dtrace} \ 103 dummynet \ 104 ${_ed} \ 105 ${_elink} \ 106 ${_em} \ 107 en \ 108 ${_ep} \ 109 ${_epic} \ 110 esp \ 111 ${_et} \ 112 ${_ex} \ 113 ${_exca} \ 114 ${_ext2fs} \ 115 ${_fatm} \ 116 fdc \ 117 fdescfs \ 118 ${_fe} \ 119 ${_filemon} \ 120 firewire \ 121 firmware \ 122 fuse \ 123 ${_fxp} \ 124 gem \ 125 geom \ 126 ${_glxiic} \ 127 ${_glxsb} \ 128 hatm \ 129 hifn \ 130 hme \ 131 ${_hpt27xx} \ 132 ${_hptiop} \ 133 ${_hptmv} \ 134 ${_hptnr} \ 135 ${_hptrr} \ 136 hwpmc \ 137 ${_hyperv} \ 138 ${_i2c} \ 139 ${_ibcore} \ 140 ${_ibcs2} \ 141 ${_ichwd} \ 142 ${_ida} \ 143 ${_ie} \ 144 if_bridge \ 145 if_disc \ 146 if_edsc \ 147 if_epair \ 148 if_faith \ 149 if_gif \ 150 ${_if_gre} \ 151 if_lagg \ 152 ${_if_ndis} \ 153 if_stf \ 154 if_tap \ 155 if_tun \ 156 if_vlan \ 157 if_vxlan \ 158 ${_igb} \ 159 ${_iir} \ 160 imgact_binmisc \ 161 ${_io} \ 162 ${_ipoib} \ 163 ${_ipdivert} \ 164 ${_ipfilter} \ 165 ${_ipfw} \ 166 ipfw_nat \ 167 ${_ipmi} \ 168 ip6_mroute_mod \ 169 ip_mroute_mod \ 170 ${_ips} \ 171 ${_ipw} \ 172 ${_ipwfw} \ 173 ${_isci} \ 174 iscsi \ 175 iscsi_initiator \ 176 isp \ 177 ${_ispfw} \ 178 ${_iwi} \ 179 ${_iwifw} \ 180 ${_iwn} \ 181 ${_iwnfw} \ 182 ${_ixgb} \ 183 ${_ixgbe} \ 184 ${_ixl} \ 185 ${_ixlv} \ 186 jme \ 187 joy \ 188 kbdmux \ 189 kgssapi \ 190 kgssapi_krb5 \ 191 khelp \ 192 krpc \ 193 ksyms \ 194 le \ 195 lge \ 196 libalias \ 197 libiconv \ 198 libmbpool \ 199 libmchain \ 200 ${_linprocfs} \ 201 ${_linsysfs} \ 202 ${_linux} \ 203 lmc \ 204 lpt \ 205 mac_biba \ 206 mac_bsdextended \ 207 mac_ifoff \ 208 mac_lomac \ 209 mac_mls \ 210 mac_none \ 211 mac_partition \ 212 mac_portacl \ 213 mac_seeotheruids \ 214 mac_stub \ 215 mac_test \ 216 malo \ 217 mcd \ 218 md \ 219 mem \ 220 mfi \ 221 mii \ 222 mlx \ 223 ${_mlx4} \ 224 ${_mlx4ib} \ 225 ${_mlxen} \ 226 ${_mly} \ 227 mmc \ 228 mmcsd \ 229 mpr \ 230 mps \ 231 mpt \ 232 mqueue \ 233 mrsas \ 234 msdosfs \ 235 msdosfs_iconv \ 236 ${_mse} \ 237 msk \ 238 ${_mthca} \ 239 mvs \ 240 mwl \ 241 ${_mwlfw} \ 242 mxge \ 243 my \ 244 ${_nandfs} \ 245 ${_nandsim} \ 246 ${_ncr} \ 247 ${_ncv} \ 248 ${_ndis} \ 249 netfpga10g \ 250 ${_netgraph} \ 251 ${_nfe} \ 252 nfs_common \ 253 nfscl \ 254 nfsclient \ 255 nfscommon \ 256 nfsd \ 257 nfslock \ 258 nfslockd \ 259 nfsserver \ 260 nfssvc \ 261 nge \ 262 nmdm \ 263 ${_nsp} \ 264 nullfs \ 265 ${_ntb} \ 266 ${_nvd} \ 267 ${_nvme} \ 268 ${_nvram} \ 269 ${_nxge} \ 270 ${_opensolaris} \ 271 oce \ 272 ${_padlock} \ 273 patm \ 274 ${_pccard} \ 275 ${_pcfclock} \ 276 pcn \ 277 ${_pf} \ 278 ${_pflog} \ 279 ${_pfsync} \ 280 plip \ 281 ${_pmc} \ 282 ppbus \ 283 ppc \ 284 ppi \ 285 pps \ 286 procfs \ 287 proto \ 288 pseudofs \ 289 ${_pst} \ 290 pty \ 291 puc \ 292 ${_qlxge} \ 293 ${_qlxgb} \ 294 ${_qlxgbe} \ 295 ral \ 296 ${_ralfw} \ 297 ${_random} \ 298 rc4 \ 299 ${_rdma} \ 300 re \ 301 reiserfs \ 302 rl \ 303 ${_s3} \ 304 ${_safe} \ 305 ${_sbni} \ 306 scc \ 307 scd \ 308 ${_scsi_low} \ 309 sdhci \ 310 sdhci_pci \ 311 sem \ 312 send \ 313 ${_sf} \ 314 ${_sfxge} \ 315 sge \ 316 ${_si} \ 317 siba_bwn \ 318 siftr \ 319 siis \ 320 sis \ 321 sk \ 322 ${_smbfs} \ 323 ${_sn} \ 324 ${_snc} \ 325 snp \ 326 ${_sound} \ 327 ${_speaker} \ 328 ${_splash} \ 329 ${_sppp} \ 330 ste \ 331 ${_stg} \ 332 stge \ 333 ${_streams} \ 334 ${_svr4} \ 335 ${_sym} \ 336 ${_syscons} \ 337 sysvipc \ 338 ${_ti} \ 339 tl \ 340 tmpfs \ 341 ${_toecore} \ 342 ${_tpm} \ 343 trm \ 344 ${_twa} \ 345 twe \ 346 tws \ 347 tx \ 348 ${_txp} \ 349 uart \ 350 ubsec \ 351 udf \ 352 udf_iconv \ 353 ufs \ 354 unionfs \ 355 usb \ 356 utopia \ 357 ${_vesa} \ 358 ${_virtio} \ 359 vge \ 360 ${_viawd} \ 361 vkbd \ 362 ${_vmm} \ 363 ${_vmware} \ 364 ${_vpo} \ 365 vr \ 366 vte \ 367 vx \ 368 ${_vxge} \ 369 wb \ 370 ${_wbwd} \ 371 ${_wds} \ 372 ${_wi} \ 373 ${_wl} \ 374 wlan \ 375 wlan_acl \ 376 wlan_amrr \ 377 wlan_ccmp \ 378 wlan_rssadapt \ 379 wlan_tkip \ 380 wlan_wep \ 381 wlan_xauth \ 382 ${_wpi} \ 383 ${_wpifw} \ 384 ${_x86bios} \ 385 ${_xe} \ 386 xl \ 387 ${_zfs} \ 388 zlib 389 390.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 391.if exists(${.CURDIR}/../opencrypto) 392_crypto= crypto 393_cryptodev= cryptodev 394.endif 395.if exists(${.CURDIR}/../crypto) 396_random= random 397.endif 398.endif 399 400.if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \ 401 defined(ALL_MODULES) 402_carp= carp 403_toecore= toecore 404.endif 405 406.if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES) 407_if_gre= if_gre 408_ipdivert= ipdivert 409_ipfw= ipfw 410.endif 411 412.if ${MK_IPFILTER} != "no" || defined(ALL_MODULES) 413_ipfilter= ipfilter 414.endif 415 416.if ${MK_NAND} != "no" || defined(ALL_MODULES) 417_nandfs= nandfs 418_nandsim= nandsim 419.endif 420 421.if ${MK_NETGRAPH} != "no" || defined(ALL_MODULES) 422_netgraph= netgraph 423.endif 424 425.if (${MK_PF} != "no" && (${MK_INET_SUPPORT} != "no" || \ 426 ${MK_INET6_SUPPORT} != "no")) || defined(ALL_MODULES) 427_pf= pf 428_pflog= pflog 429.if ${MK_INET_SUPPORT} != "no" 430_pfsync= pfsync 431.endif 432.endif 433 434.if ${MK_SOURCELESS_UCODE} != "no" 435_bce= bce 436_cxgbe= cxgbe 437_fatm= fatm 438_fxp= fxp 439_ispfw= ispfw 440_mwlfw= mwlfw 441_ralfw= ralfw 442_sf= sf 443_sn= sn 444_ti= ti 445_txp= txp 446.endif 447 448 449.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" && \ 450 ${MACHINE_CPUARCH} != "powerpc" 451_syscons= syscons 452_vpo= vpo 453.endif 454 455.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" 456# no BUS_SPACE_UNSPECIFIED 457# No barrier instruction support (specific to this driver) 458_sym= sym 459# intr_disable() is a macro, causes problems 460.if ${MK_SOURCELESS_UCODE} != "no" 461_cxgb= cxgb 462.endif 463.endif 464 465.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" 466_agp= agp 467_an= an 468_aout= aout 469_bktr= bktr 470_bxe= bxe 471_cardbus= cardbus 472_cbb= cbb 473_cpuctl= cpuctl 474_cpufreq= cpufreq 475.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 476_cyclic= cyclic 477.endif 478_dpms= dpms 479_drm= drm 480_drm2= drm2 481.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 482_dtrace= dtrace 483.endif 484_ed= ed 485_em= em 486_et= et 487_exca= exca 488_ext2fs= ext2fs 489_filemon= filemon 490_i2c= i2c 491.if ${MK_OFED} != "no" || defined(ALL_MODULES) 492_ibcore= ibcore 493.endif 494_if_ndis= if_ndis 495_igb= igb 496_io= io 497.if ${MK_OFED} != "no" || defined(ALL_MODULES) 498_ipoib= ipoib 499.endif 500_linprocfs= linprocfs 501_linsysfs= linsysfs 502_linux= linux 503_ndis= ndis 504.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 505_opensolaris= opensolaris 506.endif 507_pccard= pccard 508.if ${MK_OFED} != "no" || defined(ALL_MODULES) 509_rdma= rdma 510.endif 511_safe= safe 512_scsi_low= scsi_low 513_si= si 514_smbfs= smbfs 515_sound= sound 516_speaker= speaker 517_splash= splash 518_sppp= sppp 519_vmware= vmware 520_vxge= vxge 521_wbwd= wbwd 522_wi= wi 523.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 524_zfs= zfs 525.endif 526.if ${MACHINE} != "pc98" 527_aac= aac 528_aacraid= aacraid 529_acpi= acpi 530.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 531_aesni= aesni 532.endif 533_amdsbwd= amdsbwd 534_amdtemp= amdtemp 535_arcmsr= arcmsr 536_asmc= asmc 537_ciss= ciss 538_cmx= cmx 539_coretemp= coretemp 540.if ${MK_SOURCELESS_HOST} != "no" 541_hpt27xx= hpt27xx 542.endif 543_hptiop= hptiop 544.if ${MK_SOURCELESS_HOST} != "no" 545_hptmv= hptmv 546_hptnr= hptnr 547_hptrr= hptrr 548.endif 549_hyperv= hyperv 550_ichwd= ichwd 551_ida= ida 552_iir= iir 553_ipmi= ipmi 554_ips= ips 555_ipw= ipw 556.if ${MK_SOURCELESS_UCODE} != "no" 557_ipwfw= ipwfw 558.endif 559_isci= isci 560_iwi= iwi 561.if ${MK_SOURCELESS_UCODE} != "no" 562_iwifw= iwifw 563.endif 564_iwn= iwn 565.if ${MK_SOURCELESS_UCODE} != "no" 566_iwnfw= iwnfw 567.endif 568_ixgb= ixgb 569_ixgbe= ixgbe 570.if ${MK_OFED} != "no" || defined(ALL_MODULES) 571_mlx4= mlx4 572_mlx4ib= mlx4ib 573_mlxen= mlxen 574.endif 575_mly= mly 576.if ${MK_OFED} != "no" || defined(ALL_MODULES) 577_mthca= mthca 578.endif 579_nfe= nfe 580_nvd= nvd 581_nvme= nvme 582_nvram= nvram 583_nxge= nxge 584.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 585_padlock= padlock 586.endif 587_s3= s3 588_tpm= tpm 589_twa= twa 590_vesa= vesa 591_viawd= viawd 592_virtio= virtio 593_wpi= wpi 594.if ${MK_SOURCELESS_UCODE} != "no" 595_wpifw= wpifw 596.endif 597_x86bios= x86bios 598.endif 599.endif 600 601.if ${MACHINE_CPUARCH} == "amd64" 602_ixl= ixl 603_ixlv= ixlv 604_ntb= ntb 605_qlxge= qlxge 606_qlxgb= qlxgb 607_qlxgbe= qlxgbe 608_sfxge= sfxge 609_vmm= vmm 610.endif 611 612.if ${MACHINE_CPUARCH} == "i386" 613# XXX some of these can move to the general case when de-i386'ed 614# XXX some of these can move now, but are untested on other architectures. 615_3dfx= 3dfx 616_3dfx_linux= 3dfx_linux 617_aic= aic 618_apm= apm 619_arcnet= arcnet 620.if ${MK_SOURCELESS_UCODE} != "no" 621_ce= ce 622.endif 623_coff= coff 624.if ${MK_SOURCELESS_UCODE} != "no" 625_cp= cp 626.endif 627_cs= cs 628_elink= elink 629_ep= ep 630_fe= fe 631_glxiic= glxiic 632_glxsb= glxsb 633_ibcs2= ibcs2 634_ie= ie 635_mse= mse 636_ncr= ncr 637_ncv= ncv 638_nsp= nsp 639_pcfclock= pcfclock 640_pst= pst 641_sbni= sbni 642_streams= streams 643_stg= stg 644_svr4= svr4 645_wds= wds 646_xe= xe 647.if ${MACHINE} == "i386" 648.if ${MK_EISA} != "no" 649_ahb= ahb 650.endif 651_asr= asr 652_bios= bios 653_cm= cm 654.if ${MK_SOURCELESS_UCODE} != "no" 655_ctau= ctau 656.endif 657_dpt= dpt 658_ex= ex 659_wl= wl 660.elif ${MACHINE} == "pc98" 661_canbepm= canbepm 662_canbus= canbus 663_ct= ct 664_pmc= pmc 665_snc= snc 666.endif 667.endif 668 669.if ${MACHINE_CPUARCH} == "arm" 670_cfi= cfi 671_cpsw= cpsw 672_sound= sound 673.endif 674 675.if ${MACHINE_CPUARCH} == "powerpc" 676_agp= agp 677_an= an 678_bm= bm 679_cardbus= cardbus 680_cbb= cbb 681_cfi= cfi 682_cpufreq= cpufreq 683.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 684_cyclic= cyclic 685.endif 686_drm= drm 687.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 688_dtrace= dtrace 689.endif 690_exca= exca 691_nvram= powermac_nvram 692.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 693_opensolaris= opensolaris 694.endif 695_pccard= pccard 696_smbfs= smbfs 697_sound= sound 698_wi= wi 699.endif 700 701.if ${MACHINE_ARCH} == "powerpc64" 702.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 703_zfs= zfs 704.endif 705.endif 706 707.if ${MACHINE_CPUARCH} == "sparc64" 708_auxio= auxio 709_em= em 710_epic= epic 711_i2c= i2c 712_igb= igb 713.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 714_opensolaris= opensolaris 715.endif 716_smbfs= smbfs 717_sound= sound 718.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 719_zfs= zfs 720.endif 721.endif 722 723.endif 724 725.for reject in ${WITHOUT_MODULES} 726SUBDIR:= ${SUBDIR:N${reject}} 727.endfor 728 729# Calling kldxref(8) for each module is expensive. 730.if !defined(NO_XREF) 731.MAKEFLAGS+= -DNO_XREF 732afterinstall: 733 @if type kldxref >/dev/null 2>&1; then \ 734 ${ECHO} kldxref ${DESTDIR}${KMODDIR}; \ 735 kldxref ${DESTDIR}${KMODDIR}; \ 736 fi 737.endif 738 739.include <bsd.subdir.mk> 740