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