Thanks for the comment, Wolfgang.

Agreed that u-boot needs a patch to increase CONFIG_MAX_ARGS.  But my
point is that it's not necessary to put "mmcinfo; mmc init;" in the
command, as I explained like below on the bug page.  With that
removed, the current CONFIG_MAX_ARGS still fits.

Quote from https://bugs.launchpad.net/linaro-image-tools/+bug/659720:
Actually, we do not need to add anything before the first "fatload".
We set the bootcmd in boot.scr, and boot.scr itself is in mmc boot
partition. We have to get mmc ready before doing "fatload boot.scr" in
u-boot. In another word, when u-boot runs at the command in boot.scr,
the mmc must be already initialized.

As mx51evk u-boot implements the generic mmc than legacy one, "mmc
rescan 0" should be used to initialize mmc instead of "mmc init". See
details and patch for mx51evk default env on
https://bugs.launchpad.net/u-boot-linaro/+bug/655461

On Thu, Oct 14, 2010 at 12:36 PM, Wolfgang Denk <w...@denx.de> wrote:
> Dear Shawn Guo,
>
> In message <aanlktimk0hqf69uzq8oid0twaxuuxtsn1zzu_5zeu...@mail.gmail.com> you 
> wrote:
>> The l-m-c is broken for mx51evk due to the following two bugs.  I
>> posted the patches there.  Please review the patches and
>> pick them up if they are ok.
>>
>> The bootcmd setting for mx51evk in l-m-c exceeds max args
>> https://bugs.launchpad.net/linaro-image-tools/+bug/659720
>>
>> === modified file 'linaro-media-create'
>> --- linaro-media-create 2010-10-12 15:31:29 +0000
>> +++ linaro-media-create 2010-10-14 01:29:29 +0000
>> @@ -361,7 +361,7 @@
>>
>>      mx51evk)
>>        cat > ${TMP_DIR}/boot.cmd << BOOTCMD
>> -setenv bootcmd 'mmcinfo; mmc init; fatload mmc 0:2 $KERNEL_ADDR
>> uImage; fatload mmc 0:2 $INITRD_ADDR uInitrd; bootm $KERNEL_ADDR
>> $INITRD_ADDR'
>> +setenv bootcmd 'fatload mmc 0:2 $KERNEL_ADDR uImage; fatload mmc 0:2
>> $INITRD_ADDR uInitrd; bootm $KERNEL_ADDR $INITRD_ADDR'
>>  setenv bootargs '${serial_opts} ${splash_opts} ${lowmem_opt}
>> ${boot_snippet} rootwait ro'
>>  boot
>>  BOOTCMD
>
> Another trivial change is just to omit some of the redundant spaces in
> the command line: s/; /;/g
>
> i.e. change into
>
>        setenv bootcmd 'mmcinfo;mmc init;fatload mmc 0:2 
> $KERNEL_ADDRuImage;fatload mmc 0:2 $INITRD_ADDR uInitrd;bootm $KERNEL_ADDR
>
>
> The correct way to fix this is of course to submit a patch to U-Boot
> to increase the CONFIG_MAX_ARGS option.
>
>
> Best regards,
>
> Wolfgang Denk
>
> --
> DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
> The price of curiosity is a terminal experience.
>                         - Terry Pratchett, _The Dark Side of the Sun_
>



-- 
Regards,
Shawn

_______________________________________________
linaro-dev mailing list
linaro-dev@lists.linaro.org
http://lists.linaro.org/mailman/listinfo/linaro-dev

Reply via email to