* Determining barebox version from linux
@ 2010-12-23 0:03 Marc Reilly
2010-12-23 6:18 ` Baruch Siach
0 siblings, 1 reply; 3+ messages in thread
From: Marc Reilly @ 2010-12-23 0:03 UTC (permalink / raw)
To: barebox
Hi,
I want to be able to determine what version of barebox I have on my NOR flash,
after booting into linux.
The easiest way I thought of is something like:
cat /dev/mtd0 | grep "barebox 2010"
Another way to do this is to have the version_string (or other version info)
at a fixed location in the barebox image. This feels like a overly rigid
solution, and may be a pain to put into the build system.
Does anybody else accomplish this in a better way? (I don't want to pass the
barebox version as an arg when booting the kernel - I'd rather it be more
"standalone").
Cheers
Marc
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Determining barebox version from linux
2010-12-23 0:03 Determining barebox version from linux Marc Reilly
@ 2010-12-23 6:18 ` Baruch Siach
2010-12-23 7:07 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 1 reply; 3+ messages in thread
From: Baruch Siach @ 2010-12-23 6:18 UTC (permalink / raw)
To: Marc Reilly; +Cc: barebox
Hi Marc,
On Thu, Dec 23, 2010 at 11:03:31AM +1100, Marc Reilly wrote:
> I want to be able to determine what version of barebox I have on my NOR
> flash, after booting into linux.
[snip]
> Does anybody else accomplish this in a better way? (I don't want to pass the
> barebox version as an arg when booting the kernel - I'd rather it be more
> "standalone").
I set the board revision number, using armlinux_set_revision(), to pass the
version of the bootloader to the kernel, and then extract it from the
'Revision' field in /proc/cpuinfo. This solution is ARM specific, though.
baruch
--
~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Determining barebox version from linux
2010-12-23 6:18 ` Baruch Siach
@ 2010-12-23 7:07 ` Jean-Christophe PLAGNIOL-VILLARD
0 siblings, 0 replies; 3+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2010-12-23 7:07 UTC (permalink / raw)
To: Baruch Siach; +Cc: barebox
On 08:18 Thu 23 Dec , Baruch Siach wrote:
> Hi Marc,
>
> On Thu, Dec 23, 2010 at 11:03:31AM +1100, Marc Reilly wrote:
> > I want to be able to determine what version of barebox I have on my NOR
> > flash, after booting into linux.
>
> [snip]
>
> > Does anybody else accomplish this in a better way? (I don't want to pass the
> > barebox version as an arg when booting the kernel - I'd rather it be more
> > "standalone").
>
> I set the board revision number, using armlinux_set_revision(), to pass the
> version of the bootloader to the kernel, and then extract it from the
> 'Revision' field in /proc/cpuinfo. This solution is ARM specific, though.
It will be better to have a std way as you mqy ise the system_rev for other
stuff as example on some at91
I sync we could generate a /etc/version in the env and then export it in linux
via the fs
I think we could do like this
in barebox itself we keep a default read only fs (default env) that we merge
the same way as a unionfs in barebox to avoid duplication and allow non
modifable file with the rw env
and we will do it in linux also
so linux can get the data from barebox and modify it
Best Regards,
J.
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-12-23 7:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-23 0:03 Determining barebox version from linux Marc Reilly
2010-12-23 6:18 ` Baruch Siach
2010-12-23 7:07 ` Jean-Christophe PLAGNIOL-VILLARD
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox