From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay01.pair.com (relay01.pair.com [209.68.5.15]) by ozlabs.org (Postfix) with SMTP id 05C25DDF3B for ; Fri, 22 Feb 2008 07:09:54 +1100 (EST) Date: Thu, 21 Feb 2008 12:03:09 -0800 Subject: Re: [PATCH] [POWERPC] add target for building .dtb files From: Grant Erickson To: Grant Likely Message-ID: In-Reply-To: <20080221191955.10139.10496.stgit@trillian.secretlab.ca> Mime-version: 1.0 Content-type: text/plain; charset="US-ASCII" Cc: linuxppc-dev@ozlabs.org List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On 2/21/08 11:19 AM, Grant Likely wrote: > From: Grant Likely > > Signed-off-by: Grant Likely > > --- > > Josh, is this what your were looking for? > > Cheers, > g. > --- > > arch/powerpc/Makefile | 2 +- > arch/powerpc/boot/Makefile | 4 ++++ > 2 files changed, 5 insertions(+), 1 deletions(-) > > diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile > index ab5cfe8..dd80825 100644 > --- a/arch/powerpc/Makefile > +++ b/arch/powerpc/Makefile > @@ -164,7 +164,7 @@ boot := arch/$(ARCH)/boot > $(BOOT_TARGETS): vmlinux > $(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@) > > -bootwrapper_install: > +bootwrapper_install %.dtb: > $(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@) > > define archhelp > diff --git a/arch/powerpc/boot/Makefile b/arch/powerpc/boot/Makefile > index d57a67d..fb29f10 100644 > --- a/arch/powerpc/boot/Makefile > +++ b/arch/powerpc/boot/Makefile > @@ -311,6 +311,10 @@ $(obj)/treeImage.initrd.%: vmlinux $(dtstree)/%.dts > $(wrapperbits) > $(obj)/treeImage.%: vmlinux $(dtstree)/%.dts $(wrapperbits) > $(call if_changed,wrap,treeboot-$*,$(dtstree)/$*.dts) > > +# Rule to build device tree blobs > +$(obj)/%.dtb: $(dtstree)/%.dts $(obj)/dtc > + $(obj)/dtc -O dtb -o $(obj)/$*.dtb -b 0 $(dtstree)/$*.dts > + Grant, Would it be beneficial to provide a way to have environment- or command-line-provided DTC arguments/flags such that the oft-required '-S ' and '-R ' flags can be specified? Or, are there reasonable size and reserved defaults appropriate for all platforms that can be specified? FWIW, generating a blob for Haleakala/Kilauea on the PPC405EX[r] using the above command in the patch results in complaints about lack of space for the "CHOSEN" node in u-boot. Regards, Grant