[U-Boot] uboot for MIPS: need help to skip relocate uboot and start uboot from RAM
Pandurang Kale
kale.pandurang at gmail.com
Thu Mar 3 16:50:24 CET 2011
Hi Charles,
Thanks for the info.
We have a primary boot loader, which read the flash which might contain
more than one existing mod-image(containing header, uboot and kernel) and
depending on the state and condition it decides which mod is valid and
copies the uboot from the valid mod-image to RAM.
So our primary bootloader is needed to load correct version of u-boot to
RAM from flash. But I am looking for a fix where in the uboot should setup
the stack and gp and start executing from RAM and not to copy/relocate
itself all over again to different RAM (High-memory region) location.
Thanks,
Pandu
On Thu, Mar 3, 2011 at 3:27 PM, Charles Krinke <charles.krinke at gmail.com>wrote:
> Dear Pandurang:
>
> Sounds like you have battling boot loaders going on, perhaps with the
> Broadcom CFE (Common Firmware Environment) ?
>
> Someone else may have some data on CONFIG_SKIP_RELOCATE_UBOOT, or you could
> reflash your target and replace the existing bootloader with the U-Boot
> bootloader so your bootloaders are not battling for the same resource.
>
> Charles
>
> On Thu, Mar 3, 2011 at 2:08 AM, Pandurang Kale <kale.pandurang at gmail.com>wrote:
>
>> Hello Everyone,
>>
>> We have MIPS based development board and I am trying to get the uboot up
>> and
>> running on it.
>> We have a primary bootloader which check for the valid mod-image stored on
>> the flash. This mod-image consist of header, uboot and linux kernel.
>> Depending on the recent, active and stable imagethe primary bootloader
>> first
>> copies the uboot image. and later on we would copy the kernel image from
>> uboot.
>>
>> But when primary bootloader copies the uboot image to the RAM and passes
>> the
>> control to the uboot, uboot (MIPS version of start.S and
>> arch/mips/lib/borad.c) tries to relocate the
>> already copied image from RAM (the primary bootloader copied it to start
>> of
>> the RAM+1MB address) to top of the RAM (0x87fc0000) region thinking that
>> the
>> uboot image is stored in flash.
>>
>> All I need to do is skip the uboot relocate code in MIPS version of uboot
>> startup as the primary bootloader has already relocated the uboot from
>> Flash
>> to RAM and set up the stack pointer and other global data appropriately,
>> which it does after relocation.
>> I can see there is a switch for ARM processor, CONFIG_SKIP_RELOCATE_UBOOT,
>> which skips the relocation of uboot code and tries to run the uboot from
>> RAM. I
>> cannot see a similar switch implemented for MIPS and didnt find any
>> related
>> thread anywhere in mailing list or on net.
>>
>> Do we have similar ARM like switch to SKIP the RELOCATION? If not has
>> anyone
>> done this before?
>>
>> I would really appreciate if you can guide me to overcome this issue to
>> run
>> the uboot cleanly skipping the relocation.
>>
>> Thanks in advance,
>> Pandu
>>
>> _______________________________________________
>> U-Boot mailing list
>> U-Boot at lists.denx.de
>> http://lists.denx.de/mailman/listinfo/u-boot
>>
>>
>
>
> --
> Charles Krinke
>
>
>
More information about the U-Boot
mailing list