mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Stefan Christ <s.christ@phytec.de>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH v2] barebox update: add note after successful update
Date: Thu, 18 Jun 2015 09:57:23 +0200	[thread overview]
Message-ID: <20150618075723.GB2575@lws-christ> (raw)
In-Reply-To: <20150616135241.GT6325@pengutronix.de>

Hi Sascha,

> I would find this message more useful from the new, updated barebox
> rather than from the barebox that does the update. This way we could
> also see the message with offline updates when for example a SD
> card has been updated on an external host. Also we would have more
> freedom to react on an outdated environment in the next steps. We could
> for example make it configurable to completely ignore an outdated
> environment or just to issue a warning message.
> Doing this should be fairly simple, we could store the barebox version
> in a nv variable and compare the variable with the current version
> during startup.
> 
> What do you think?

This would solve the issue for our users.

If I understand you correctly, this approach is different from a separate
versioning of the environment data, since the barebox verison in UTS_RELEASE is
written to the nv variable. So nobody can forget to increase the version number
of the environment and a warning message is printing to the user as a new
barebox with a different version is flashed.

I looked at the code a bit. The first step would be to write the version of the
running barebox into environment in the function envfs_save() and compare the
version in the function envfs_load(). Correct? In envfs_load() the warning
message would be printed.

But we cannot interrupt the boot sequence and ask the user whether he/she wants
to use the old environment or use the default environment, because the default
boot process must be non-interactive. So only a warning can be printed, right?

Mit freundlichen Grüßen / Kind regards,
	Stefan Christ

On Tue, Jun 16, 2015 at 03:52:41PM +0200, Sascha Hauer wrote:
> Hi Stefan,
> 
> On Mon, Jun 15, 2015 at 12:20:08PM +0200, Stefan Christ wrote:
> > Hi Sascha,
> > 
> > *ping, is this patch acceptable?
> 
> I thought about this again.
> 
> I would find this message more useful from the new, updated barebox
> rather than from the barebox that does the update. This way we could
> also see the message with offline updates when for example a SD
> card has been updated on an external host. Also we would have more
> freedom to react on an outdated environment in the next steps. We could
> for example make it configurable to completely ignore an outdated
> environment or just to issue a warning message.
> Doing this should be fairly simple, we could store the barebox version
> in a nv variable and compare the variable with the current version
> during startup.
> 
> What do you think?
> 
> Sascha
> 
> -- 
> Pengutronix e.K.                           |                             |
> Industrial Linux Solutions                 | http://www.pengutronix.de/  |
> Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2015-06-18  7:57 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-05  7:51 Stefan Christ
2015-06-05  7:51 ` Stefan Christ
2015-06-05  7:59   ` Eric Bénard
2015-06-09  9:05     ` Stefan Christ
2015-06-15 10:20   ` Stefan Christ
2015-06-16 13:52     ` Sascha Hauer
2015-06-18  7:57       ` Stefan Christ [this message]
2015-06-18  9:10         ` Sascha Hauer

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=20150618075723.GB2575@lws-christ \
    --to=s.christ@phytec.de \
    --cc=barebox@lists.infradead.org \
    --cc=s.hauer@pengutronix.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