linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Dirk Brandewie <dirk.brandewie@gmail.com>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: linux-arch@vger.kernel.org, mmarek@suse.cz,
	microblaze-uclinux@itee.uq.edu.au,
	devicetree-discuss@lists.ozlabs.org,
	linux-kernel@vger.kernel.org, sodaville@linutronix.de,
	linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH 1/4] of: Add support for linking device tree blobs into vmlinux
Date: Mon, 06 Dec 2010 19:19:11 -0800	[thread overview]
Message-ID: <4CFDA7AF.2060201@gmail.com> (raw)
In-Reply-To: <20101206190251.GB20882@merkur.ravnborg.org>

On 12/06/2010 11:02 AM, Sam Ravnborg wrote:
> On Mon, Dec 06, 2010 at 09:35:59AM -0800, dirk.brandewie@gmail.com wrote:
>> From: Dirk Brandewie<dirk.brandewie@gmail.com>
>> -
>> +# DTC
>> +#  ---------------------------------------------------------------------------
>> +
>> +# Generate an assembly file to wrap the output of the device tree compiler
>> +$(obj)/%.dtb.S: $(obj)/%.dtb
>> +	@echo '#include<asm-generic/vmlinux.lds.h>'>  $@
>> +	@echo '.section .dtb.init.rodata,"a"'>>  $@
>> +	@echo '.balign STRUCT_ALIGNMENT'>>  $@
>> +	@echo '.global __dtb_$(*F)_begin'>>  $@
>> +	@echo '__dtb_$(*F)_begin:'>>  $@
>> +	@echo '.incbin "$<" '>>  $@
>> +	@echo '__dtb_$(*F)_end:'>>  $@
>> +	@echo '.global __dtb_$(*F)_end'>>  $@
>> +	@echo '.balign STRUCT_ALIGNMENT'>>  $@
>> +
>
> If we really want this rule in Makefile.lib then at least make it less verbose,
> and more secure.

I started with the change in Makefile.lib because it made sense to me, is there 
a more appropriate place for these rules/commands?

> Something like this:
> quiet_dt_S_dtb_cmd = DTB    $@
>        dt_S_dtb_cmd =                                      \
> (                                                         \
> 	@echo '#include<asm-generic/vmlinux.lds.h>';     \
> 	@echo '.section .dtb.init.rodata,"a"';            \
> 	@echo '.balign STRUCT_ALIGNMENT';                 \
> 	echo '.global __dtb_$(*F)_begin';                 \
> 	echo '__dtb_$(*F)_begin:';                        \
> 	echo '.incbin "$<" ';                             \
> 	echo '__dtb_$(*F)_end:';                          \
> 	echo '.global __dtb_$(*F)_end';                   \
> 	echo '.balign STRUCT_ALIGNMENT';                  \
> )>  $@
>
> $(obj)/%.dtb.S: $(obj)/%.dtb
> 	$(call cmd,dt_S_dtb)
>

I will make the changes in next version.

>
>> +DTC = $(objtree)/scripts/dtc/dtc
>
> If this is the only spot where we use DTC then drop the variable.
>
>> +
>> +quiet_cmd_dtc = DTC $@
>> +      cmd_dtc = $(DTC) -O dtb -o $@ -b 0 $(DTC_FLAGS) $<
>
>
>> +ooo
>
> What is the purpose of these "ooo"? A debugging left-over?
>

Yep sorry

>
> 	Sam

  reply	other threads:[~2010-12-07  3:19 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-06 17:35 [PATCH 0/4] V2 Add ability to link device blob(s) into vmlinux dirk.brandewie
2010-12-06 17:35 ` [PATCH 1/4] of: Add support for linking device tree blobs " dirk.brandewie
2010-12-06 19:02   ` Sam Ravnborg
2010-12-07  3:19     ` Dirk Brandewie [this message]
2010-12-06 17:36 ` [PATCH 2/4] x86/of: Add building device tree blob(s) into image dirk.brandewie
2010-12-06 17:36 ` [PATCH 3/4] of/powerpc: Use generic rule to build dtb's dirk.brandewie
2010-12-06 17:36 ` [PATCH 4/4] microblaze/of: " dirk.brandewie
  -- strict thread matches above, loose matches on Subject: below --
2010-12-22 19:57 [PATCH 0/4] V3 Add ability to link device blob(s) into vmlinux dirk.brandewie
2010-12-22 19:57 ` [PATCH 1/4] of: Add support for linking device tree blobs " dirk.brandewie
2010-12-22 22:36   ` Michal Marek
2010-12-23  6:14     ` Geert Uytterhoeven
2010-12-23 21:44       ` Grant Likely
2010-12-23 21:42   ` Grant Likely
2010-12-08 15:01 [PATCH 0/4] V3 Add ability to link device blob(s) " dirk.brandewie
2010-12-08 15:01 ` [PATCH 1/4] of: Add support for linking device tree blobs " dirk.brandewie
2010-12-21 14:24   ` Michal Marek
2010-12-21 17:52     ` Dirk Brandewie
2010-11-16 22:41 [PATCH 0/5] Add the ability to link device " dirk.brandewie
2010-12-01 19:41 ` [PATCH 0/4] V2 Add ability to link device blob(s) " dirk.brandewie
2010-12-01 19:41   ` [PATCH 1/4] of: Add support for linking device tree blobs " dirk.brandewie

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=4CFDA7AF.2060201@gmail.com \
    --to=dirk.brandewie@gmail.com \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=microblaze-uclinux@itee.uq.edu.au \
    --cc=mmarek@suse.cz \
    --cc=sam@ravnborg.org \
    --cc=sodaville@linutronix.de \
    /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).