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 ${_igb} \ 158 ${_iir} \ 159 imgact_binmisc \ 160 ${_io} \ 161 ${_ipoib} \ 162 ${_ipdivert} \ 163 ${_ipfilter} \ 164 ${_ipfw} \ 165 ipfw_nat \ 166 ${_ipmi} \ 167 ip6_mroute_mod \ 168 ip_mroute_mod \ 169 ${_ips} \ 170 ${_ipw} \ 171 ${_ipwfw} \ 172 ${_isci} \ 173 iscsi \ 174 iscsi_initiator \ 175 isp \ 176 ${_ispfw} \ 177 ${_iwi} \ 178 ${_iwifw} \ 179 ${_iwn} \ 180 ${_iwnfw} \ 181 ${_ixgb} \ 182 ${_ixgbe} \ 183 jme \ 184 joy \ 185 kbdmux \ 186 kgssapi \ 187 kgssapi_krb5 \ 188 khelp \ 189 krpc \ 190 ksyms \ 191 le \ 192 lge \ 193 libalias \ 194 libiconv \ 195 libmbpool \ 196 libmchain \ 197 ${_linprocfs} \ 198 ${_linsysfs} \ 199 ${_linux} \ 200 lmc \ 201 lpt \ 202 mac_biba \ 203 mac_bsdextended \ 204 mac_ifoff \ 205 mac_lomac \ 206 mac_mls \ 207 mac_none \ 208 mac_partition \ 209 mac_portacl \ 210 mac_seeotheruids \ 211 mac_stub \ 212 mac_test \ 213 malo \ 214 mcd \ 215 md \ 216 mem \ 217 mfi \ 218 mii \ 219 mlx \ 220 ${_mlx4} \ 221 ${_mlx4ib} \ 222 ${_mlxen} \ 223 ${_mly} \ 224 mmc \ 225 mmcsd \ 226 mpr \ 227 mps \ 228 mpt \ 229 mqueue \ 230 mrsas \ 231 msdosfs \ 232 msdosfs_iconv \ 233 ${_mse} \ 234 msk \ 235 ${_mthca} \ 236 mvs \ 237 mwl \ 238 ${_mwlfw} \ 239 mxge \ 240 my \ 241 ${_nandfs} \ 242 ${_nandsim} \ 243 ${_ncp} \ 244 ${_ncv} \ 245 ${_ndis} \ 246 netfpga10g \ 247 ${_netgraph} \ 248 ${_nfe} \ 249 nfs_common \ 250 nfscl \ 251 nfsclient \ 252 nfscommon \ 253 nfsd \ 254 nfslock \ 255 nfslockd \ 256 nfsserver \ 257 nfssvc \ 258 nge \ 259 nmdm \ 260 ${_nsp} \ 261 nullfs \ 262 ${_ntb} \ 263 ${_nvd} \ 264 ${_nvme} \ 265 ${_nvram} \ 266 ${_nxge} \ 267 ${_opensolaris} \ 268 oce \ 269 ${_padlock} \ 270 patm \ 271 ${_pccard} \ 272 ${_pcfclock} \ 273 pcn \ 274 ${_pf} \ 275 ${_pflog} \ 276 ${_pfsync} \ 277 plip \ 278 ${_pmc} \ 279 ppbus \ 280 ppc \ 281 ppi \ 282 pps \ 283 procfs \ 284 proto \ 285 pseudofs \ 286 ${_pst} \ 287 pty \ 288 puc \ 289 ${_qlxge} \ 290 ${_qlxgb} \ 291 ${_qlxgbe} \ 292 ral \ 293 ${_ralfw} \ 294 ${_random} \ 295 rc4 \ 296 ${_rdma} \ 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 ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64" 388_filemon= filemon 389_vmware= vmware 390.endif 391 392.if ${MACHINE_CPUARCH} != "powerpc" && ${MACHINE_CPUARCH} != "arm" && \ 393 ${MACHINE_CPUARCH} != "mips" 394_syscons= syscons 395_vpo= vpo 396.endif 397 398.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" 399# no BUS_SPACE_UNSPECIFIED 400# No barrier instruction support (specific to this driver) 401_sym= sym 402# intr_disable() is a macro, causes problems 403.if ${MK_SOURCELESS_UCODE} != "no" 404_cxgb= cxgb 405.endif 406.endif 407 408.if ${MK_SOURCELESS_UCODE} != "no" 409_cxgbe= cxgbe 410.endif 411 412.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 413.if exists(${.CURDIR}/../opencrypto) 414_crypto= crypto 415_cryptodev= cryptodev 416.endif 417.if exists(${.CURDIR}/../crypto) 418_random= random 419.endif 420.endif 421 422.if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \ 423 defined(ALL_MODULES) 424_carp= carp 425_toecore= toecore 426.endif 427 428.if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES) 429_if_gre= if_gre 430.endif 431 432.if ${MK_IPFILTER} != "no" || defined(ALL_MODULES) 433_ipfilter= ipfilter 434.endif 435 436.if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES) 437_ipdivert= ipdivert 438_ipfw= ipfw 439.endif 440 441.if ${MK_NAND} != "no" || defined(ALL_MODULES) 442_nandfs= nandfs 443_nandsim= nandsim 444.endif 445 446.if ${MK_NETGRAPH} != "no" || defined(ALL_MODULES) 447_netgraph= netgraph 448.endif 449 450.if (${MK_PF} != "no" && (${MK_INET_SUPPORT} != "no" || \ 451 ${MK_INET6_SUPPORT} != "no")) || defined(ALL_MODULES) 452_pf= pf 453_pflog= pflog 454.if ${MK_INET_SUPPORT} != "no" 455_pfsync= pfsync 456.endif 457.endif 458 459.if ${MK_SOURCELESS_UCODE} != "no" 460_bce= bce 461_fatm= fatm 462_fxp= fxp 463_ispfw= ispfw 464_mwlfw= mwlfw 465_ralfw= ralfw 466_sf= sf 467_sn= sn 468_ti= ti 469_txp= txp 470.endif 471 472.if ${MACHINE_CPUARCH} == "i386" 473# XXX some of these can move to the general case when de-i386'ed 474# XXX some of these can move now, but are untested on other architectures. 475_3dfx= 3dfx 476_3dfx_linux= 3dfx_linux 477_agp= agp 478_aic= aic 479_an= an 480_aout= aout 481_apm= apm 482_arcnet= arcnet 483_bktr= bktr 484_bxe= bxe 485_cardbus= cardbus 486_cbb= cbb 487.if ${MK_SOURCELESS_UCODE} != "no" 488_ce= ce 489.endif 490_coff= coff 491.if ${MK_SOURCELESS_UCODE} != "no" 492_cp= cp 493.endif 494_cpuctl= cpuctl 495_cpufreq= cpufreq 496_cs= cs 497.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 498_cyclic= cyclic 499.endif 500_dpms= dpms 501_drm= drm 502_drm2= drm2 503.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 504_dtrace= dtrace 505.endif 506_ed= ed 507_elink= elink 508_em= em 509_ep= ep 510_et= et 511_exca= exca 512_ext2fs= ext2fs 513_fe= fe 514_glxiic= glxiic 515_glxsb= glxsb 516_i2c= i2c 517.if ${MK_OFED} != "no" || defined(ALL_MODULES) 518_ibcore= ibcore 519.endif 520_ibcs2= ibcs2 521_ie= ie 522_if_ndis= if_ndis 523_igb= igb 524_io= io 525.if ${MK_OFED} != "no" || defined(ALL_MODULES) 526_ipoib= ipoib 527.endif 528_linprocfs= linprocfs 529_linsysfs= linsysfs 530_linux= linux 531_mse= mse 532.if ${MK_OFED} != "no" || defined(ALL_MODULES) 533_mlx4= mlx4 534_mlx4ib= mlx4ib 535_mlxen= mlxen 536_mthca= mthca 537.endif 538_ncv= ncv 539_ndis= ndis 540_nsp= nsp 541.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 542_opensolaris= opensolaris 543.endif 544_pccard= pccard 545_pcfclock= pcfclock 546_pst= pst 547.if ${MK_OFED} != "no" || defined(ALL_MODULES) 548_rdma= rdma 549.endif 550_safe= safe 551_sbni= sbni 552_scsi_low= scsi_low 553_si= si 554_smbfs= smbfs 555_sound= sound 556_speaker= speaker 557_splash= splash 558_sppp= sppp 559_stg= stg 560_streams= streams 561_svr4= svr4 562_vxge= vxge 563_wbwd= wbwd 564_wds= wds 565_wi= wi 566_xe= xe 567.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 568_zfs= zfs 569.endif 570.if ${MACHINE} == "i386" 571_aac= aac 572_aacraid= aacraid 573_acpi= acpi 574.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 575_aesni= aesni 576.endif 577.if ${MK_EISA} != "no" 578_ahb= ahb 579.endif 580_amdsbwd= amdsbwd 581_amdtemp= amdtemp 582_arcmsr= arcmsr 583_asmc= asmc 584_asr= asr 585_bios= bios 586_ciss= ciss 587_cm= cm 588_cmx= cmx 589_coretemp= coretemp 590.if ${MK_SOURCELESS_UCODE} != "no" 591_ctau= ctau 592.endif 593_dpt= dpt 594_ex= ex 595.if ${MK_SOURCELESS_HOST} != "no" 596_hpt27xx= hpt27xx 597.endif 598_hptiop= hptiop 599.if ${MK_SOURCELESS_HOST} != "no" 600_hptmv= hptmv 601_hptnr= hptnr 602_hptrr= hptrr 603.endif 604_hyperv= hyperv 605_ichwd= ichwd 606_ida= ida 607_iir= iir 608_ipmi= ipmi 609_ips= ips 610_ipw= ipw 611.if ${MK_SOURCELESS_UCODE} != "no" 612_ipwfw= ipwfw 613.endif 614_isci= isci 615_iwi= iwi 616.if ${MK_SOURCELESS_UCODE} != "no" 617_iwifw= iwifw 618.endif 619_iwn= iwn 620.if ${MK_SOURCELESS_UCODE} != "no" 621_iwnfw= iwnfw 622.endif 623_ixgb= ixgb 624_ixgbe= ixgbe 625_mly= mly 626_nfe= nfe 627_nvd= nvd 628_nvme= nvme 629_nvram= nvram 630_nxge= nxge 631_tpm= tpm 632_viawd= viawd 633_wl= wl 634_wpi= wpi 635.if ${MK_SOURCELESS_UCODE} != "no" 636_wpifw= wpifw 637.endif 638.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 639_padlock= padlock 640.endif 641_s3= s3 642_twa= twa 643_vesa= vesa 644_virtio= virtio 645_x86bios= x86bios 646.elif ${MACHINE} == "pc98" 647_canbepm= canbepm 648_canbus= canbus 649_ct= ct 650_pmc= pmc 651_snc= snc 652.endif 653.endif 654 655.if ${MACHINE_CPUARCH} == "amd64" 656_aac= aac 657_aacraid= aacraid 658_aout= aout 659_acpi= acpi 660.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 661_aesni= aesni 662.endif 663_agp= agp 664_an= an 665_amdsbwd= amdsbwd 666_amdtemp= amdtemp 667_arcmsr= arcmsr 668_asmc= asmc 669_bktr= bktr 670_bxe= bxe 671_cardbus= cardbus 672_cbb= cbb 673_cmx= cmx 674_ciss= ciss 675_coretemp= coretemp 676_cpuctl= cpuctl 677_cpufreq= cpufreq 678.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 679_cyclic= cyclic 680.endif 681_dpms= dpms 682_drm= drm 683_drm2= drm2 684.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 685_dtrace= dtrace 686.endif 687_ed= ed 688_et= et 689_em= em 690_exca= exca 691_ext2fs= ext2fs 692.if ${MK_SOURCELESS_HOST} != "no" 693_hpt27xx= hpt27xx 694.endif 695_hptiop= hptiop 696.if ${MK_SOURCELESS_HOST} != "no" 697_hptmv= hptmv 698_hptnr= hptnr 699_hptrr= hptrr 700.endif 701_hyperv= hyperv 702_i2c= i2c 703.if ${MK_OFED} != "no" || defined(ALL_MODULES) 704_ibcore= ibcore 705.endif 706_ichwd= ichwd 707_ida= ida 708_if_ndis= if_ndis 709_igb= igb 710_iir= iir 711_io= io 712_ipmi= ipmi 713.if ${MK_OFED} != "no" || defined(ALL_MODULES) 714_ipoib= ipoib 715.endif 716_ips= ips 717_ipw= ipw 718.if ${MK_SOURCELESS_UCODE} != "no" 719_ipwfw= ipwfw 720.endif 721_isci= isci 722_iwi= iwi 723.if ${MK_SOURCELESS_UCODE} != "no" 724_iwifw= iwifw 725.endif 726_iwn= iwn 727.if ${MK_SOURCELESS_UCODE} != "no" 728_iwnfw= iwnfw 729.endif 730_ixgb= ixgb 731_ixgbe= ixgbe 732_linprocfs= linprocfs 733_linsysfs= linsysfs 734_linux= linux 735_mly= mly 736.if ${MK_OFED} != "no" || defined(ALL_MODULES) 737_mlx4= mlx4 738_mlx4ib= mlx4ib 739_mlxen= mlxen 740_mthca= mthca 741.endif 742_ndis= ndis 743_nfe= nfe 744_ntb= ntb 745_nvd= nvd 746_nvme= nvme 747_nvram= nvram 748_nxge= nxge 749.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 750_opensolaris= opensolaris 751.endif 752.if ${MK_CRYPT} != "no" || defined(ALL_MODULES) 753_padlock= padlock 754.endif 755_pccard= pccard 756_qlxge= qlxge 757_qlxgb= qlxgb 758_qlxgbe= qlxgbe 759.if ${MK_OFED} != "no" || defined(ALL_MODULES) 760_rdma= rdma 761.endif 762_s3= s3 763_safe= safe 764_scsi_low= scsi_low 765_sfxge= sfxge 766_si= si 767_smbfs= smbfs 768_sound= sound 769_speaker= speaker 770_splash= splash 771_sppp= sppp 772_tpm= tpm 773_twa= twa 774_vesa= vesa 775_viawd= viawd 776_virtio= virtio 777_vmm= vmm 778_vxge= vxge 779_x86bios= x86bios 780_wbwd= wbwd 781_wi= wi 782_wpi= wpi 783.if ${MK_SOURCELESS_UCODE} != "no" 784_wpifw= wpifw 785.endif 786.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 787_zfs= zfs 788.endif 789.endif 790 791.if ${MACHINE_CPUARCH} == "arm" 792_cfi= cfi 793_cpsw= cpsw 794_sound= sound 795.endif 796 797.if ${MACHINE_CPUARCH} == "powerpc" 798_agp= agp 799_an= an 800_bm= bm 801_cardbus= cardbus 802_cbb= cbb 803_cfi= cfi 804_cpufreq= cpufreq 805.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 806_cyclic= cyclic 807.endif 808_drm= drm 809.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 810_dtrace= dtrace 811.endif 812_exca= exca 813_nvram= powermac_nvram 814_pccard= pccard 815_smbfs= smbfs 816_sound= sound 817.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 818_opensolaris= opensolaris 819.endif 820_wi= wi 821.endif 822 823.if ${MACHINE_ARCH} == "powerpc64" 824.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 825_zfs= zfs 826.endif 827.endif 828 829.if ${MACHINE_CPUARCH} == "sparc64" 830_auxio= auxio 831_em= em 832_epic= epic 833_i2c= i2c 834_igb= igb 835.if ${MK_CDDL} != "no" || defined(ALL_MODULES) 836_opensolaris= opensolaris 837.endif 838_smbfs= smbfs 839_sound= sound 840.if ${MK_ZFS} != "no" || defined(ALL_MODULES) 841_zfs= zfs 842.endif 843.endif 844.endif 845 846.for reject in ${WITHOUT_MODULES} 847SUBDIR:= ${SUBDIR:N${reject}} 848.endfor 849 850# Calling kldxref(8) for each module is expensive. 851.if !defined(NO_XREF) 852.MAKEFLAGS+= -DNO_XREF 853afterinstall: 854 @if type kldxref >/dev/null 2>&1; then \ 855 ${ECHO} kldxref ${DESTDIR}${KMODDIR}; \ 856 kldxref ${DESTDIR}${KMODDIR}; \ 857 fi 858.endif 859 860.include <bsd.subdir.mk> 861