22 Feb, 2014
2 commits
-
This function has been around for powerpc. It is used for systems with
memory more than CONFIG_MAX_MEM_MAPPED. In case of non-contiguous memory,
this feature can limit U-boot to one block without going over the limit.Signed-off-by: York Sun
Acked-by: Albert ARIBAUD -
do_bootm_standanlone() calls ntohl(images->ep) which is wrong because
endianess conversion has already been done:do_bootm()
\-do_bootm_states()
+-bootm_find_os()
| \-images.ep = image_get_ep();
| \-uimage_to_cpu(hdr->ih_ep);
\-boot_selected_os()
\-do_bootm_standanlone()Without this conversion the code works correctly at least on AT91SAM9G45.
On big endian systems there should be no difference after applying this
patch because uimage_to_cpu(x) and ntohl(x) both expand to 'x'.Signed-off-by: Christian Eggers
21 Feb, 2014
2 commits
-
We have an unused FAT implementation in fs/fdos, remove.
Signed-off-by: Tom Rini
-
With d6a320d we moved some clock externs out of blackfin_local.h and
into clock.h but now need to include in more drivers to
avoid warnings.Cc: Sonic Zhang
Signed-off-by: Tom Rini
20 Feb, 2014
5 commits
-
There is a strange comment in fit_image_load().
This function can be used for loading Kernel Image, FDT
as well as ramdisk.Signed-off-by: Masahiro Yamada
Cc: Simon Glass
Acked-by: Simon Glass -
- When CONFIG_DISPLAY_CPUINFO is not enabled,
print_cpuinfo() should be defined as an empty function
in a header, include/common.h- Remove #ifdef CONFIG_DISPLAY_CPUINFO .. #endif
from caller, common/board_f.c and arch/arm/lib/board.c- Remove redundant prototypes in arch/arm/lib/board.c,
arch/arm/include/asm/arch-am33x/sys_proto.h and
board/nokia/rx51/rx51.h, keeping the one in include/common.h- Add #ifdef CONFIG_DISPLAY_CPUINFO to the func definition
where it is missingSigned-off-by: Masahiro Yamada
-
Useful rules in scripts/Makefile.lib allows us to easily
generate a device tree blob and wrap it in assembly code.We do not need to parse a linker script to get output format and arch.
This commit deletes ./u-boot.dtb since it is a copy of dts/dt.dtb.
Signed-off-by: Masahiro Yamada
-
Now we are ready to switch over to real Kbuild.
This commit disables temporary scripts:
scripts/{Makefile.build.tmp, Makefile.host.tmp}
and enables real Kbuild scripts:
scripts/{Makefile.build,Makefile.host,Makefile.lib}.This switch is triggered by the line in scripts/Kbuild.include
-build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build.tmp obj
+build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build objWe need to adjust some build scripts for U-Boot.
But smaller amount of modification is preferable.Additionally, we need to fix compiler flags which are
locally added or removed.In Kbuild, it is not allowed to change CFLAGS locally.
Instead, ccflags-y, asflags-y, cppflags-y,
CFLAGS_$(basetarget).o, CFLAGS_REMOVE_$(basetarget).o
are prepared for that purpose.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig -
This commit changes the working directory
where the build process occurs.Before this commit, build process occurred under the source
tree for both in-tree and out-of-tree build.That's why we needed to add $(obj) prefix to all generated
files in makefiles like follows:
$(obj)u-boot.bin: $(obj)u-bootHere, $(obj) is empty for in-tree build, whereas it points
to the output directory for out-of-tree build.And our old build system changes the current working directory
with "make -C " syntax when descending into the
sub-directories.On the other hand, Kbuild uses a different idea
to handle out-of-tree build and directory descending.The build process of Kbuild always occurs under the output tree.
When "O=dir/to/store/output/files" is given, the build system
changes the current working directory to that directory and
restarts the make.Kbuild uses "make -f $(srctree)/scripts/Makefile.build obj="
syntax for descending into sub-directories.
(We can write it like "make $(obj)=" with a shorthand.)
This means the current working directory is always the top
of the output directory.Signed-off-by: Masahiro Yamada
Tested-by: Gerhard Sittig
19 Feb, 2014
8 commits
-
Add spl_sata to read a fat partition from a bootable SATA
drive.Signed-off-by: Dan Murphy
Reviewed-by: Roger Quadros -
Unlike other commands (for example, "fatwrite"), ext4write would
interpret the "sizebytes" as decimal number. This is not only
inconsistend and unexpected to most users, it also breaks usage
like this:tftp ${addr} ${name}
ext4write mmc 0:2 ${addr} ${filename} ${filesize}Change this to use the standard notation of base 16 input format.
See also commit b770e88WARNING: this is a change to the user interface!!
Signed-off-by: Wolfgang Denk
Cc: Uma Shankar
Cc: Stephen Warren -
Signed-off-by: Masahiro Yamada
Acked-by: Simon Glass -
This is much like a regular shell's -e operator, except that it takes
multiple arguments to specify the device type and device/partition ID
in addition to the usual filename:if test -e mmc 0:1 /boot/boot.scr; then echo yes; else echo no; fi
Signed-off-by: Stephen Warren
-
This emulates bash:
$ if test; then echo yes; else echo no; fi
noCurrently, the code sets expr = -1 in this case, which gets mapped to
0 (true) at the end of do_test() by the logical -> shell exit code
conversion.Signed-off-by: Stephen Warren
-
Currently, ! can only be parsed as the first operator in an expression.
This prevents the following from working:$ if test ! ! 1 -eq 1; then echo yes; else echo no; fi
yes
$ if test ! 1 -eq 2 -a ! 3 -eq 4; then echo yes; else echo no; fi
yesFix this by parsing ! like any other operator, and and handling it
similarly to -a and -o.Signed-off-by: Stephen Warren
-
This better mirrors the behaviour of bash, for example:
$ if test -z = -z; then echo yes; else echo no; fi
yesThis is parsed as a string comparison of "-z" and "-z", since the check
for the binary "=" operator occurs first. Without this change, the
command would be parsed as a -z test of "-", followed by a syntax error;
a trailing -z without and operand.This is a behavioural change, but I believe any commands affected were
previously invalid or bizarely formed.Signed-off-by: Stephen Warren
-
do_test() currently uses strcmp() twice to determine which operator is
present; once to determine how many arguments the operator needs, then
a second time to actually decode the operator and implement it.Rewrite the code so that a table lookup is used to translate the operator
string to an integer, and use a more efficient switch statement to decode
and execute the operator.This approach also acts as enablement for the following patches.
This patch should introduce no behavioural change.
Signed-off-by: Stephen Warren
18 Feb, 2014
2 commits
08 Feb, 2014
6 commits
-
The open and close mmc sub-commands implement a hard-coded set of values
specific to the SMDK5250 platform. Remove these commands as what they
did can be done instead with a series of mmc dev / bootpart / bootbus
commands instead now.Cc: Amar
Cc: Minkyu Kang
Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Add a bootbus sub-command to the mmc command to allow for setting
the boot_bus_width, reset_boot_bus_width and boot_mode fields of
BOOT_BUS_WIDTH (EXT_CSD[177]).Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Add a partconf sub-command to the mmc command to allow for setting
the boot_ack, boot_partition and partition_access fields of
PARTITION_CONFIG (formerly BOOT_CONFIG, EXT_CSD[179]). Part of this
requires changing the check for 'part' from an strncmp to a strcmp, like
the rest of the sub-commands.Cc: Andy Fleming
Cc: Pantelis Antoniou
Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Rename 'bootpart' to 'bootpart-resize' to better reflect what this
command is for.Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
Acked-by: Jaehoon Chung
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou -
We use the switch CONFIG_SUPPORT_EMMC_BOOT today to enable some
additional features of the eMMC boot partitions. Add support for being
told that we have booted from one of these partitions to the spl
framework and implement this on TI OMAP/related.Cc: Pantelis Antoniou
Signed-off-by: Tom Rini
Signed-off-by: Pantelis Antoniou
07 Feb, 2014
1 commit
-
Signed-off-by: Alexey Brodkin
Cc: Vineet Gupta
Cc: Francois Bedard
Cc: Wolfgang Denk
Cc: Heiko Schocher
05 Feb, 2014
4 commits
-
Signed-off-by: Dennis Gilmore
-
People who write (or scripts that auto-generate) extlinux.conf don't
want to know about HW-specific information such as FDT filenames. Create
a new extlinux.conf tag "fdtdir" that specifies only the directory where
FDT files are located, and defer all knowledge of the filename to U-Boot.
The algorithm implemented is:==========
if $fdt_addr_r is set:
if "fdt" tag was specified in extlinux.conf:
load the FDT from the filename in the tag
else if "fdtdir" tag was specified in extlinux.conf:
if "fdtfile" is set in the environment:
load the FDT from filename in "$fdtfile"
else:
load the FDT from some automatically generated filenameif no FDT file was loaded, and $fdtaddr is set:
# This indicates an FDT packaged with firmware
use the FDT at $fdtaddr
==========A small part of an example /boot/extlinux.conf might be:
==========
LABEL primary
LINUX zImage
FDTDIR ./LABEL failsafe
LINUX bkp/zImage
FDTDIR bkp/
==========... with /boot/tegra20-seaboard.dtb or /boot/bkp/tegra20-seaboard.dtb
being loaded by the sysboot/pxe code.Signed-off-by: Stephen Warren
-
The specification for extlinux.conf[1] states that "fdt" is an alias for
"devicetree". To date, U-Boot only implements "fdt". Rectify that.[1] http://freedesktop.org/wiki/Specifications/BootLoaderSpec/
Signed-off-by: Stephen Warren
04 Feb, 2014
1 commit
-
Command provides just dump subcommand for showing clock
frequencies in a soc.Signed-off-by: Michal Simek
Acked-by: Stefano Babic
03 Feb, 2014
1 commit
-
Changes:
- le16_to_cpu() to get_unaligned_le16()
- le32_to_cpu() to get_unaligned_le32()
when access fields in struct bmp header.This changes avoids data abort exception caused by unaligned data access.
Signed-off-by: Przemyslaw Marczak
Acked-by: Anatolij Gustschin
Signed-off-by: Minkyu Kang
27 Jan, 2014
1 commit
-
This is only required for "PIC" relocation and doesn't apply to modern
"PIE" relocation which does data relocation as well as code."init_sequence_r" is just an array that consists of compile-time
adresses of init functions. Since this is basically an array of integers
(pointers to "void" to be more precise) it won't be modified during
relocation - it will be just copied to new location as it is.As a consequence on execution after relocation "initcall_run_list" will
be jumping to pre-relocation addresses. As long as we don't overwrite
pre-relocation memory area init calls are executed correctly. But still
it is dangerous because after relocation we don't expect initially used
memory to stay untouched.Cc: Tom Rini
Cc: Masahiro Yamada
Cc: Doug Anderson
Cc: Thomas Langer
Cc: Albert ARIBAUD
Acked-by: Simon Glass
Signed-off-by: Alexey Brodkin
25 Jan, 2014
2 commits
-
Add SPL support to be able to detect a USB Mass Storage device
connected to a USB host. Once a USB Mass storage device is detected
the SPL will load the u-boot.img from a FAT partition to target address.Signed-off-by: Dan Murphy
-
Move the FAT functions to a common location for reuse.
Signed-off-by: Dan Murphy
21 Jan, 2014
1 commit
-
The change to add 64bit initrd support broke 32bit initrd support as it
always set 64bits worth of data into the properties, even on 32bit
systems. The fix is to use addr_cell_len (which already says how much
data is in 'tmp') to set the property, rather than always setting 8.
Thanks to Stephen Warren for pointing out the fix here.Reported-by: Otavio Salvador
Signed-off-by: Tom Rini
20 Jan, 2014
1 commit
14 Jan, 2014
3 commits
-
when creating the hashtable, for each environmentvariable
getenv(ENV_CALLBACK_VAR) and getenv(ENV_FLAGS_VAR) is called,
which costs at this point a lot of time. So call this two
getenv() calls only once.Boottime on the ids8313 board without this patch:
2013-12-19 13:38:22,894: NAND: 128 MiB
2013-12-19 13:38:27,659: In: serial
(~4.8 sec)Bootime with this patch on the ids8313 board:
2013-12-19 13:40:25,332: NAND: 128 MiB
2013-12-19 13:40:25,546: In: serial
(~0.2 sec)Signed-off-by: Heiko Schocher
Cc: Tom Rini
Cc: Joe Hershberger
Cc: Wolfgang Denk -
For standalone images, bootm had a special case where the OS boot function
was NULL but did actually exist. It was just called manually.This was removed by commit 35fc84fa which checks for the non-existence of
this function before the special case is examined.There is no obvious reason why standalone is handled with a special case.
Adjust the code so that standalone has a normal OS boot function. We still
need a special case for when the function returns, but at least we can
avoid the main problem.This is intended to fix the reported:
ERROR: booting os 'U-Boot' (17) is not supported
but needs testing.
Signed-off-by: Simon Glass
-
Otherwise, when booting VxWorks kernel, the incorrect message will
be seen:ARM Unknown OS Kernel Image (uncompressed)
Signed-off-by: Miao Yan