From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Pitre Subject: Re: Boot interface for device trees on ARM Date: Wed, 19 May 2010 16:22:47 -0400 (EDT) Message-ID: References: <201005181054.32325.jeremy.kerr@canonical.com> <20100519200819.GF1693@shareable.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-reply-to: <20100519200819.GF1693-yetKDKU6eevNLxjTenLetw@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: devicetree-discuss-bounces+gldd-devicetree-discuss=m.gmane.org-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org Errors-To: devicetree-discuss-bounces+gldd-devicetree-discuss=m.gmane.org-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org To: Jamie Lokier Cc: nicolas.pitre-Z7WLFzj8eWMS+FvcfC7Uqw@public.gmane.org, Jeremy Kerr , devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org List-Id: devicetree@vger.kernel.org On Wed, 19 May 2010, Jamie Lokier wrote: > Nicolas Pitre wrote: > > It is not up to the bootloader to "adjust" to the kernel. But rather > > for the kernel to cope with the bootloader's provided information. If > > the bootloader passes a specific machine ID with the ATAG list then the > > kernel will use that, and if the bootloader passes a DT machine ID with > > a DT blob then the kernel will use that. You just have to configure > > your kernel with both "machine types" at the same time. > > Scenario: > > You upgrade your systems to a new DT-capable kernel and DT-capable > bootloader. It works great. You ship new instances of your device with this. > > Once they're in the field, someone reports a bug that doesn't happen > with the older device instances. It's not a bug you can reproduce, > but you suspect the newer of kernel. So you remote-update some of the > newly shipped devices with an old, pre-DT kernel binary that's been > stable on the older devices, to see if the bug goes away. > > Problem: The newer shipped devices have a DT-capable bootloader, and > it can't boot old kernels, because they don't understand the DT format. > > You could remote-downgrade the bootloaders, but that's risky. You > could try building the old kernel with DT support, but that adds > another variable to your testing. > > Anticipating this well in advance, you of course built your DT-capable > bootloader with the ability to boot old and new style kernels... Exact. Quoting myself: |I think that, for the moment, it is best if the bootloader on already |existing subarchitectures where DT is introduced still preserve the |already existing ability to boot using ATAGs. This allows for the |testing and validation of the DT concept against the legacy ATAG method |more easily. | |On new subarchitectures, it might make sense to go with DT from the |start instead of creating setup code for every single machine. In that |case the bootloader for those machines would only need to care about DT |and forget about ATAGs. Nicolas