Centos-kernel-stream-9/net/wireless/Makefile

57 lines
1.9 KiB
Makefile
Raw Normal View History

License cleanup: add SPDX GPL-2.0 license identifier to files with no license Many source files in the tree are missing licensing information, which makes it harder for compliance tools to determine the correct license. By default all files without license information are under the default license of the kernel, which is GPL version 2. Update the files which contain no license information with the 'GPL-2.0' SPDX license identifier. The SPDX identifier is a legally binding shorthand, which can be used instead of the full boiler plate text. This patch is based on work done by Thomas Gleixner and Kate Stewart and Philippe Ombredanne. How this work was done: Patches were generated and checked against linux-4.14-rc6 for a subset of the use cases: - file had no licensing information it it. - file was a */uapi/* one with no licensing information in it, - file was a */uapi/* one with existing licensing information, Further patches will be generated in subsequent months to fix up cases where non-standard license headers were used, and references to license had to be inferred by heuristics based on keywords. The analysis to determine which SPDX License Identifier to be applied to a file was done in a spreadsheet of side by side results from of the output of two independent scanners (ScanCode & Windriver) producing SPDX tag:value files created by Philippe Ombredanne. Philippe prepared the base worksheet, and did an initial spot review of a few 1000 files. The 4.13 kernel was the starting point of the analysis with 60,537 files assessed. Kate Stewart did a file by file comparison of the scanner results in the spreadsheet to determine which SPDX license identifier(s) to be applied to the file. She confirmed any determination that was not immediately clear with lawyers working with the Linux Foundation. Criteria used to select files for SPDX license identifier tagging was: - Files considered eligible had to be source code files. - Make and config files were included as candidates if they contained >5 lines of source - File already had some variant of a license header in it (even if <5 lines). All documentation files were explicitly excluded. The following heuristics were used to determine which SPDX license identifiers to apply. - when both scanners couldn't find any license traces, file was considered to have no license information in it, and the top level COPYING file license applied. For non */uapi/* files that summary was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 11139 and resulted in the first patch in this series. If that file was a */uapi/* path one, it was "GPL-2.0 WITH Linux-syscall-note" otherwise it was "GPL-2.0". Results of that was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 WITH Linux-syscall-note 930 and resulted in the second patch in this series. - if a file had some form of licensing information in it, and was one of the */uapi/* ones, it was denoted with the Linux-syscall-note if any GPL family license was found in the file or had no licensing in it (per prior point). Results summary: SPDX license identifier # files ---------------------------------------------------|------ GPL-2.0 WITH Linux-syscall-note 270 GPL-2.0+ WITH Linux-syscall-note 169 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) 21 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) 17 LGPL-2.1+ WITH Linux-syscall-note 15 GPL-1.0+ WITH Linux-syscall-note 14 ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause) 5 LGPL-2.0+ WITH Linux-syscall-note 4 LGPL-2.1 WITH Linux-syscall-note 3 ((GPL-2.0 WITH Linux-syscall-note) OR MIT) 3 ((GPL-2.0 WITH Linux-syscall-note) AND MIT) 1 and that resulted in the third patch in this series. - when the two scanners agreed on the detected license(s), that became the concluded license(s). - when there was disagreement between the two scanners (one detected a license but the other didn't, or they both detected different licenses) a manual inspection of the file occurred. - In most cases a manual inspection of the information in the file resulted in a clear resolution of the license that should apply (and which scanner probably needed to revisit its heuristics). - When it was not immediately clear, the license identifier was confirmed with lawyers working with the Linux Foundation. - If there was any question as to the appropriate license identifier, the file was flagged for further research and to be revisited later in time. In total, over 70 hours of logged manual review was done on the spreadsheet to determine the SPDX license identifiers to apply to the source files by Kate, Philippe, Thomas and, in some cases, confirmation by lawyers working with the Linux Foundation. Kate also obtained a third independent scan of the 4.13 code base from FOSSology, and compared selected files where the other two scanners disagreed against that SPDX file, to see if there was new insights. The Windriver scanner is based on an older version of FOSSology in part, so they are related. Thomas did random spot checks in about 500 files from the spreadsheets for the uapi headers and agreed with SPDX license identifier in the files he inspected. For the non-uapi files Thomas did random spot checks in about 15000 files. In initial set of patches against 4.14-rc6, 3 files were found to have copy/paste license identifier errors, and have been fixed to reflect the correct identifier. Additionally Philippe spent 10 hours this week doing a detailed manual inspection and review of the 12,461 patched files from the initial patch version early this week with: - a full scancode scan run, collecting the matched texts, detected license ids and scores - reviewing anything where there was a license detected (about 500+ files) to ensure that the applied SPDX license was correct - reviewing anything where there was no detection but the patch license was not GPL-2.0 WITH Linux-syscall-note to ensure that the applied SPDX license was correct This produced a worksheet with 20 files needing minor correction. This worksheet was then exported into 3 different .csv files for the different types of files to be modified. These .csv files were then reviewed by Greg. Thomas wrote a script to parse the csv files and add the proper SPDX tag to the file, in the format that the file expected. This script was further refined by Greg based on the output to detect more types of files automatically and to distinguish between header and source .c files (which need different comment types.) Finally Greg ran the script using the .csv files to generate the patches. Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-11-01 14:07:57 +00:00
# SPDX-License-Identifier: GPL-2.0
obj-$(CONFIG_CFG80211) += cfg80211.o
obj-y += tests/
obj-$(CONFIG_WEXT_CORE) += wext-core.o
obj-$(CONFIG_WEXT_PROC) += wext-proc.o
obj-$(CONFIG_WEXT_PRIV) += wext-priv.o
cfg80211-y += core.o sysfs.o radiotap.o util.o reg.o scan.o nl80211.o
cfg80211-y += mlme.o ibss.o sme.o chan.o ethtool.o mesh.o ap.o trace.o ocb.o
cfg80211: add peer measurement with FTM initiator API Add a new "peer measurement" API, that can be used to measure certain things related to a peer. Right now, only implement FTM (flight time measurement) over it, but the idea is that it'll be extensible to also support measuring the necessary things to calculate e.g. angle-of-arrival for WiGig. The API is structured to have a generic list of peers and channels to measure with/on, and then for each of those a set of measurements (again, only FTM right now) to perform. Results are sent to the requesting socket, including a final complete message. Closing the controlling netlink socket will abort a running measurement. v3: - add a bit to report "final" for partial results - remove list keeping etc. and just unicast out the results to the requester (big code reduction ...) - also send complete message unicast, and as a result remove the multicast group - separate out struct cfg80211_pmsr_ftm_request_peer from struct cfg80211_pmsr_request_peer - document timeout == 0 if no timeout - disallow setting timeout nl80211 attribute to 0, must not include attribute for no timeout - make MAC address randomization optional - change num bursts exponent default to 0 (1 burst, rather rather than the old default of 15==don't care) v4: - clarify NL80211_ATTR_TIMEOUT documentation v5: - remove unnecessary nl80211 multicast/family changes - remove partial results bit/flag, final is sufficient - add max_bursts_exponent, max_ftms_per_burst to capability - rename "frames per burst" -> "FTMs per burst" v6: - rename cfg80211_pmsr_free_wdev() to cfg80211_pmsr_wdev_down() and call it in leave, so the device can't go down with any pending measurements v7: - wording fixes (Lior) - fix ftm.max_bursts_exponent to allow having the limit of 0 (Lior) v8: - copyright statements - minor coding style fixes - fix error path leak Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2018-09-10 11:29:12 +00:00
cfg80211-y += pmsr.o
cfg80211-$(CONFIG_OF) += of.o
cfg80211-$(CONFIG_CFG80211_DEBUGFS) += debugfs.o
cfg80211-$(CONFIG_CFG80211_WEXT) += wext-compat.o wext-sme.o
CFLAGS_trace.o := -I$(src)
cfg80211-$(CONFIG_CFG80211_USE_KERNEL_REGDB_KEYS) += shipped-certs.o
ifneq ($(CONFIG_CFG80211_EXTRA_REGDB_KEYDIR),)
cfg80211-y += extra-certs.o
endif
kbuild: use $(src) instead of $(srctree)/$(src) for source directory JIRA: https://issues.redhat.com/browse/RHEL-107194 commit b1992c3772e69a6fd0e3fc81cd4d2820c8b6eca0 Author: Masahiro Yamada <masahiroy@kernel.org> Date: Sat Apr 27 23:55:02 2024 +0900 kbuild: use $(src) instead of $(srctree)/$(src) for source directory Kbuild conventionally uses $(obj)/ for generated files, and $(src)/ for checked-in source files. It is merely a convention without any functional difference. In fact, $(obj) and $(src) are exactly the same, as defined in scripts/Makefile.build: src := $(obj) When the kernel is built in a separate output directory, $(src) does not accurately reflect the source directory location. While Kbuild resolves this discrepancy by specifying VPATH=$(srctree) to search for source files, it does not cover all cases. For example, when adding a header search path for local headers, -I$(srctree)/$(src) is typically passed to the compiler. This introduces inconsistency between upstream and downstream Makefiles because $(src) is used instead of $(srctree)/$(src) for the latter. To address this inconsistency, this commit changes the semantics of $(src) so that it always points to the directory in the source tree. Going forward, the variables used in Makefiles will have the following meanings: $(obj) - directory in the object tree $(src) - directory in the source tree (changed by this commit) $(objtree) - the top of the kernel object tree $(srctree) - the top of the kernel source tree Consequently, $(srctree)/$(src) in upstream Makefiles need to be replaced with $(src). Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Reviewed-by: Nicolas Schier <nicolas@fjasle.eu> Conflicts: There is a extensive list of fixes/conflicts due the amount of files originally changed by this commit, plus the difference of rhel-9 code against upstream. All conflicts/differences are listed below: - Context difference at Documentation/Makefile since RHEL 9 does not have the change "docs: allow to pass extra DOCS_CSS themes via make" and later changes. - Conflict at Documentation/devicetree/bindings/Makefile, patch find_cmd instead of find_all_cmd since RHEL-9 doesn't have "dt-bindings: Consider DT_SCHEMA_FILES when finding all json-schema", "dt-bindings: kbuild: Split targets out to separate rules" and later changes. - Conflict at Documentation/kbuild/makefiles.rst due different identation since RHEL-9 doesn't have the change "docs/kbuild/makefiles: clean up indentation and whitespace" - Patched additional $(srctree)/$(src) references at: * arch/arm/mach-davinci/Makefile * arch/arm/mach-omap2/Makefile * arch/arm/mach-spear/Makefile * arch/arm/plat-pxa/Makefile * arch/arm/plat-versatile/Makefile * arch/ia64/kernel/Makefile * arch/nds32/boot/Makefile * arch/nds32/kernel/vdso/Makefile * drivers/net/ethernet/hisilicon/hns3/hns3pf/Makefile * drivers/net/ethernet/hisilicon/hns3/hns3vf/Makefile * drivers/staging/rtl8188eu/Makefile * drivers/staging/unisys/visorhba/Makefile * drivers/staging/unisys/visornic/Makefile * scripts/gcc-plugins/Makefile Since RHEL-9 does not have later upstream changes that dropped/made those references uneeded. - Conflict at arch/arm/mach-s3c/Makefile since RHEL-9 doesn't have "ARM: s3c: remove s3c24xx specific hacks" and related changes. Also, extra locations needed patching because of not having the changes "ARM: s3c: remove all s3c24xx support" and "ARM: s3c: fix include path". Due lacking the last change also arch/arm/mach-s3c/Makefile.s3c64xx needs additional two places patched as well. - Conflict at arch/arm/plat-orion/Makefile since RHEL-9 doesn't have the commit "ARM: orion: fix include path" and its previous related changes. - Dropped changes for arch/loongarch since it doesn't exist on rhel-9 - Dropped changes to arch/parisc/kernel/{vdso32,vdso64}/Makefile since RHEL 9 does not have the change "parisc: Add vDSO support" and later updates to it. - Dropped change to arch/riscv/kernel/compat_vdso/Makefile since RHEL 9 does not have the change "riscv: compat: vdso: Add COMPAT_VDSO base code implementation" - Dropped change to arch/riscv/kvm/Makefile since there is no KVM support/commits in RHEL 9 for riscv. - Apply change for arch/riscv/kernel/vdso/Makefile in a different place since RHEL-9 does not have the change "riscv: explicitly use symbol offsets for VDSO" which changed the location of the $(srctree)/$(src) reference - Dropped change to certs/Makefile related to check-blacklist-hashes.awk since that script was only added with commit "certs: Check that builtin blacklist hashes are valid" which is not backported/available in RHEL 9 code right now. - Dropped change to drivers/md/dm-vdo/Makefile since dm-vdo was never backported to RHEL-9 main. - Dropped change to drivers/net/ethernet/fungible/funeth/Makefile since fungible ethernet driver/devices code is not available/backported to RHEL-9. - Fixed conflict at drivers/net/ethernet/hisilicon/hns3/Makefile since RHEL-9 does not have the change "net: hns3: refactor hns3 makefile to support hns3_common module" - Fixed conflict at drivers/net/wireless/intel/iwlwifi/mvm/Makefile due already backported commit "wifi: iwlwifi: mvm: implement link grading" - Dropped change to init/Makefile since we are not backporting "kbuild: build init/built-in.a just once" that introduced the section patched. - Dropped change to rust/Makefile since there is no rust support backported to RHEL-9. - Fixed conflict at scripts/dtc/Makefile since RHEL-9 does not have the change "dt-bindings: kbuild: Use DTB files for validation" - Dropped change to security/tomoyo/Makefile since it's not needed, it's just reverting the change "tomoyo: fix broken dependency on *.conf.default" which was never applied to RHEL-9. However, we also bring a different change/patch location since RHEL-9 does not have the change "tomoyo: Omit use of bin2c". - Dropped change to usr/include/Makefile since "kbuild: move headers_check.pl to usr/include/" is not being backported to RHEL-9. - Misc/minor context differences at other places. Signed-off-by: Herton R. Krzesinski <herton@redhat.com>
2025-08-14 22:50:14 +00:00
$(obj)/shipped-certs.c: $(sort $(wildcard $(src)/certs/*.hex))
@$(kecho) " GEN $@"
$(Q)(echo '#include "reg.h"'; \
echo 'const u8 shipped_regdb_certs[] = {'; \
echo | cat - $^ ; \
echo '};'; \
echo 'unsigned int shipped_regdb_certs_len = sizeof(shipped_regdb_certs);'; \
) > $@
$(obj)/extra-certs.c: $(CONFIG_CFG80211_EXTRA_REGDB_KEYDIR:"%"=%) \
$(sort $(wildcard $(CONFIG_CFG80211_EXTRA_REGDB_KEYDIR:"%"=%)/*.x509))
@$(kecho) " GEN $@"
$(Q)(set -e; \
allf=""; \
for f in $^ ; do \
test -f $$f || continue;\
# similar to hexdump -v -e '1/1 "0x%.2x," "\n"' \
thisf=$$(od -An -v -tx1 < $$f | \
sed -e 's/ /\n/g' | \
sed -e 's/^[0-9a-f]\+$$/\0/;t;d' | \
sed -e 's/^/0x/;s/$$/,/'); \
# file should not be empty - maybe command substitution failed? \
test ! -z "$$thisf";\
allf=$$allf$$thisf;\
done; \
( \
echo '#include "reg.h"'; \
echo 'const u8 extra_regdb_certs[] = {'; \
echo "$$allf"; \
echo '};'; \
echo 'unsigned int extra_regdb_certs_len = sizeof(extra_regdb_certs);'; \
) > $@)
clean-files += shipped-certs.c extra-certs.c