summaryrefslogtreecommitdiff
path: root/boot/image-board.c
AgeCommit message (Collapse)Author
2022-09-29treewide: Drop image_header_t typedefSimon Glass
This is not needed and we should avoid typedefs. Use the struct instead and rename it to indicate that it really is a legacy struct. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-29treewide: Drop bootm_headers_t typedefSimon Glass
This is not needed and we should avoid typedefs. Use the struct instead. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-18cyclic: Use schedule() instead of WATCHDOG_RESET()Stefan Roese
Globally replace all occurances of WATCHDOG_RESET() with schedule(), which handles the HW_WATCHDOG functionality and the cyclic infrastructure. Signed-off-by: Stefan Roese <sr@denx.de> Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: Tom Rini <trini@konsulko.com> [am335x_evm, mx6cuboxi, rpi_3,dra7xx_evm, pine64_plus, am65x_evm, j721e_evm]
2022-09-14image: Drop some other #ifdefs in image-board.cSimon Glass
Remove all but a few that are difficult, relying on legacy CONFIG options or optional global_data fields. Drop the duplicate function name in the comment for boot_get_cmdline(). Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Correct indentation in select_ramdisk()Simon Glass
Finish off the refactoring by correcting the indent levels. Note that this does not include any functional changes. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Drop remaining FIT #ifdefSimon Glass
Drop the last one of these, by using a done_select variable to control whether to fall back to using 'select' as a hex value. Note that the indentation is not adjusted, to make this easier to review. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Drop another #ifdef for FITSimon Glass
Drop the prenultimate one of these from select_ramdisk(). Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Drop one #ifdef for FITSimon Glass
Drop the #ifdef from near the end of select_ramdisk(). Move some variables to the top of the function to make this work. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Drop #ifdefs for LEGACY_IMAGE_FORMATSimon Glass
Use if() instead of the #ifdef in select_ramdisk(). Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Track when ramdisk processing is completedSimon Glass
The current switch default is tricky since it relies on #ifdefs to work. Use a bool instead. Also fix the comment on @select, since it has a dual purpose. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-09-14image: Fix up ANDROID_BOOT_IMAGE ramdisk codeSimon Glass
Convert this to an if(), fix the cast from an address to a pointer and make sure that any error is returned correctly. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-08-10common: Drop display_options.h from common headerSimon Glass
Move this out of the common header and include it only where needed. Signed-off-by: Simon Glass <sjg@chromium.org>
2022-07-26fpga: pass compatible flags to fpga_load()Oleksandr Suvorov
These flags may be used to check whether an FPGA driver is able to load a particular FPGA bitstream image. Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@foundries.io> Tested-by: Ricardo Salveti <ricardo@foundries.io> Tested-by: Adrian Fiergolski <adrian.fiergolski@fastree3d.com> Link: https://lore.kernel.org/r/20220722141614.297383-7-oleksandr.suvorov@foundries.io Signed-off-by: Michal Simek <michal.simek@amd.com>
2022-07-26zynqmp: Run board_get_usable_ram_top() only on main U-BootAshok Reddy Soma
With commit ce39ee28ec31 ("zynqmp: Do not place u-boot to reserved memory location"), the function board_get_usable_ram_top() is allocating MMU_SECTION_SIZE of about 2MB using lmb_alloc(). But we dont have this much memory in case of mini U-Boot. Keep these functions which use lmb under CONFIG_LMB so that they are compiled and used only when LMB is enabled. Signed-off-by: Ashok Reddy Soma <ashok.reddy.soma@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Michal Simek <michal.simek@amd.com> Link: https://lore.kernel.org/r/75e52def75f573e554a6b177a78504c128cb0c4a.1657183534.git.michal.simek@amd.com
2022-06-06Convert CONFIG_SYS_BARGSIZE to KconfigTom Rini
This converts the following to Kconfig: CONFIG_SYS_BARGSIZE Signed-off-by: Tom Rini <trini@konsulko.com>
2022-01-19doc: replace @return by Return:Heinrich Schuchardt
Sphinx expects Return: and not @return to indicate a return value. find . -name '*.c' -exec \ sed -i 's/^\(\s\)\*\(\s*\)@return\(\s\)/\1*\2Return:\3/' {} \; find . -name '*.h' -exec \ sed -i 's/^\(\s\)\*\(\s*\)@return\(\s\)/\1*\2Return:\3/' {} \; Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2021-12-20Revert "image: Remove #ifdefs from select_ramdisk()"Tom Rini
This reverts commit f33a2c1bd0fb371511a485cac1f182ba50db51be. This causes a crash on some platforms as seen here: https://lore.kernel.org/r/f153017b-c41a-0d32-67b9-f288e695f900@baylibre.com/ Reported-by: Neil Armstrong <narmstrong@baylibre.com> Signed-off-by: Tom Rini <trini@konsulko.com>
2021-11-15image: Explicitly declare do_bdinfo()Andy Shevchenko
Compiler is not happy: common/image-board.c: In function ‘boot_get_kbd’: common/image-board.c:902:17: warning: implicit declaration of function ‘do_bdinfo’ [-Wimplicit-function-declaration] 902 | do_bdinfo(NULL, 0, 0, NULL); | ^~~~~~~~~ Move the forward declaration to a header. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Simon Glass <sjg@chromium.org>
2021-11-11Create a new boot/ directorySimon Glass
Quite a lot of the code in common/relates to booting and images. Before adding more it seems like a good time to move the code into its own directory. Most files with 'boot' or 'image' in them are moved, except: - autoboot.c which relates to U-Boot automatically running a script - bootstage.c which relates to U-Boot timing Drop the removal of boot* files from the output directory, since this interfers with the symlinks created by tools and there does not appear to be any such file from my brief testing. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Artem Lapkin <email2tema@gmail.com> Tested-by: Artem Lapkin <email2tema@gmail.com>