devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Bresticker <abrestic@chromium.org>
To: Ralf Baechle <ralf@linux-mips.org>,
	Rob Herring <robh+dt@kernel.org>, Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Kumar Gala <galak@codeaurora.org>
Cc: James Hogan <james.hogan@imgtec.com>,
	Paul Burton <paul.burton@imgtec.com>,
	David Daney <david.daney@cavium.com>,
	John Crispin <blogic@openwrt.org>,
	Jayachandran C <jchandra@broadcom.com>,
	Qais Yousef <qais.yousef@imgtec.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Jonas Gorski <jogo@openwrt.org>, Olof Johansson <olof@lixom.net>,
	Arnd Bergmann <arnd@arndb.de>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	linux-mips@linux-mips.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org,
	Andrew Bresticker <abrestic@chromium.org>
Subject: [PATCH v2 1/7] MIPS: Create common infrastructure for building built-in device-trees
Date: Wed, 27 Aug 2014 19:10:06 -0700	[thread overview]
Message-ID: <1409191812-23697-2-git-send-email-abrestic@chromium.org> (raw)
In-Reply-To: <1409191812-23697-1-git-send-email-abrestic@chromium.org>

In preparation for moving the device-trees to a common location,
introduce the config option BUILTIN_DTB, which can be selected by
platforms that use a device-tree built into the kernel image, and
create a Makefile to build the device-trees in arch/mips/boot/dts/.

Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
---
 arch/mips/Kconfig           | 3 +++
 arch/mips/Makefile          | 6 ++++++
 arch/mips/boot/dts/Makefile | 3 +++
 3 files changed, 12 insertions(+)
 create mode 100644 arch/mips/boot/dts/Makefile

diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index df51e78..19b8aac 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -2481,6 +2481,9 @@ config USE_OF
 	select OF_EARLY_FLATTREE
 	select IRQ_DOMAIN
 
+config BUILTIN_DTB
+	bool
+
 endmenu
 
 config LOCKDEP_SUPPORT
diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index 9336509..72cdd6a 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -324,6 +324,12 @@ endif
 
 CLEAN_FILES += vmlinux.32 vmlinux.64
 
+# device-trees
+core-$(CONFIG_BUILTIN_DTB) += arch/mips/boot/dts/
+
+%.dtb %.dtb.S %.dtb.o: | scripts
+	$(Q)$(MAKE) $(build)=arch/mips/boot/dts arch/mips/boot/dts/$@
+
 archprepare:
 ifdef CONFIG_MIPS32_N32
 	@echo '  Checking missing-syscalls for N32'
diff --git a/arch/mips/boot/dts/Makefile b/arch/mips/boot/dts/Makefile
new file mode 100644
index 0000000..0fef69d
--- /dev/null
+++ b/arch/mips/boot/dts/Makefile
@@ -0,0 +1,3 @@
+obj-y		+= $(patsubst %.dtb, %.dtb.o, $(dtb-y))
+
+clean-files	+= */*.dtb.S
-- 
2.1.0.rc2.206.gedb03e5

  reply	other threads:[~2014-08-28  2:10 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-28  2:10 [PATCH v2 0/7] MIPS: Move device-tree files to a common location Andrew Bresticker
2014-08-28  2:10 ` Andrew Bresticker [this message]
2014-08-28  2:10 ` [PATCH v2 2/7] MIPS: Add support for building device-tree binaries Andrew Bresticker
2014-08-28  2:10 ` [PATCH v2 3/7] MIPS: Octeon: Move device-trees to arch/mips/boot/dts/cavium-octeon/ Andrew Bresticker
2014-08-28  2:10 ` [PATCH v2 4/7] MIPS: Lantiq: Move device-trees to arch/mips/boot/dts/lantiq/ Andrew Bresticker
2014-08-28  2:10 ` [PATCH v2 6/7] MIPS: Netlogic: Move device-trees to arch/mips/boot/dts/netlogic/ Andrew Bresticker
     [not found] ` <1409191812-23697-1-git-send-email-abrestic-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2014-08-28  2:10   ` [PATCH v2 5/7] MIPS: sead3: Move device-trees to arch/mips/boot/dts/mti/ Andrew Bresticker
2014-08-29  3:27   ` [PATCH v2 7/7] MIPS: ralink: Move device-trees to arch/mips/boot/dts/ralink/ Andrew Bresticker
2014-08-29  3:56   ` Andrew Bresticker

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=1409191812-23697-2-git-send-email-abrestic@chromium.org \
    --to=abrestic@chromium.org \
    --cc=arnd@arndb.de \
    --cc=blogic@openwrt.org \
    --cc=david.daney@cavium.com \
    --cc=devicetree@vger.kernel.org \
    --cc=f.fainelli@gmail.com \
    --cc=galak@codeaurora.org \
    --cc=geert@linux-m68k.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=james.hogan@imgtec.com \
    --cc=jchandra@broadcom.com \
    --cc=jogo@openwrt.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@linux-mips.org \
    --cc=mark.rutland@arm.com \
    --cc=olof@lixom.net \
    --cc=paul.burton@imgtec.com \
    --cc=pawel.moll@arm.com \
    --cc=qais.yousef@imgtec.com \
    --cc=ralf@linux-mips.org \
    --cc=robh+dt@kernel.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;
as well as URLs for NNTP newsgroup(s).