aboutsummaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorGravatar Titouan Christophe <titouan.christophe@railnova.eu>2019-01-15 15:15:48 +0100
committerGravatar Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>2019-02-03 20:27:41 +0100
commiteb37deb670c6f9024751fe43eaf1381f2b832a6d (patch)
tree774258f4f8efe1c3097e852a69ae95b81a079746 /linux
parent4c8760bdc501f44dcf77a8ee40349a4387e517ac (diff)
downloadbuildroot-eb37deb670c6f9024751fe43eaf1381f2b832a6d.tar.gz
buildroot-eb37deb670c6f9024751fe43eaf1381f2b832a6d.tar.bz2
linux: add option to enable support for Device Tree overlays
Add an option to compile device trees in Linux with symbol generation such that device tree overlays can be loaded on the target system Signed-off-by: Titouan Christophe <titouan.christophe@railnova.eu> [Arnout: remove "default n" and move setting of LINUX_MAKE_ENV to the place where the rest is set.] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Diffstat (limited to 'linux')
-rw-r--r--linux/Config.in8
-rw-r--r--linux/linux.mk4
2 files changed, 12 insertions, 0 deletions
diff --git a/linux/Config.in b/linux/Config.in
index 4f6ae2e9ee..8b04471008 100644
--- a/linux/Config.in
+++ b/linux/Config.in
@@ -394,6 +394,14 @@ config BR2_LINUX_KERNEL_CUSTOM_DTS_PATH
You can provide a list of dts paths to copy and
build, separated by spaces.
+config BR2_LINUX_KERNEL_DTB_OVERLAY_SUPPORT
+ bool "Build Device Tree with overlay support"
+ help
+ If enabled, pass the "-@" option to dtc, such that
+ symbols are generated in the compiled Device Tree.
+ Choose this option to support Device Tree overlays
+ on the target system.
+
endif
config BR2_LINUX_KERNEL_INSTALL_TARGET
diff --git a/linux/linux.mk b/linux/linux.mk
index 02def89113..62068106e0 100644
--- a/linux/linux.mk
+++ b/linux/linux.mk
@@ -143,6 +143,10 @@ ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_8),y)
LINUX_MAKE_ENV += KCFLAGS=-Wno-attribute-alias
endif
+ifeq ($(BR2_LINUX_KERNEL_DTB_OVERLAY_SUPPORT),y)
+LINUX_MAKE_ENV += DTC_FLAGS=-@
+endif
+
# Get the real Linux version, which tells us where kernel modules are
# going to be installed in the target filesystem.
LINUX_VERSION_PROBED = `$(MAKE) $(LINUX_MAKE_FLAGS) -C $(LINUX_DIR) --no-print-directory -s kernelrelease 2>/dev/null`