- Jan 25, 2016
-
-
Simon Glass authored
Now that they are in their own directory, we can remove this prefix. This makes it easier to find a file since the prefix does not get in the way. Signed-off-by:
Simon Glass <sjg@chromium.org> Reviewed-by:
Bin Meng <bmeng.cn@gmail.com> Reviewed-by:
Heiko Schocher <hs@denx.de> Acked-by:
Stefan Roese <sr@denx.de> Acked-by:
Przemyslaw Marczak <p.marczak@samsung.com>
-
Simon Glass authored
There are a lot of unrelated files in common, including all of the commands. Moving them into their own directory makes them easier to find and is more logical. Some commands include non-command code, such as cmd_scsi.c. This should be sorted out at some point so that the function can be enabled with or without the associated command. Unfortunately, with m68k I get this error: m68k: + M5329AFEE +arch/m68k/cpu/mcf532x/start.o: In function `_start': +arch/m68k/cpu/mcf532x/start.S:159:(.text+0x452): relocation truncated to fit: R_68K_PC16 against symbol `board_init_f' defined in .text.board_init_f section in common/built-in.o I hope someone can shed some light on what this means. I hope it isn't depending on the position of code in the image. Signed-off-by:
Simon Glass <sjg@chromium.org> Reviewed-by:
Bin Meng <bmeng.cn@gmail.com> Reviewed-by:
Heiko Schocher <hs@denx.de> Acked-by:
Stefan Roese <sr@denx.de> Acked-by:
Przemyslaw Marczak <p.marczak@samsung.com>
-
- Jul 27, 2015
-
-
Stephen Warren authored
The sysboot and pxe commands currently support either U-Boot formats or raw zImages. Add support for the AArch64 Linux port's native image format too. As with zImage support, there is no auto-detection of the native image format. Rather, if the image is auto-detected as a U-Boot format, U-Boot will try to interpret it as such. Otherwise, U-Boot will fall back to a raw/native image format, if one is enabled. My belief is that CONFIG_CMD_BOOTZ won't ever be enabled for any AArch64 port, hence there's never a need to differentiate between CONFIG_CMD_ _BOOTI and _BOOTZ at run-time; compile-time will do. Even if this isn't true, we want to prefer _BOOTI over _BOOTZ when defined, since _BOOTI is definitely the native format for AArch64. Change-Id: I83c5cc7566032afd72516de46f4e5eb7a780284a Signed-off-by:
Stephen Warren <swarren@nvidia.com> Signed-off-by:
Tom Warren <twarren@nvidia.com>
-
- May 27, 2015
-
-
Tuomas Tynkkynen authored
Previously, a NULL pointer dereference would occur if the 'sysboot' command is executed without any arguments. Signed-off-by:
Tuomas Tynkkynen <tuomas.tynkkynen@iki.fi> Reviewed-by:
Simon Glass <sjg@chromium.org>
-
- Apr 19, 2015
-
-
Sjoerd Simons authored
Properly map memory through map_sysmem so that pxe can be used from the sandbox. Tested in sandbox as well as on jetson-tk1, odroid-xu3, snow as peach-pi boards Signed-off-by:
Sjoerd Simons <sjoerd.simons@collabora.co.uk> Acked-by:
Simon Glass <sjg@chromium.org>
-
- Apr 18, 2015
-
-
Joe Hershberger authored
The variables around the bootfile were inconsistent and used CamelCase. Update them to make the code more readable. Signed-off-by:
Joe Hershberger <joe.hershberger@ni.com> Acked-by:
Simon Glass <sjg@chromium.org>
-
Joe Hershberger authored
This patch is simply clean-up to make the IPv4 type that is used match what Linux uses. It also attempts to move all variables that are IP addresses use good naming instead of CamelCase. No functional change. Signed-off-by:
Joe Hershberger <joe.hershberger@ni.com> Acked-by:
Simon Glass <sjg@chromium.org>
-
Joe Hershberger authored
In the case where the arch defines a custom map_sysmem(), make sure that including just mapmem.h is sufficient to have these functions as they are when the arch does not override it. Also split the non-arch specific functions out of common.h Signed-off-by:
Joe Hershberger <joe.hershberger@ni.com> Reviewed-by:
Simon Glass <sjg@chromium.org>
-
- Oct 10, 2014
-
-
Ian Campbell authored
On a couple of platforms I've tripped over long PXE append lines overflowing this array, due to having CONFIG_SYS_CBSIZE == 256. When doing preseeded Debian installs it's pretty trivial to exceed that. Since the symptom can be a silent hang or a crash add a check. Of course the affected boards would also need an increased CBSIZE to actually work. Note that due to the printing of the final bootargs string CONFIG_SYS_PBSIZE also needs to be sufficiently large. Signed-off-by:
Ian Campbell <ian.campbell@citrix.com> [trini: Use %zd not %d in printf for all args] Signed-off-by:
Tom Rini <trini@ti.com>
-
- Aug 21, 2014
-
-
Hans de Goede authored
Use cli_simple_process_macros, so that environment variables (e.g. ${console}) can be used in append strings. Signed-off-by:
Hans de Goede <hdegoede@redhat.com>
-
- Aug 09, 2014
-
-
Bryan Wu authored
Trying bootm for zImage will print out several error message which is not necessary for this case. So detect image format firstly, only try bootm for legacy and FIT format image then try bootz for others. This patch needs new function genimg_get_kernel_addr(). Signed-off-by:
Bryan Wu <pengw@nvidia.com>
-
Stephen Warren authored
When "pxe boot" downloads the initrd/kernel/DTB, netboot_common() saves the downloaded filename to global variable BootFile. If the boot operation is aborted, this global state is not cleared. If "dhcp" is executed later without any arguments, BootFile is not cleared, and when the DHCP response is received, BootpCopyNetParams() writes the value into environment variable bootfile. This causes the following scenario: * Boot script executes dhcp; pxe get; pxe boot * User CTRL-C's the PXE menu, which causes the first menu item to be booted, which causes some file to be downloaded. (This boot-on-CTRL-C behaviour is arguably a bug too, but it's a separate bug and the bug this patch fixes would still exist if the user simply waited to press CTRL-C until "pxe boot" started downloading files) * User CTRL-C's the file downloads, but the filename is still written to the bootfile environment variable. * User re-runs the boot command, which in my case executes "dhcp; pxe get; pxe boot" again, and "dhcp" picks up the saved bootfile environment variable and proceeds to download a file that it shouldn't. To solve this, modify the implementation of "pxe get" to clear BootFile if the whole boot operation fails, which avoids this whole mess. An alternative would be to modify netboot_common() such that the no- arguments case explicitly clears the global variable BootFile. However, that would prevent the following command sequences from working: $ dhcp filename # downloads "filename" $ dhcp # downloads $bootfile, i.e. "filename" or: $ setenv bootfile filename $ dhcp # downloads $bootfile, i.e. "filename" ... and I assume someone relies on U-Boot working that way. Signed-off-by:
Stephen Warren <swarren@nvidia.com> Acked-by:
Joe Hershberger <joe.hershberger@ni.com>
-
- Jul 18, 2014
-
-
Jeroen Hofstee authored
Since most commands are not public, make them static. This prevents warnings that no common prototype is available. Signed-off-by:
Jeroen Hofstee <jeroen@myspectrum.nl>
-
- Feb 21, 2014
-
-
Stephen Warren authored
The directory name from an fdtdir directive in a PXE config file should always be pre-pended to the DTB filename; it shouldn't matter whether the DTB filename came from the $fdtfile environment variable, or whether it was constructed dynamically from ${soc}-${board}.dtb. Fix the code to always prepend the directory name. Reported-by:
Dennis Gilmore <dennis@ausil.us> Fixes: c61d94d8 ("pxe: implement fdtdir extlinux.conf tag") Signed-off-by:
Stephen Warren <swarren@nvidia.com> Reviewed-by:
Dennis Gilmore <dennis@ausil.us> Tested-by:
Dennis Gilmore <dennis@ausil.us>
-
Stephen Warren authored
pxe.c provides both the "pxe" command which relies on a network, and the "sysboot" command which doesn't. Fix the file to compile when network support isn't enabled. This is useful e.g. on the Raspberry Pi which has no network support yet, but will soon support the sysboot command. Signed-off-by:
Stephen Warren <swarren@wwwdotorg.org>
-
- Feb 04, 2014
-
-
Dennis Gilmore authored
Signed-off-by:
Dennis Gilmore <dennis@ausil.us>
-
Stephen Warren authored
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 filename if 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 <swarren@nvidia.com>
-
Stephen Warren authored
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 <swarren@nvidia.com>
-
- Jan 09, 2014
-
-
David Feng authored
Signed-off-by:
David Feng <fenghua@phytium.com.cn>
-
- Nov 04, 2013
-
-
Rob Herring authored
pxelinux and syslinux differ in their handling of absolute paths in menu files. A pxelinux path is aways prepended with the bootfile path while syslinux allows for absolute paths. u-boot was always treating a leading / as an absolute path breaking some pxelinux setups. Fix this by adding a flag to distinguish pxelinux vs. syslinux behavior. Reported-by:
Ian Campbell <Ian.Campbell@citrix.com> Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
- Oct 14, 2013
-
-
Steven Falco authored
Pass a valid cmdtp into do_tftpb(), do_ext2load(), and do_get_fat(), to avoid possible crashes due to null pointer dereferencing. Commit d7884e04 does not go far enough. There is still at least one call chain that can result in a crash. The do_tftpb(), do_ext2load(), and do_get_fat() functions expect a valid cmdtp. Passing in NULL is particularly bad in the do_tftpb() case, because eventually boot_get_kernel() will be called with a NULL cmdtp: do_tftpb() -> netboot_common() -> bootm_maybe_autostart() -> do_bootm() -> do_bootm_states() -> bootm_find_os() -> boot_get_kernel() Around line 991 in cmd_bootm.c, boot_get_kernel() will dereference the null pointer, and the board will crash. Signed-off-by:
Steven A. Falco <stevenfalco@gmail.com>
-
- Sep 24, 2013
-
-
Tom Rini authored
When we call do_bootm() with a vmlinuz, this would lead to a NULL pointer dereference, and after talking with Wolfgang the right thing to do here for now is to make sure that we pass cmdtp to these functions rather than NULL. Reported-by:
Steven A. Falco <stevenfalco@gmail.com> Signed-off-by:
Tom Rini <trini@ti.com>
-
- Jul 24, 2013
-
-
Wolfgang Denk authored
Signed-off-by:
Wolfgang Denk <wd@denx.de> [trini: Fixup common/cmd_io.c] Signed-off-by:
Tom Rini <trini@ti.com>
-
- Jun 25, 2013
-
-
Rob Herring authored
Add ipappend support to pass network device information to the kernel. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Joe Hershberger authored
Not all boards define an SOC. As a result, we can't depend on that. This was introduced in 39f98553 Signed-off-by:
Joe Hershberger <joe.hershberger@ni.com>
-
Rob Herring authored
A pxelinux server setup for "default" menu is typically an x86 binary. This does not work well with a mixed architecture setup. Extend the default search to look for default-<arch>-<soc> and then default-<arch> before falling back to just "default". Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
ontimeout is similar to default, but is the selection on menu timeout. This is how cobbler sets a default. The label default is supposed to be the default selection when <enter> is pressed. If both default and ontimeout are set, last one parsed wins. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
Menus with lots of entries and long append lines are hard to read. Just show a numbered list using the label or name and make the choice by entering the number. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
The prompt flag is for displaying a "boot:" prompt in pxelinux. This doesn't make sense for u-boot as we don't support the pxelinux command interface. So we should just ignore prompt statements and always show the menu if a menu is present. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
Standard pxelinux servers will typically use a zImage rather than u-boot image format, so fallback to bootz if bootm fails. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
Add support for value of -1 For localboot. A value of -1 means return to u-boot prompt. The localboot value is often 0, so we need to distinguish the value from localboot being selected. A value of greater than or equal to 0 means attempt local boot command. If localboot is selected, we don't want to try other entries. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
Convert a bunch of string parameters to be const. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
Get the MAC address using eth_getenv_enetaddr_by_index so that the MAC address of ethact is used. This enables using the a NIC other than the first one for PXE boot. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
- Mar 29, 2013
-
-
Pali Rohár authored
Selecting menu items is currently done in menu_interactive_choice() by reading the user input strings from standard input. Extend menu_interactive_choice() to support user defined function for selecting menu items. This function and its argument can be specified when creating the menu. Signed-off-by:
Pali Rohár <pali.rohar@gmail.com> Signed-off-by:
Anatolij Gustschin <agust@denx.de>
-
- Sep 27, 2012
-
-
Chander Kashyap authored
Now DT support is becoming common for all new SoC's. Hence it is better to have option for getting specific FDT from the remote server. This patch adds support for new label i.e. 'fdt'. This will allow to retrieve 'fdt blob' from the remote server. This patch take care for the following scenarios. The usage of fdt is optional. The 'fdt blob' can be retrieved from tftp or can be available locally or can be absent. If 'fdt_addr_r' environment variable is set and 'fdt' label is defined retrieve 'fdt blob' from tftp. 'fdt_addr_r' is then passed along bootm command. If 'fdt_addr' is set and 'fdt blob' is not retrieved from the tftp pass 'fdt_addr' to bootm command. In this case 'fdt blob' will be available at 'fdt_addr'. If 'fdt_addr' is not set and 'fdt blob' is not retrieve from tftp pass NULL to boot command. In this case 'fdt blob' is not required and absent. Signed-off-by:
Chander Kashyap <chander.kashyap@linaro.org> Acked-by:
Jason Hobbs <jason.hobbs@calxeda.com>
-
- Aug 09, 2012
-
-
Simon Glass authored
This new function runs a list of commands separated by semicolon or newline. We move this out of cmd_source so that it can be used by other code. The PXE code also uses the new function. Suggested-by:
Michael Walle <michael@walle.cc> Signed-off-by:
Simon Glass <sjg@chromium.org>
-
- Jul 10, 2012
-
-
Wolfgang Denk authored
Signed-off-by:
Wolfgang Denk <wd@denx.de>
-
- Jun 21, 2012
-
-
Rob Herring authored
Add a new command "sysboot" which parses syslinux menu files and boots using kernel and initrd specified by menu files. The operation is similar to "pxe boot" except local files on ext2 or fat filesystem are parsed. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
For syslinux, the initrd can be set in the append string as "initrd=<file>", so try to find it there if we haven't already set the initrd. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-
Rob Herring authored
If the file path starts with a '/', then don't pre-pend the bootfile path. This fixes a problem with running 'pxe boot' multiple times where the bootfile path gets pre-pended to itself each time. Signed-off-by:
Rob Herring <rob.herring@calxeda.com>
-