[U-Boot] dtb vs. kernel command line arguments

Tom Rini trini at ti.com
Tue Mar 5 20:33:36 CET 2013


On Tue, Mar 05, 2013 at 11:16:17AM -0800, Simon Glass wrote:
> Hi Kim,
> 
> On Mon, Mar 4, 2013 at 4:03 PM, Kim Phillips <kim.phillips at freescale.com> wrote:
> > On Mon, 4 Mar 2013 10:30:45 -0800
> > Curt Brune <curt at cumulusnetworks.com> wrote:
> >
> >> Hello -
> >>
> >> I want to pass a number of arguments from u-boot to the booted kernel.
> >> The arguments are needed by user space applications, not the kernel.
> >>
> >> I can think of two ways:
> >>
> >> 1. append args by setting "bootargs".
> >> 2. add nodes to the dtb before booting.
> >>
> >> Is there a preferred way to pass information like this?
> >>
> >> Like I said the arguments are not needed by the kernel device drivers,
> >> but by user space applications.
> >>
> >> I like the structure of nodes in the dtb.
> >
> > please don't dual-purpose device trees as a mechanism of getting
> > arguments through the kernel into userspace - device trees strictly
> > describe the hardware.
> 
> That's certainly the primary purpose, but it is also true that the
> device tree is a convenient way to pass things to the kernel. It is in
> fact becoming the only way on ARM systems. We certainly use it to pass
> general information to the kernel, for example the command line.

And there, historically, is the answer.  You pass it in via the
command line and parse that at run-time.  So you can use that existing
part of the device tree.

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20130305/b8b2d60d/attachment.pgp>


More information about the U-Boot mailing list