This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: moving RedBoot config from one device to another - is "dd" enough?


Andrew Lunn wrote:
Tomasz Chmielewski wrote:

So let's say I have a "master" device (properly configured), and the devices I need to reconfigure.

If I do this on a "master" device (Linux already started):

# /dev/mtd3 is a "RedBoot config" partition
dd if=/dev/mtd3 of=new-redboot-config


And then, on the devices I want to reconfigure (Linux already started):


dd if=new-redboot-config of=/dev/mtd3


Will this work properly? Will the new device have its starting sequence changed to:


RedBoot> fis load kern2
RedBoot> exec

?

Perhaps, I should use something like "erase /dev/mtd3 0 12 1" first?


The basic concept is O.K. Im not familiar with mtd, so i've no idea if you need to erase the block first, or if writing to it will automagically erase it.

Indeed it works like that.


I erased the RedBoot partition first, used dd to flash the config I wanted to use, made sure that the sums are the same on both devices:

# md5sum /dev/mtd[0-4]
b0065fbf12b5babdc3ebac248b7ad2e8  /dev/mtd0
6e04dd840d2d3d101f6ee390b5ddefd2  /dev/mtd1
0cc305797ca5751fe8de793fbcc2ab62  /dev/mtd2
b76500f62dce7cb3b949b3d6ebde6034  /dev/mtd3
7c6a2f0e0c424101f8d5494b4065afc1  /dev/mtd4


And it works! :)



-- Tomasz Chmielewski http://wpkg.org

--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]