From 32346491ddf24599decca06190ebca03ff9de7f8 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Sun, 10 Jul 2022 14:40:51 -0700 Subject: Linux 5.19-rc6 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 990d2ee79186..faa4880f25f7 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ VERSION = 5 PATCHLEVEL = 19 SUBLEVEL = 0 -EXTRAVERSION = -rc5 +EXTRAVERSION = -rc6 NAME = Superb Owl # *DOCUMENTATION* -- cgit v1.2.3 From 67bd292cd281be2216cd269c161be31cd3ccf196 Mon Sep 17 00:00:00 2001 From: Guillaume Tucker Date: Fri, 8 Jul 2022 17:23:30 +0100 Subject: Makefile: add headers_install to kselftest targets Add headers_install as a dependency to kselftest targets so that they can be run directly from the top of the tree. The kselftest Makefile used to try to call headers_install "backwards" but failed due to the relative path not being consistent. Now we can either run this directly: $ make O=build kselftest-all or this: $ make O=build headers_install $ make O=build -C tools/testing/selftest all The same commands work as well when building directly in the source tree (no O=) or any arbitrary path (relative or absolute). Signed-off-by: Guillaume Tucker Tested-by: Anders Roxell Signed-off-by: Shuah Khan --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 8973b285ce6c..fb2f3bb53a6b 100644 --- a/Makefile +++ b/Makefile @@ -1347,10 +1347,10 @@ tools/%: FORCE # Kernel selftest PHONY += kselftest -kselftest: +kselftest: headers_install $(Q)$(MAKE) -C $(srctree)/tools/testing/selftests run_tests -kselftest-%: FORCE +kselftest-%: headers_install FORCE $(Q)$(MAKE) -C $(srctree)/tools/testing/selftests $* PHONY += kselftest-merge -- cgit v1.2.3 From ff6992735ade75aae3e35d16b17da1008d753d28 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Sun, 17 Jul 2022 13:30:22 -0700 Subject: Linux 5.19-rc7 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index faa4880f25f7..00fd80c5dd6e 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ VERSION = 5 PATCHLEVEL = 19 SUBLEVEL = 0 -EXTRAVERSION = -rc6 +EXTRAVERSION = -rc7 NAME = Superb Owl # *DOCUMENTATION* -- cgit v1.2.3 From e0dccc3b76fb35bb257b4118367a883073d7390e Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Sun, 24 Jul 2022 13:26:27 -0700 Subject: Linux 5.19-rc8 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 00fd80c5dd6e..b79c1c18149d 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ VERSION = 5 PATCHLEVEL = 19 SUBLEVEL = 0 -EXTRAVERSION = -rc7 +EXTRAVERSION = -rc8 NAME = Superb Owl # *DOCUMENTATION* -- cgit v1.2.3 From ed29b0b4fd835b058ddd151c49d021e28d631ee6 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Mon, 23 May 2022 17:05:03 -0600 Subject: io_uring: move to separate directory In preparation for splitting io_uring up a bit, move it into its own top level directory. It didn't really belong in fs/ anyway, as it's not a file system only API. This adds io_uring/ and moves the core files in there, and updates the MAINTAINERS file for the new location. Signed-off-by: Jens Axboe --- Makefile | 1 + 1 file changed, 1 insertion(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b79c1c18149d..e231f70dc78a 100644 --- a/Makefile +++ b/Makefile @@ -1097,6 +1097,7 @@ export MODULES_NSDEPS := $(extmod_prefix)modules.nsdeps ifeq ($(KBUILD_EXTMOD),) core-y += kernel/ certs/ mm/ fs/ ipc/ security/ crypto/ core-$(CONFIG_BLOCK) += block/ +core-$(CONFIG_IO_URING) += io_uring/ vmlinux-dirs := $(patsubst %/,%,$(filter %/, \ $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ -- cgit v1.2.3 From 4062eba9f3d072e72645860fbc5d160428a75c50 Mon Sep 17 00:00:00 2001 From: Guillaume Tucker Date: Wed, 13 Jul 2022 08:33:43 +0200 Subject: Makefile: replace headers_install with headers for kselftest Replace headers_install with headers as kselftest uses the header files from within the kernel tree rather than from a system-wide installation. We can still run this directly: $ make O=build kselftest-all and when building from the selftests directory: $ make O=build headers $ make O=build -C tools/testing/selftests all Signed-off-by: Guillaume Tucker Reported-by: Masahiro Yamada Acked-by: Shuah Khan Signed-off-by: Shuah Khan --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index fb2f3bb53a6b..5c934d16664c 100644 --- a/Makefile +++ b/Makefile @@ -1347,10 +1347,10 @@ tools/%: FORCE # Kernel selftest PHONY += kselftest -kselftest: headers_install +kselftest: headers $(Q)$(MAKE) -C $(srctree)/tools/testing/selftests run_tests -kselftest-%: headers_install FORCE +kselftest-%: headers FORCE $(Q)$(MAKE) -C $(srctree)/tools/testing/selftests $* PHONY += kselftest-merge -- cgit v1.2.3 From a6036a41bffba3d5007e377483b425d470ad8042 Mon Sep 17 00:00:00 2001 From: Nick Desaulniers Date: Tue, 28 Jun 2022 14:04:07 -0700 Subject: kbuild: drop support for CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 The difference in most compilers between `-O3` and `-O2` is mostly down to whether loops with statically determinable trip counts are fully unrolled vs unrolled to a multiple of SIMD width. This patch is effectively a revert of commit 15f5db60a137 ("kbuild,arc: add CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 for ARC") without re-adding ARCH_CFLAGS Ever since commit cfdbc2e16e65 ("ARC: Build system: Makefiles, Kconfig, Linker script") ARC has been built with -O3, though the reason for doing so was not specified in inline comments or the commit message. This commit does not re-add -O3 to arch/arc/Makefile. Folks looking to experiment with `-O3` (or any compiler flag for that matter) may pass them along to the command line invocation of make: $ make KCFLAGS=-O3 Code that looks to re-add an explicit Kconfig option for `-O3` should provide: 1. A rigorous and reproducible performance profile of a reasonable userspace workload that demonstrates a hot loop in the kernel that would benefit from `-O3` over `-O2`. 2. Disassembly of said loop body before and after. 3. Provides stats on terms of increase in file size. Link: https://lore.kernel.org/linux-kbuild/CA+55aFz2sNBbZyg-_i8_Ldr2e8o9dfvdSfHHuRzVtP2VMAUWPg@mail.gmail.com/ Signed-off-by: Nick Desaulniers Signed-off-by: Masahiro Yamada --- Makefile | 2 -- 1 file changed, 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index faa4880f25f7..f8e325709bf3 100644 --- a/Makefile +++ b/Makefile @@ -755,8 +755,6 @@ KBUILD_CFLAGS += $(call cc-disable-warning, address-of-packed-member) ifdef CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE KBUILD_CFLAGS += -O2 -else ifdef CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE_O3 -KBUILD_CFLAGS += -O3 else ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE KBUILD_CFLAGS += -Os endif -- cgit v1.2.3 From 9a68fd7fd8b05050b27ae67a829a2035b2b7a993 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Thu, 14 Jul 2022 14:02:42 +0900 Subject: kbuild: error out if $(KBUILD_EXTMOD) contains % or : If the directory path given to KBUILD_EXTMOD (or M=) contains % or :, the module fails to build. % is used in pattern rules, and : as the separator of dependencies. Bail out with a clearer error message. Signed-off-by: Masahiro Yamada Reviewed-by: Nicolas Schier --- Makefile | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index f8e325709bf3..dee707c98bbe 100644 --- a/Makefile +++ b/Makefile @@ -129,6 +129,9 @@ endif $(if $(word 2, $(KBUILD_EXTMOD)), \ $(error building multiple external modules is not supported)) +$(foreach x, % :, $(if $(findstring $x, $(KBUILD_EXTMOD)), \ + $(error module directory path cannot contain '$x'))) + # Remove trailing slashes ifneq ($(filter %/, $(KBUILD_EXTMOD)),) KBUILD_EXTMOD := $(shell dirname $(KBUILD_EXTMOD).) -- cgit v1.2.3 From ee47620367d5b5ee6a1934888bf1ae46576be757 Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Sun, 24 Jul 2022 18:59:19 +0900 Subject: kbuild: add dtbs_prepare target Factor out the common prerequisites for DT compilation into the new target, dtbs_prepare. Add comments to explain why include/config/kernel.release is the prerequisite. Our policy is that installation targets must not rebuild anything in the tree. If 'make modules_install' is executed as root, include/config/kernel.release may be owned by root. Signed-off-by: Masahiro Yamada Reviewed-by: Nicolas Schier Reviewed-by: Dmitry Baryshkov Tested-by: Dmitry Baryshkov --- Makefile | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index dee707c98bbe..a2a030f41e65 100644 --- a/Makefile +++ b/Makefile @@ -1370,16 +1370,21 @@ endif ifneq ($(dtstree),) -%.dtb: include/config/kernel.release scripts_dtc +%.dtb: dtbs_prepare $(Q)$(MAKE) $(build)=$(dtstree) $(dtstree)/$@ -%.dtbo: include/config/kernel.release scripts_dtc +%.dtbo: dtbs_prepare $(Q)$(MAKE) $(build)=$(dtstree) $(dtstree)/$@ -PHONY += dtbs dtbs_install dtbs_check -dtbs: include/config/kernel.release scripts_dtc +PHONY += dtbs dtbs_prepare dtbs_install dtbs_check +dtbs: dtbs_prepare $(Q)$(MAKE) $(build)=$(dtstree) +# include/config/kernel.release is actually needed when installing DTBs because +# INSTALL_DTBS_PATH contains $(KERNELRELEASE). However, we do not want to make +# dtbs_install depend on it as dtbs_install may run as root. +dtbs_prepare: include/config/kernel.release scripts_dtc + ifneq ($(filter dtbs_check, $(MAKECMDGOALS)),) export CHECK_DTBS=y dtbs: dt_binding_check -- cgit v1.2.3 From 3d7cb6b04c3f3115719235cc6866b10326de34cd Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Sun, 31 Jul 2022 14:03:01 -0700 Subject: Linux 5.19 --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b79c1c18149d..df92892325ae 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ VERSION = 5 PATCHLEVEL = 19 SUBLEVEL = 0 -EXTRAVERSION = -rc8 +EXTRAVERSION = NAME = Superb Owl # *DOCUMENTATION* -- cgit v1.2.3 From 0d362be5b14200b77ecc2127936a5ff82fbffe41 Mon Sep 17 00:00:00 2001 From: Nick Desaulniers Date: Wed, 10 Aug 2022 15:24:40 -0700 Subject: Makefile: link with -z noexecstack --no-warn-rwx-segments Users of GNU ld (BFD) from binutils 2.39+ will observe multiple instances of a new warning when linking kernels in the form: ld: warning: vmlinux: missing .note.GNU-stack section implies executable stack ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker ld: warning: vmlinux has a LOAD segment with RWX permissions Generally, we would like to avoid the stack being executable. Because there could be a need for the stack to be executable, assembler sources have to opt-in to this security feature via explicit creation of the .note.GNU-stack feature (which compilers create by default) or command line flag --noexecstack. Or we can simply tell the linker the production of such sections is irrelevant and to link the stack as --noexecstack. LLVM's LLD linker defaults to -z noexecstack, so this flag isn't strictly necessary when linking with LLD, only BFD, but it doesn't hurt to be explicit here for all linkers IMO. --no-warn-rwx-segments is currently BFD specific and only available in the current latest release, so it's wrapped in an ld-option check. While the kernel makes extensive usage of ELF sections, it doesn't use permissions from ELF segments. Link: https://lore.kernel.org/linux-block/3af4127a-f453-4cf7-f133-a181cce06f73@kernel.dk/ Link: https://sourceware.org/git/?p=binutils-gdb.git;a=commit;h=ba951afb99912da01a6e8434126b8fac7aa75107 Link: https://github.com/llvm/llvm-project/issues/57009 Reported-and-tested-by: Jens Axboe Suggested-by: Fangrui Song Signed-off-by: Nick Desaulniers Signed-off-by: Linus Torvalds --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 60a7e3e8b478..5f5c43a52455 100644 --- a/Makefile +++ b/Makefile @@ -1034,6 +1034,11 @@ KBUILD_CFLAGS += $(KCFLAGS) KBUILD_LDFLAGS_MODULE += --build-id=sha1 LDFLAGS_vmlinux += --build-id=sha1 +KBUILD_LDFLAGS += -z noexecstack +ifeq ($(CONFIG_LD_IS_BFD),y) +KBUILD_LDFLAGS += $(call ld-option,--no-warn-rwx-segments) +endif + ifeq ($(CONFIG_STRIP_ASM_SYMS),y) LDFLAGS_vmlinux += $(call ld-option, -X,) endif -- cgit v1.2.3 From 568035b01cfb107af8d2e4bd2fb9aea22cf5b868 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Sun, 14 Aug 2022 15:50:18 -0700 Subject: Linux 6.0-rc1 --- Makefile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 5f5c43a52455..f09673b6c11d 100644 --- a/Makefile +++ b/Makefile @@ -1,9 +1,9 @@ # SPDX-License-Identifier: GPL-2.0 -VERSION = 5 -PATCHLEVEL = 19 +VERSION = 6 +PATCHLEVEL = 0 SUBLEVEL = 0 -EXTRAVERSION = -NAME = Superb Owl +EXTRAVERSION = -rc1 +NAME = Hurr durr I'ma ninja sloth # *DOCUMENTATION* # To see a list of typical targets execute "make help" -- cgit v1.2.3