From e5ce0b5ddb6a9322ed480d567e403b4c542f0f22 Mon Sep 17 00:00:00 2001 From: Florin Sarbu Date: Mon, 6 Apr 2020 17:20:51 +0200 Subject: [PATCH] linux-mainline_%.bbappend: Re-allow to build dtb overlays The upstream kernel reworked how dtbs are generated: https://github.com/torvalds/linux/commit/ 37c8a5fafa3bb7dcdd51774be353be6cb2912b86 This broke how we built the dtb overlays from yocto so let's do a partial revert of the above upstream kernel commit so we can still build the overlays in the same way. Signed-off-by: Florin Sarbu --- ...e-Partial-revert-of-https-github.com.patch | 45 +++++++++++++++++++ .../linux/linux-mainline_%.bbappend | 1 + 2 files changed, 46 insertions(+) create mode 100644 layers/meta-balena-allwinner/recipes-kernel/linux/files/0001-arch-arm-Makefile-Partial-revert-of-https-github.com.patch diff --git a/layers/meta-balena-allwinner/recipes-kernel/linux/files/0001-arch-arm-Makefile-Partial-revert-of-https-github.com.patch b/layers/meta-balena-allwinner/recipes-kernel/linux/files/0001-arch-arm-Makefile-Partial-revert-of-https-github.com.patch new file mode 100644 index 0000000..8a23471 --- /dev/null +++ b/layers/meta-balena-allwinner/recipes-kernel/linux/files/0001-arch-arm-Makefile-Partial-revert-of-https-github.com.patch @@ -0,0 +1,45 @@ +From c76cd7f6e1e5dc204fcdbfc181857783b6a9e202 Mon Sep 17 00:00:00 2001 +From: Florin Sarbu +Date: Mon, 6 Apr 2020 17:16:12 +0200 +Subject: [PATCH] arch/arm/Makefile: Partial revert of + https://github.com/torvalds/linux/commit/37c8a5fafa3bb7dcdd51774be353be6cb2912b86 + +We do this partial revert so that we can still build the dtb overlays in the same way from yocto as before this upstream commit. + +Upstream-Status: Inappropriate [configuration] +Signed-off-by: Florin Sarbu +--- + arch/arm/Makefile | 17 +++++++++++++++++ + 1 file changed, 17 insertions(+) + +diff --git a/arch/arm/Makefile b/arch/arm/Makefile +index db857d0..b8dedc7 100644 +--- a/arch/arm/Makefile ++++ b/arch/arm/Makefile +@@ -343,6 +343,23 @@ $(BOOT_TARGETS): vmlinux + $(INSTALL_TARGETS): + $(Q)$(MAKE) $(build)=$(boot) MACHINE=$(MACHINE) $@ + ++%.dtb: | scripts ++ $(Q)$(MAKE) $(build)=$(boot)/dts MACHINE=$(MACHINE) $(boot)/dts/$@ ++ ++%.dtbo: | scripts ++ $(Q)$(MAKE) $(build)=$(boot)/dts MACHINE=$(MACHINE) $(boot)/dts/$@ ++ ++%.scr: | scripts ++ $(Q)$(MAKE) $(build)=$(boot)/dts ARCH=$(ARCH) $(boot)/dts/$@ ++ ++PHONY += dtbs dtbs_install ++ ++dtbs: prepare scripts ++ $(Q)$(MAKE) $(build)=$(boot)/dts ++ ++dtbs_install: ++ $(Q)$(MAKE) $(dtbinst)=$(boot)/dts ++ + PHONY += vdso_install + vdso_install: + ifeq ($(CONFIG_VDSO),y) +-- +2.7.4 + diff --git a/layers/meta-balena-allwinner/recipes-kernel/linux/linux-mainline_%.bbappend b/layers/meta-balena-allwinner/recipes-kernel/linux/linux-mainline_%.bbappend index 0a6a397..a887b55 100644 --- a/layers/meta-balena-allwinner/recipes-kernel/linux/linux-mainline_%.bbappend +++ b/layers/meta-balena-allwinner/recipes-kernel/linux/linux-mainline_%.bbappend @@ -16,6 +16,7 @@ SRC_URI_append = " \ file://general-add-configfs-overlay.patch \ file://general-add-overlay-compilation-support.patch \ file://general-sunxi-overlays.patch \ + file://0001-arch-arm-Makefile-Partial-revert-of-https-github.com.patch \ " RESIN_CONFIGS_append = " axp_power"