devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Using CONFIG_ARM_APPENDED_DTB with multiple device trees
@ 2015-10-20  3:27 Chris Packham
       [not found] ` <fce90e91fe3c452b80bcd2113f267003-5g7mGxlPNYb6GjIOKuZY+ItlCAj8ZROq@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Chris Packham @ 2015-10-20  3:27 UTC (permalink / raw)
  To: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org

Hi,

We currently have several boards based around the 88f6281 (kirkwood) ARM 
CPU.

The boards all share a kernel image (currently 3.16 based but we're in 
the process of moving to 4.3). We use the machine id (and some other 
eeprom type information) to distinguish the boards.

We'd like to move to a device tree based model but we're restricted in 
that updating the bootloaders to a DT-aware u-boot is impractical. 
CONFIG_ARM_APPENDED_DTB allows us to append a device tree but we still 
need to account for the differences between the boards.

Is it possible to append several device trees and have the correct one 
selected based on mach-id? One alternative would be to have a lowest 
common denominator device tree and platform_data style initializations 
for the rest (which would kind of defeat the purpose of having a device 
tree). Or we could have a superset device tree with the nodes disabled 
and install fixups to enable them based on mach-id. Has anyone faced a 
similar situation?

Thanks,
Chris
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Using CONFIG_ARM_APPENDED_DTB with multiple device trees
       [not found] ` <fce90e91fe3c452b80bcd2113f267003-5g7mGxlPNYb6GjIOKuZY+ItlCAj8ZROq@public.gmane.org>
@ 2015-10-20  4:04   ` Andrew Lunn
       [not found]     ` <20151020040445.GA4478-g2DYL2Zd6BY@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Lunn @ 2015-10-20  4:04 UTC (permalink / raw)
  To: Chris Packham
  Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org

On Tue, Oct 20, 2015 at 03:27:15AM +0000, Chris Packham wrote:
> Hi,
> 
> We currently have several boards based around the 88f6281 (kirkwood) ARM 
> CPU.
> 
> The boards all share a kernel image (currently 3.16 based but we're in 
> the process of moving to 4.3). We use the machine id (and some other 
> eeprom type information) to distinguish the boards.
> 
> We'd like to move to a device tree based model but we're restricted in 
> that updating the bootloaders to a DT-aware u-boot is impractical. 
> CONFIG_ARM_APPENDED_DTB allows us to append a device tree but we still 
> need to account for the differences between the boards.

Hi Chris

You might want to look at what Debian does. When installing the
kernel, it appends the correct DT blob depending on what the current
running kernel is, to the new kernel image before writing it to the
boot medium.

Another option is the pxa-impedance-matcher.

     Andrew
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Using CONFIG_ARM_APPENDED_DTB with multiple device trees
       [not found]     ` <20151020040445.GA4478-g2DYL2Zd6BY@public.gmane.org>
@ 2015-10-20  8:11       ` Arnd Bergmann
  0 siblings, 0 replies; 3+ messages in thread
From: Arnd Bergmann @ 2015-10-20  8:11 UTC (permalink / raw)
  To: Andrew Lunn
  Cc: Chris Packham,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org

On Tuesday 20 October 2015 06:04:45 Andrew Lunn wrote:
> On Tue, Oct 20, 2015 at 03:27:15AM +0000, Chris Packham wrote:
> > Hi,
> > 
> > We currently have several boards based around the 88f6281 (kirkwood) ARM 
> > CPU.
> > 
> > The boards all share a kernel image (currently 3.16 based but we're in 
> > the process of moving to 4.3). We use the machine id (and some other 
> > eeprom type information) to distinguish the boards.
> > 
> > We'd like to move to a device tree based model but we're restricted in 
> > that updating the bootloaders to a DT-aware u-boot is impractical. 
> > CONFIG_ARM_APPENDED_DTB allows us to append a device tree but we still 
> > need to account for the differences between the boards.
> 
> Hi Chris
> 
> You might want to look at what Debian does. When installing the
> kernel, it appends the correct DT blob depending on what the current
> running kernel is, to the new kernel image before writing it to the
> boot medium.
> 
> Another option is the pxa-impedance-matcher.
> 

Right, pxa-impedance-matcher is indeed meant to solve this. We intentionally
do not support CONFIG_ARM_APPENDED_DTB with multiple DT files so we get
people to eventually update their boot loaders to a version that
understands DT.

For modern systems, the part of the boot loader that knows about the
machine ID also knows about the DT.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-10-20  8:11 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-20  3:27 Using CONFIG_ARM_APPENDED_DTB with multiple device trees Chris Packham
     [not found] ` <fce90e91fe3c452b80bcd2113f267003-5g7mGxlPNYb6GjIOKuZY+ItlCAj8ZROq@public.gmane.org>
2015-10-20  4:04   ` Andrew Lunn
     [not found]     ` <20151020040445.GA4478-g2DYL2Zd6BY@public.gmane.org>
2015-10-20  8:11       ` Arnd Bergmann

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).