From: Murray.Jensen at csiro.au <Murray.Jensen@csiro.au>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] expand macros in bootargs env var for bootm command
Date: Fri, 01 Jul 2005 00:37:28 +1000 [thread overview]
Message-ID: <9752.1120142248@huldra> (raw)
In-Reply-To: Your message of "Thu, 30 Jun 2005 15:43:53 +0200" <20050630134353.41D54353A0E@atlas.denx.de>
On Thu, 30 Jun 2005 15:43:53 +0200, Wolfgang Denk writes:
>You can expand all macros when building the bootargs variable like it
>is shown in all the examples in the DULG; is there any problem with
>that?
Quoting from the DULG:
"We can use U-Boot environment variables to store all necessary configuration
parameters:
=> setenv ipaddr 10.0.0.99
=> setenv serverip 10.0.0.2
=> setenv netmask 255.0.0.0
=> setenv hostname tqm
=> setenv rootpath /opt/eldk/ppc_8xx
=> saveenv
Then you can use these variables to build the boot arguments to be passed to
the Linux kernel:
=> setenv bootargs root=/dev/nfs rw nfsroot=\$(serverip):\$(rootpath) ip=\$(ipaddr):\$(serverip):\$(gatewayip):\$(netmask):\$(hostname)::off
Note how backslashes are used to delay the substitution of the referenced
environment variables. This way, the current values of these variables get
inserted when the "bootargs" variable itself is used, i. e. when the kernel
gets booted. This allows us to simply redefine any of the variables (say, the
value of "ipaddr" if it has to be changed), and the changes will
automatically propagate to the Linux kernel."
But I found that this (or at least, an almost identical situation) simply
didn't work. Macros in the bootargs variable weren't expanded when the kernel
was booted. Maybe I've missed something?
>See section "Submitting Patches" in the README.
>
>There is no excuse for not reding the README.
Except that I read the README file many years ago before this section
was in there. Obviously, I need to re-read it. Cheers!
Murray...
--
Murray Jensen, CSIRO Manufacturing & Infra. Tech. Phone: +61 3 9662 7763
Locked Bag No. 9, Preston, Vic, 3072, Australia. Fax: +61 3 9662 7853
Internet: Murray.Jensen at csiro.au
To the extent permitted by law, CSIRO does not represent, warrant and/or
guarantee that the integrity of this communication has been maintained or
that the communication is free of errors, virus, interception or interference.
The information contained in this e-mail may be confidential or privileged.
Any unauthorised use or disclosure is prohibited. If you have received this
e-mail in error, please delete it immediately and notify Murray Jensen on
+61 3 9662 7763. Thank you.
next prev parent reply other threads:[~2005-06-30 14:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-30 6:25 [U-Boot-Users] [PATCH] expand macros in bootargs env var for bootm command Murray.Jensen at csiro.au
2005-06-30 10:25 ` Wolfgang Denk
2005-06-30 13:23 ` Murray.Jensen at csiro.au
2005-06-30 13:43 ` Wolfgang Denk
2005-06-30 14:37 ` Murray.Jensen at csiro.au [this message]
2005-06-30 15:15 ` Wolfgang Denk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9752.1120142248@huldra \
--to=murray.jensen@csiro.au \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox