RFC: Adding U-Boot version in FDT chosen node

Francesco Dolcini francesco.dolcini at toradex.com
Thu Apr 21 10:34:34 CEST 2022


Hello Mark

On Wed, Apr 20, 2022 at 11:51:44PM +0200, Mark Kettenis wrote:
> > Date: Wed, 20 Apr 2022 19:01:43 +0200
> > From: Francesco Dolcini <francesco.dolcini at toradex.com>
> > 
> > +Tom
> > 
> > On Mon, Apr 11, 2022 at 08:17:55PM +0200, Francesco Dolcini wrote:
> > > Hello all,
> > > I have a need to pass the u-boot version string to the operating
> > > system and I'm thinking at adding `u-boot,version` property storing
> > > `version_string` in it in the FDT `chosen` node.
> > > 
> > > Is this something that would be generally useful? Would be a patch like
> > > that acceptable in upstream u-boot? Is there any other obvious way to
> > > achieve something like that already implemented (using the cmdline would
> > > work without any code change, but probably not the nicest solution).
> > 
> > Any concern on this Tom? I'm asking you directly since you recently
> > acknowledged another change [0] related to the chosen node.
> > 
> > [0] https://lore.kernel.org/all/20220412201444.GN14282@bill-the-cat/
> 
> To be honest, putting this in the "chosen" node feels odd.
> Traditionally device trees have a node dedicated to the firmware.  For
> example Sun OpenFirmware systems had a "openprom" node with a
> "version" property.  And OpenPOWER systems have an
> "ibm,firmware-versions" node.

I would personally not mind the parent node of this property, however
from my partial understanding on the recent device tree architecture
decisions we do want only the description of the hardware and real
devices into it.

No software artifact nor software configuration should be part of it,
with the only exception of the chosen node [0].

Rob in cc can comment if I understood this wrong.

[0] https://www.kernel.org/doc/Documentation/devicetree/bindings/chosen.txt

Francesco


More information about the U-Boot mailing list