Re: [U-Boot] how can i change u-boot load address?
Dear Roman, In message [EMAIL PROTECTED] you wrote: Can the value of TEXT_BASE be arbitrary chosen for test purposes? No, it cannot. You have to define a memory map for your system, which will result in certain restrictions for the choice of TEXT_BASE. In general, you have to understand what you are doing, and in detail. I'm trying to understand how it's done on ARM -- On ARM it's being done wrong - no real relocation is preformed; instead, U-Boot is liked to a fixed address in RAM. The startup code (mostly assembler) can run from ROM (too). 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: [EMAIL PROTECTED] Vulcans believe peace should not depend on force. -- Amanda, Journey to Babel, stardate 3842.3 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Hi Wolfgang Denk, wd wrote: I'm trying to understand how it's done on ARM -- On ARM it's being done wrong - no real relocation is preformed; instead, U-Boot is liked to a fixed address in RAM. The startup code (mostly assembler) can run from ROM (too). If you can tell me what exactly is wrong with ARM startup, i will try to find a solution. Can u point the platform and its startup functions where it is been done correctly. Then i will try to fixup th error in ARM. Thanks in advance Regards Gururaja -- View this message in context: http://www.nabble.com/how-can-i-change-u-boot-load-address--tp19836732p19853320.html Sent from the Uboot - Users mailing list archive at Nabble.com. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Dear Roman, In message [EMAIL PROTECTED] you wrote: On ARM it's being done wrong - no real relocation is preformed; What do you mean by real relocation? As per start.S bootcode is copied from ROM to RAM. Copied to a fixed address where it is actiually already linked for. See my previous message with a lenghty explanation why this is a poor design when dealing with variable sized memory. The problem with the ARM implementation is that the link address is fixed, i. e. it cannot be adjusted to varying RAM sizes. Usually one ports U-Boot on a board with predefined hardware layout, i.e. flash, SDRAM and peripherals are fixed. If hardware changes, say SDRAM size, no big deal to make two/three distinct u-boot images -- after all it ends up by changing TEXT_BASE only, as I understand. This may be your opinion, but it is an isolated one and not shared by *many* board vendors who offer different configurations of boards with smaller and bigger amounts of RAM etc. For these, having only a single binary image of U-Boot for all board configurations is a MAJOR win. Also consider systems which use memory modules. Just try to imagine you have to install a new version of the BIOS on your PC just because you add or remove a memory module. Would you buy such a PC? 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: [EMAIL PROTECTED] (null cookie; hope that's ok) ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Hi, -Original Message- From: Wolfgang Denk [mailto:[EMAIL PROTECTED] Subject: Re: [U-Boot] how can i change u-boot load address? U wouldnt see mapping the vector on (most) ARM Platforms because they use u-boot as secondary bootloader I don't have reliable statistical data to judge if the most is correct, or if it actually is only a few configurations that do this. I meant to say the arm supplied board (integrator[ap/cp], versatile[ap/cp], realview). I said most because ARM Integrator Board doesnt use Arm Bootmonitor hence its code has remapping functionality. From what I'm seeing, most systems use U-oot as primary (and only) boot loader. S its my mistake. sorry for that. Regards Gururaja ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Dear Gururaja Hebbar K R, In message [EMAIL PROTECTED] you wrote: U wouldnt see mapping the vector on (most) ARM Platforms because they use u-boot as secondary bootloader I don't have reliable statistical data to judge if the most is correct, or if it actually is only a few configurations that do this. I said most because ARM Integrator Board doesnt use Arm Bootmonitor hence its code has remapping functionality. From what I'm seeing, most systems use U-oot as primary (and only) boot loader. 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: [EMAIL PROTECTED] The only person who always got his work done by Friday was Robinson Crusoe. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Hello 2008/10/7 Wolfgang Denk [EMAIL PROTECTED]: The advantage of the PowerPC implementation with relocation is that we can measure the actual size of memory present on the board, and then relocate U-Boot to the very end of the RAM, leaving nearly th When you say end of the RAM', I think you mean higher addresses, i.e. 0x_ downwards or lower 0x000_ onwards? (this depends on how to look at memory map, written on a sheet of paper -- straight or upside down :-) ). So the bottom line of PPC architecture is that it tries to have unified booting/relocation process for every platform? For instance, always copy itself in the upper addresses, occupying, say, 128kB or so of RAM. whole RAM usable as one big contiguous area for applications like loading Linux kernel, ramdisk, etc. [skip] Just try to imagine you have to install a new version of the BIOS on your PC just because you add or remove a memory module. Would you buy such a PC? Well, you convinced me; but despite its flaws and drawbacks the current ARM port architecture exists and it is here to stay for quite awhile, unless there will be some hero ready to break it up and build a new from scratch. -- Roman Mashak ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
On Mon, Oct 6, 2008 at 7:13 AM, sahar mustafa [EMAIL PROTECTED] wrote: can you tell me how to change the load address without crippling the u-boot? It's not 100% clear what you are trying to do, and you didn't mention your target other than it's MIPS... If you want to build a version of u-boot that is linked to a start address that is in RAM for loading via a jtag debugger, then change the definition of TEXT_BASE in board/your board name here/config.mk. You have to make sure that u-boot doesn't try to re-initialize the ram or caches, and doesn't write over parts of itself when it relocates or allocates memory for the stack and heap. If you want to make sure u-boot is still linked in ROM, but gets put at the top of memory during relocation, then you have to make sure the initdram() function in your code returns the correct ram size. If you look in lib_mips/board.c board_init_f(), ram starts being allocated top down, starting at CFG_SDRAM_BASE + gd-ram_size. gd-ram_size is initialized by the return value of a call to initdram() which is usually somewhere in the board specific code. -- Hardware, n.: The parts of a computer system that can be kicked. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] how can i change u-boot load address?
Hello Andrew, 2008/10/6 Andrew Dyer [EMAIL PROTECTED]: If you want to build a version of u-boot that is linked to a start address that is in RAM for loading via a jtag debugger, then change the definition of TEXT_BASE in board/your board name here/config.mk. Can the value of TEXT_BASE be arbitrary chosen for test purposes? If you want to make sure u-boot is still linked in ROM, but gets put at the top of memory during relocation, then you have to make sure the initdram() function in your code returns the correct ram size. As I understand it's valid for MIPS or PPC based architectures, right? On many MCUs built on arm7tdmi core (for example, SAM7 family from Atmel) the process of starting up involves remapping, i.e. 0x0 address points on ROM at reset and on RAM after remap. U-Boot usually resides in ROM storage at startup, after reset relocates itself to RAM -- should not it involve remapping as well? I didn't find how it's done in U-Boot (if it's done at all). Would appreciate a lot for clarification. I'm trying to understand how it's done on ARM -- -- Roman Mashak ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot