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