From mboxrd@z Thu Jan 1 00:00:00 1970 From: Grant Likely Subject: Re: [PATCH v5 4/8] arm/dt: probe for platforms via the device tree Date: Mon, 2 May 2011 15:55:37 -0600 Message-ID: <20110502215537.GE10097@ponder.secretlab.ca> References: <20110429070135.12522.35745.stgit@ponder> <20110429071548.12522.56929.stgit@ponder> <20110502151542.GG2092@atomide.com> <20110502163951.GC9243@atomide.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: Content-Disposition: inline In-Reply-To: <20110502163951.GC9243@atomide.com> Sender: linux-kernel-owner@vger.kernel.org To: Tony Lindgren Cc: devicetree-discuss@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, Nicolas Pitre , Russell King , linux-kernel@vger.kernel.org List-Id: devicetree@vger.kernel.org On Mon, May 02, 2011 at 07:39:54PM +0300, Tony Lindgren wrote: > * Grant Likely [110502 18:31]: > > On Mon, May 2, 2011 at 9:15 AM, Tony Lindgren wr= ote: > > > * Grant Likely [110429 00:13]: > > >> + > > >> +/** > > >> + * setup_machine_fdt - Machine setup when an dtb was passed to = the kernel > > >> + * @dt_phys: physical address of dt blob > > >> + * > > >> + * If a dtb was passed to the kernel in r2, then use it to choo= se the > > >> + * correct machine_desc and to setup the system. > > >> + */ > > >> +struct machine_desc * __init setup_machine_fdt(unsigned int dt_= phys) > > >> +{ > > > ... > > > > > >> + > > >> + =A0 =A0 /* Retrieve various information from the /chosen node = */ > > >> + =A0 =A0 of_scan_flat_dt(early_init_dt_scan_chosen, boot_comman= d_line); > > > > > > Just to make sure we're considering properly what this change mea= ns.. > > > > > > Does this patch require using CONFIG_CMDLINE_FORCE for older boot= loaders > > > with the device tree append patch? > >=20 > > With the current patch? Yes, but there is a follow-on patch that w= as > > posted a while ago[1] that will copy ATAG data into the device tree= in > > the bootloader. I've not been pushing to include that change since= it > > adds a lot of code to the wrapper and I'm not sure how deeply we wa= nt > > to support that use case. Basically I want to have a better idea w= hat > > the supported use cases are before pushing something like that. >=20 > OK. Maybe that could be made simpler if we only copy the cmdline? >=20 > The cmdline is something that bootloaders typically allow to configur= e, > while the other ATAGs are static and should be in the .dts file. Once the libfdt code is pulled into to manipulate the command line, it becomes trivial to parse the rest of the atags too, so this probably won't make much difference (unless work is done to preparse the devicetree and provide to the zimage wrapper a direct offset to the cmdline buffer in the dtb, but that gets hairy and I really don't want to go down that path). > =20 > > Adding a default command line to the .dts file instead of using > > CONFIG_CMDLINE_FORCE also works. >=20 > But that requires carrying extra patches for something that should > be user configured.. So not so nice for distros. Right, so this is only a stop-gap solution. I'll add this to the list of topics to discuss in the device tree session at Linaro@UDS next week. g. >=20 > Tony > =20 > > [1] http://lists.ozlabs.org/pipermail/devicetree-discuss/2011-March= /004652.html