
On Tue, Sep 06, 2005 at 09:47:08PM +0200, Wolfgang Denk wrote:
In above scheme my custom part function allowed only chpart [34], so it was not even possible to change partition to evn sector for example.
Ummm... I can understand what you mean, but this is not how things normally are done in a UNIX environment. It seems a very arbitrary restriction to me, which I wouldn;t like if I was working on such a system.
Ack. I have no strong requirement for such feature.
Moreover it was pretty easy to construct kernel command line this way: setenv bootargs '$bootargs root=/dev/mtdblock$partition ro rootfstype=jffs2'
What prevents you from doing the same now?
Previously I did it in environment:
if test -n $swapos; then if test $ospart -eq 0; then chpart 4; else chpart 3; fi; setenv swapos; saveenv; else if test $ospart -eq 0; then chpart 3; else chpart 4; fi; fi flashargs=run setpart; fixroot; setenv bootargs $bootargs \ root=/dev/mtdblock$partition ro rootfstype=jffs2 fboot=run flashargs;fsload;bootm
This no longer possible, because $partiton is nand0,1 now, so finding corresponding Linux device is more tricky. For now I solved it in C by writing new command which does the trick. Hush doesn't support 'eval' nor something like echo $fs`echo $ospart` where fs0=/dev/mtdblock3 and fs1=/dev/mtdblock4, so it's hard to do it using builtin commands. In case I'm the only one who needs something like this, I'm perfectly fine with my current solution.
Best regards, ladis