Skip to content
Browse files

kbuild: Correctly step into driver directory

Descending into subdirectories with modules via subdir-y worked up to
5.3-rc1 but was never designed to do so, see We are supposed to use
obj-m here as well.

Don't migrate the other subdirs because that causes warnings such as

cat: /data/jailhouse/hypervisor/modules.order: No such file or directory

due to missing module targets there.

Signed-off-by: Jan Kiszka <>
  • Loading branch information...
jan-kiszka committed Jul 26, 2019
1 parent e7674ea commit 4f27c75d40daa00e7bb10e2c7b8160c6da8d9732
Showing with 4 additions and 2 deletions.
  1. +4 −2 Kbuild
6 Kbuild
@@ -51,14 +51,16 @@ GEN_PCI_DEFS_PY := $(obj)/pyjailhouse/
$(GEN_PCI_DEFS_PY): $(src)/scripts/
$(call if_changed,gen_pci_defs)

subdir-y := driver hypervisor configs inmates tools
subdir-y := hypervisor configs inmates tools

subdir-ccflags-y := -Werror

obj-m := driver/

# Do not generate files by creating dependencies if we are cleaning up
ifeq ($(filter %/Makefile.clean,$(MAKEFILE_LIST)),)

$(addprefix $(obj)/,$(subdir-y)): $(GEN_CONFIG_MK)
$(obj)/driver $(addprefix $(obj)/,$(subdir-y)): $(GEN_CONFIG_MK)

$(obj)/driver $(obj)/hypervisor: $(GEN_VERSION_H)

0 comments on commit 4f27c75

Please sign in to comment.
You can’t perform that action at this time.