linux-stable/arch
Masahiro Yamada f61e85f284 um: let 'make clean' properly clean underlying SUBARCH as well
[ Upstream commit ab09da7570 ]

Building the kernel with O= is affected by stale in-tree build artifacts.

So, if the source tree is not clean, Kbuild displays the following:

  $ make ARCH=um O=build defconfig
  make[1]: Entering directory '/.../linux/build'
  ***
  *** The source tree is not clean, please run 'make ARCH=um mrproper'
  *** in /.../linux
  ***
  make[2]: *** [/.../linux/Makefile:673: outputmakefile] Error 1
  make[1]: *** [/.../linux/Makefile:248: __sub-make] Error 2
  make[1]: Leaving directory '/.../linux/build'
  make: *** [Makefile:248: __sub-make] Error 2

Usually, running 'make mrproper' is sufficient for cleaning the source
tree for out-of-tree builds.

However, building UML generates build artifacts not only in arch/um/,
but also in the SUBARCH directory (i.e., arch/x86/). If in-tree stale
files remain under arch/x86/, Kbuild will reuse them instead of creating
new ones under the specified build directory.

This commit makes 'make ARCH=um clean' recurse into the SUBARCH directory.

Reported-by: Shuah Khan <skhan@linuxfoundation.org>
Closes: https://lore.kernel.org/lkml/20250502172459.14175-1-skhan@linuxfoundation.org/
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Reviewed-by: David Gow <davidgow@google.com>
Reviewed-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-06-04 14:37:09 +02:00
..
alpha
arc
arm ARM: tegra: Switch DSI-B clock parent to PLLD on Tegra114 2025-06-04 14:37:01 +02:00
arm64 arm64: tegra: p2597: Fix gpio for vdd-1v8-dis regulator 2025-06-04 14:37:01 +02:00
c6x
csky
h8300
hexagon
ia64
m68k
microblaze
mips MIPS: pm-cps: Use per-CPU variables as per-CPU, not per-core 2025-06-04 14:37:03 +02:00
nds32
nios2
openrisc
parisc parisc: Fix double SIGFPE crash 2025-06-04 14:36:51 +02:00
powerpc powerpc/prom_init: Fixup missing #size-cells on PowerBook6,7 2025-06-04 14:37:01 +02:00
riscv riscv: Avoid fortify warning in syscall_get_arguments() 2025-05-02 07:41:02 +02:00
s390 KVM: s390: Don't use %pK through tracepoints 2025-05-02 07:41:19 +02:00
sh
sparc
um um: let 'make clean' properly clean underlying SUBARCH as well 2025-06-04 14:37:09 +02:00
x86 perf/amd/ibs: Fix perf_ibs_op.cnt_mask for CurCnt 2025-06-04 14:37:06 +02:00
xtensa
.gitignore
Kconfig