From: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
To: linux-snps-arc@lists.infradead.org
Cc: linux-kernel@vger.kernel.org,
Alexey Brodkin <Alexey.Brodkin@synopsys.com>,
Vineet Gupta <Vineet.Gupta1@synopsys.com>
Subject: [PATCH] arc: dts - remove default value if CONFIG_ARC_BUILTIN_DTB_NAME is blank
Date: Sun, 1 Nov 2015 02:21:11 +0300 [thread overview]
Message-ID: <1446333671-32095-1-git-send-email-abrodkin@synopsys.com> (raw)
As of today default .dtb will be built (and subsequently will be built-in
kernel binary) even if CONFIG_ARC_BUILTIN_DTB_NAME is not set.
But it is possible we're going to use external .dtb and so we don't want to
have .dtb built-in kernel binary.
For example that could be the case with:
a) U-Boot which loads .dtb in DDR and passes its address to the kernel
b) OpenWRT which embeds .dtb in existing kernel binary
This change excludes .dtb building if CONFIG_ARC_BUILTIN_DTB_NAME is
blank.
Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Vineet Gupta <vgupta@synopsys.com>
---
arch/arc/Makefile | 2 ++
arch/arc/boot/dts/Makefile | 6 ++----
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/arc/Makefile b/arch/arc/Makefile
index 8a27a48..b0cb6de 100644
--- a/arch/arc/Makefile
+++ b/arch/arc/Makefile
@@ -94,7 +94,9 @@ head-y := arch/arc/kernel/head.o
core-y += arch/arc/
# w/o this dtb won't embed into kernel binary
+ifneq ($(CONFIG_ARC_BUILTIN_DTB_NAME),"")
core-y += arch/arc/boot/dts/
+endif
core-$(CONFIG_ARC_PLAT_SIM) += arch/arc/plat-sim/
core-$(CONFIG_ARC_PLAT_TB10X) += arch/arc/plat-tb10x/
diff --git a/arch/arc/boot/dts/Makefile b/arch/arc/boot/dts/Makefile
index b0e3f19..4dcab5b 100644
--- a/arch/arc/boot/dts/Makefile
+++ b/arch/arc/boot/dts/Makefile
@@ -1,13 +1,11 @@
# Built-in dtb
-builtindtb-y := nsim_700
ifneq ($(CONFIG_ARC_BUILTIN_DTB_NAME),"")
builtindtb-y := $(patsubst "%",%,$(CONFIG_ARC_BUILTIN_DTB_NAME))
+ obj-y += $(builtindtb-y).dtb.o
+ targets += $(builtindtb-y).dtb
endif
-obj-y += $(builtindtb-y).dtb.o
-targets += $(builtindtb-y).dtb
-
.SECONDARY: $(obj)/$(builtindtb-y).dtb.S
dtbs: $(addprefix $(obj)/, $(builtindtb-y).dtb)
--
2.4.3
next reply other threads:[~2015-10-31 23:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-31 23:21 Alexey Brodkin [this message]
2015-11-01 20:37 ` Noam Camus
2015-11-02 6:54 ` Vineet Gupta
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1446333671-32095-1-git-send-email-abrodkin@synopsys.com \
--to=alexey.brodkin@synopsys.com \
--cc=Vineet.Gupta1@synopsys.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-snps-arc@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®