summaryrefslogtreecommitdiff
path: root/arch/i386/lib
Commit message (Collapse)AuthorAgeLines
* x86: Convert board_init_f to use an init_sequenceGraeme Russ2011-02-12-41/+29
|
* x86: Rearrange function calls in board_init_fGraeme Russ2011-02-12-8/+8
|
* x86: Split board_init_f() into init_fnc_t compatible functionsGraeme Russ2011-02-12-45/+66
|
* x86: Fix incorrect usage of relocation offsetGraeme Russ2011-02-12-5/+5
| | | | | x86 has always used relocation offset in the opposite sense to the ELF standard - Fix this
* x86: Move console initialisation into board_init_fGraeme Russ2011-02-12-3/+12
|
* x86: Move test for cold boot into init functionsGraeme Russ2011-02-12-10/+7
|
* x86: Move call to dram_init_f into board_init_fGraeme Russ2011-02-12-0/+3
|
* x86: Defer setup of final stackGraeme Russ2011-02-12-2/+4
|
* sc520: Move RAM sizing code from asm to CGraeme Russ2011-02-12-2/+6
|
* x86: Move initial gd to fixed locationGraeme Russ2011-02-12-12/+24
|
* x86: Fix mangled umlautsGraeme Russ2011-02-12-1/+1
| | | | | git mergetool has a nasty habit of mangling umlats - fix ones that have been missed in previous submissions
* x86: Parametize values used in linker scriptGraeme Russ2011-02-12-4/+4
|
* Switch from archive libraries to partial linkingSebastien Carlier2010-11-17-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Before this commit, weak symbols were not overridden by non-weak symbols found in archive libraries when linking with recent versions of binutils. As stated in the System V ABI, "the link editor does not extract archive members to resolve undefined weak symbols". This commit changes all Makefiles to use partial linking (ld -r) instead of creating library archives, which forces all symbols to participate in linking, allowing non-weak symbols to override weak symbols as intended. This approach is also used by Linux, from which the gmake function cmd_link_o_target (defined in config.mk and used in all Makefiles) is inspired. The name of each former library archive is preserved except for extensions which change from ".a" to ".o". This commit updates references accordingly where needed, in particular in some linker scripts. This commit reveals board configurations that exclude some features but include source files that depend these disabled features in the build, resulting in undefined symbols. Known such cases include: - disabling CMD_NET but not CMD_NFS; - enabling CONFIG_OF_LIBFDT but not CONFIG_QE. Signed-off-by: Sebastien Carlier <sebastien.carlier@gmail.com>
* Rename TEXT_BASE into CONFIG_SYS_TEXT_BASEWolfgang Denk2010-10-18-2/+2
| | | | | | | | | | | | The change is currently needed to be able to remove the board configuration scripting from the top level Makefile and replace it by a simple, table driven script. Moving this configuration setting into the "CONFIG_*" name space is also desirable because it is needed if we ever should move forward to a Kconfig driven configuration system. Signed-off-by: Wolfgang Denk <wd@denx.de>
* x86: Implement fully relocatable imageGraeme Russ2010-10-07-11/+14
| | | | | | | | u-boot.bin can be loaded at any 4-byte aligned memory location and directly 'jumped' to using the 'go' command using the load address as the start address. Doing so performs a 'warm boot' which skips memory initialisation and other low-level initialisations, relocates U-Boot to upper memory and starts U-Boot in RAM as per normal 'cold boot'
* x86: Use loops instead of memcpy/memset in board_init_fGraeme Russ2010-10-07-16/+31
| | | | | | | Provides a small speed increase and prepares for fully relocatable image. Downside is the TEXT_BASE, bss, load address etc must ALL be aligned on a a 4-byte boundary which is not such a terrible restriction as everything is already 4-byte aligned anyway
* x86: Rearrange linker scriptGraeme Russ2010-10-07-2/+3
| | | | Tidy up the linker script and discard some sections to save space
* x86: Rename linker script symbolsGraeme Russ2010-10-07-24/+24
| | | | Create more generic names for the symbols exported from the linker script
* x86: Place global data below stack before entering CGraeme Russ2010-10-07-35/+7
| | | | | | | By reserving space for the Global Data immediately below the stack during assembly level initialisation, the C declaration of the static global data can be removed, along with the 'RAM Bootstrap' function. This results in cleaner code, and the ability to pass boot-up flags from assembler into C
* x86: zboot updateGraeme Russ2010-10-07-5/+13
| | | | | | The header of recent Linux Kernels includes the size of the image, and therefore is not needed to be passed to zboot. Still process the third parameter (size of image) in the event that an older kernel is being loaded
* Remove unused CONFIG_SERIAL_SOFTWARE_FIFO featureStefan Roese2010-09-23-7/+0
| | | | | | | | | This patch removes the completely unused CONFIG_SERIAL_SOFTWARE_FIFO feature from U-Boot. It has only been implemented for PPC4xx and was not used at all. So let's remove it and make the code smaller and cleaner. Signed-off-by: Stefan Roese <sr@denx.de> Acked-by: Detlev Zundel <dzu@denx.de>
* x86: Fix do_go_exec() - const argv[]Graeme Russ2010-09-13-5/+20
| | | | | | | | | | | Commit 54841ab50c20d6fa6c9cc3eb826989da3a22d934 made the argv parameter to do_go_exec() const but did not allow for the fact that argv[-1] is set to point to the global data structure and relies on argv being non- const. With this patch, do_go_exec() creates a new copy of the argv array with an extra element to store global data pointer rather than simply clobbering an arbitrary memory location.
* Rename getenv_r() into getenv_f()Wolfgang Denk2010-08-04-1/+1
| | | | | | | | | | | | | | | | | | | While running from flash, i. e. before relocation, we have only a limited C runtime environment without writable data segment. In this phase, some configurations (for example with environment in EEPROM) must not use the normal getenv(), but a special function. This function had been called getenv_r(), with the idea that the "_r" suffix would mean the same as in the _r_eentrant versions of some of the C library functions (for example getdate vs. getdate_r, getgrent vs. getgrent_r, etc.). Unfortunately this was a misleading name, as in U-Boot the "_r" generally means "running from RAM", i. e. _after_ relocation. To avoid confusion, rename into getenv_f() [as "running from flash"] Signed-off-by: Wolfgang Denk <wd@denx.de> Acked-by: Detlev Zundel <dzu@denx.de>
* Make sure that argv[] argument pointers are not modified.Wolfgang Denk2010-07-04-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The hush shell dynamically allocates (and re-allocates) memory for the argument strings in the "char *argv[]" argument vector passed to commands. Any code that modifies these pointers will cause serious corruption of the malloc data structures and crash U-Boot, so make sure the compiler can check that no such modifications are being done by changing the code into "char * const argv[]". This modification is the result of debugging a strange crash caused after adding a new command, which used the following argument processing code which has been working perfectly fine in all Unix systems since version 6 - but not so in U-Boot: int main (int argc, char **argv) { while (--argc > 0 && **++argv == '-') { /* ====> */ while (*++*argv) { switch (**argv) { case 'd': debug++; break; ... default: usage (); } } } ... } The line marked "====>" will corrupt the malloc data structures and usually cause U-Boot to crash when the next command gets executed by the shell. With the modification, the compiler will prevent this with an error: increment of read-only location '*argv' N.B.: The code above can be trivially rewritten like this: while (--argc > 0 && **++argv == '-') { char *arg = *argv; while (*++arg) { switch (*arg) { ... Signed-off-by: Wolfgang Denk <wd@denx.de> Acked-by: Mike Frysinger <vapier@gentoo.org>
* x86: Fix support for booting bzImageGraeme Russ2010-05-06-32/+95
| | | | | | | | | | | Add support for newer (up to 2.6.33) kernels Add zboot command which takes the address of a bzImage as its first argument and (optionally) the size of the bzImage as the second argument (the second argument is needed for older kernels which do not include the bzImage size in the header) Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: Provide weak PC/AT compatibility setup functionGraeme Russ2010-05-06-0/+7
| | | | | | | | | | It is possibly to setup x86 boards to use non-PC/AT configurations. For example, the sc520 is an x86 CPU with PC/AT and non-PC/AT peripherals. This function allows the board to set itself up for maximum PC/AT compatibility just before booting the Linux kernel (the Linux kernel 'just works' if everything is PC/AT compliant) Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: Use CONFIG_SERIAL_MULTIGraeme Russ2010-05-06-1/+4
| | | | Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: Fix copying of Real-Mode code into RAMGraeme Russ2010-05-06-2/+2
| | | | Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: Pass relocation offset into Global DataGraeme Russ2010-05-06-27/+36
| | | | | | | In order to locate the 16-bit BIOS code, we need to know the reloaction offset. Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: Fix do_go_exec()Graeme Russ2010-05-06-4/+4
| | | | | | | This was broken a long time ago by a49864593e083a5d0779fb9ca98e5a0f2053183d which munged the NIOS and x86 do_go_exec() Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* x86: #ifdef out getenv_IPaddr()Graeme Russ2010-05-06-0/+2
| | | | Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
* Move lib_$ARCH directories to arch/$ARCH/libPeter Tyser2010-04-13-0/+3579
Also move lib_$ARCH/config.mk to arch/$ARCH/config.mk This change is intended to clean up the top-level directory structure and more closely mimic Linux's directory organization. Signed-off-by: Peter Tyser <ptyser@xes-inc.com>