All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [RFC] skip area in flash/memory commands (cp, cmp, ...)
@ 2011-04-11 18:52 Andreas Pretzsch
  2011-04-11 19:31 ` Albert ARIBAUD
  0 siblings, 1 reply; 7+ messages in thread
From: Andreas Pretzsch @ 2011-04-11 18:52 UTC (permalink / raw)
  To: u-boot

Objective: Skip an area in memory commands

Example use case: Skip over embedded environment when updating U-Boot

In case of an embedded environment, a complete U-Boot binary consists of
two code sections and an environment block in between. In an update flow
tftp/erase/cp/cmp conveniently using the complete image, the environment
is also overwritten. As the env might contain device specific data, this
is not always desirable.
Of course, one could overcome this with several approaches, e.g.
  - provide two distinct U-Boot parts on the tftp server
  - load the complete image and erase/cp/cmp only the desired parts,
    either via hardcoded addresses and sizes or via some setexpr magic
  - other ways I simply missed

While this is sufficent, I'd find it handy to be able to skip an area in
the above commands.
Possible approaches:
  - explicit via additional parameters to cp, cmp, etc.
  - implicit for the embedded environment (confusing and less generic)
  - based on e.g. some skip_addr, skip_len environment variables or
    even sets (addr1,addr2 + len1,len2)

There might be other use cases I didn't thought of by now. Also, the
command list is probably not complete.

What do you think, worth the effort, acceptable in mainline or
over-engineering ?


-- 

carpe noctem engineering
Ingenieurbuero fuer Hard- & Software-Entwicklung Andreas Pretzsch
Dipl.-Ing. (FH) Andreas Pretzsch          Tel. +49-(0)731-5521572
Hahnengasse 3                             Fax: +49-(0)731-5521573
89073 Ulm, Germany                        email: apr at cn-eng.de

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-04-13 19:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-11 18:52 [U-Boot] [RFC] skip area in flash/memory commands (cp, cmp, ...) Andreas Pretzsch
2011-04-11 19:31 ` Albert ARIBAUD
2011-04-11 19:57   ` Andreas Pretzsch
2011-04-11 21:08     ` Wolfgang Denk
2011-04-12 13:28       ` Andreas Pretzsch
2011-04-12 14:15         ` Wolfgang Denk
2011-04-13 19:57           ` Andreas Pretzsch

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.