spl: Use a single underscore in the SPL_LOAD_IMAGE_METHOD() macro
Subsystems (5)
PATCH v2 1/8 spl: Use a single underscore in the SPL_LOAD_IMAGE_METHOD() macro
A double underscore is normally reserved for compiler predefines. Use a single underscore instead.
---
Changes in v2: None
include/spl.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)
include/spl.h +7 -7
@@ -172,15 +172,15 @@ struct spl_image_loader { ll_entry_declare(struct spl_image_loader, __name, spl_image_loader)/* -* __priority is the priority of this method, 0 meaning it will be the top +* _priority is the priority of this method, 0 meaning it will be the top * choice for this device, 9 meaning it is the bottom choice. -* __boot_device is the BOOT_DEVICE_... value -* __method is the load_image function to call +* _boot_device is the BOOT_DEVICE_... value +* _method is the load_image function to call */ -#define SPL_LOAD_IMAGE_METHOD (__priority, __boot_device, __method) \ - SPL_LOAD_IMAGE(__method ## __priority ## __boot_device) = { \ - .boot_device = __boot_device, \ - .load_image = __method, \ +#define SPL_LOAD_IMAGE_METHOD (_priority, _boot_device, _method) \ + SPL_LOAD_IMAGE(_method ## _priority ## _boot_device) = { \ + .boot_device = _boot_device, \ + .load_image = _method, \ }/* SPL FAT image functions */
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 2/8 spl: Add a name to the SPL load-image methods
It is useful to name each method so that we can print out this name when using the method. Currently this happens using a separate function. In preparation for unifying this, add a name to each method.
The name is only available if we have libcommon support (i.e can use printf()).
---
Changes in v2: None
arch/arm/mach-sunxi/board.c | 2 +- arch/arm/mach-uniphier/boot-mode/spl_board.c | 2 +- arch/sandbox/cpu/spl.c | 2 +- common/spl/spl.c | 4 ++-- common/spl/spl_mmc.c | 6 +++--- common/spl/spl_nand.c | 2 +- common/spl/spl_net.c | 5 +++-- common/spl/spl_nor.c | 2 +- common/spl/spl_onenand.c | 3 ++- common/spl/spl_sata.c | 2 +- common/spl/spl_spi.c | 2 +- common/spl/spl_ubi.c | 4 ++-- common/spl/spl_usb.c | 2 +- common/spl/spl_ymodem.c | 2 +- drivers/mtd/spi/sunxi_spi_spl.c | 2 +- include/spl.h | 15 ++++++++++++++- 16 files changed, 36 insertions(+), 21 deletions(-)
arch/arm/mach-sunxi/board.c +1 -1
@@ -142,7 +142,7 @@ static int spl_board_load_image(struct spl_image_info *spl_image, return 0; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_BOARD , spl_board_load_image); +SPL_LOAD_IMAGE_METHOD ("FEL" ,0 ,BOOT_DEVICE_BOARD , spl_board_load_image);#endif void s_init (void )
arch/arm/mach-uniphier/boot-mode/spl_board.c +1 -1
@@ -127,4 +127,4 @@ static int spl_board_load_image(struct spl_image_info *spl_image,return 0 ; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_BOARD , spl_board_load_image); +SPL_LOAD_IMAGE_METHOD ("eMMC" ,0 ,BOOT_DEVICE_BOARD , spl_board_load_image);
arch/sandbox/cpu/spl.c +1 -1
@@ -51,7 +51,7 @@ static int spl_board_load_image(struct spl_image_info *spl_image,/* Hopefully this will not return */ return os_spl_to_uboot (fname); } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_BOARD , spl_board_load_image); +SPL_LOAD_IMAGE_METHOD ("sandbox" ,0 ,BOOT_DEVICE_BOARD , spl_board_load_image);void spl_board_init (void ) {
common/spl/spl.c +2 -2
@@ -221,10 +221,10 @@ static int spl_ram_load_image(struct spl_image_info *spl_image, return 0; }#if defined(CONFIG_SPL_RAM_DEVICE ) -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_RAM , spl_ram_load_image); +SPL_LOAD_IMAGE_METHOD ("RAM" ,0 ,BOOT_DEVICE_RAM , spl_ram_load_image);#endif #if defined(CONFIG_SPL_DFU_SUPPORT ) -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_DFU , spl_ram_load_image); +SPL_LOAD_IMAGE_METHOD ("USB DFU" ,0 ,BOOT_DEVICE_DFU , spl_ram_load_image);#endif #endif
common/spl/spl_mmc.c +3 -3
@@ -352,6 +352,6 @@ static int spl_mmc_load_image(struct spl_image_info *spl_image,return err; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_MMC1 , spl_mmc_load_image); -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_MMC2 , spl_mmc_load_image); -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_MMC2_2 , spl_mmc_load_image); +SPL_LOAD_IMAGE_METHOD ("MMC1" ,0 ,BOOT_DEVICE_MMC1 , spl_mmc_load_image); +SPL_LOAD_IMAGE_METHOD ("MMC2" ,0 ,BOOT_DEVICE_MMC2 , spl_mmc_load_image); +SPL_LOAD_IMAGE_METHOD ("MMC2_2" ,0 ,BOOT_DEVICE_MMC2_2 , spl_mmc_load_image);
common/spl/spl_nand.c +1 -1
@@ -151,4 +151,4 @@ static int spl_nand_load_image(struct spl_image_info *spl_image, }#endif /* Use priorty 1 so that Ubi can override this */ -SPL_LOAD_IMAGE_METHOD (1 ,BOOT_DEVICE_NAND , spl_nand_load_image); +SPL_LOAD_IMAGE_METHOD ("NAND" ,1 ,BOOT_DEVICE_NAND , spl_nand_load_image);
common/spl/spl_net.c +3 -2
@@ -51,7 +51,8 @@ int spl_net_load_image_cpgmac(struct spl_image_info *spl_image, return spl_net_load_image(spl_image, bootdev); } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_CPGMAC , spl_net_load_image_cpgmac); +SPL_LOAD_IMAGE_METHOD ("eth device" ,0 ,BOOT_DEVICE_CPGMAC , + spl_net_load_image_cpgmac);#endif #ifdef CONFIG_SPL_USBETH_SUPPORT
@@ -62,5 +63,5 @@ int spl_net_load_image_usb(struct spl_image_info *spl_image, return spl_net_load_image(spl_image, bootdev); } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_USBETH , spl_net_load_image_usb); +SPL_LOAD_IMAGE_METHOD ("USB eth" ,0 ,BOOT_DEVICE_USBETH , spl_net_load_image_usb);#endif
common/spl/spl_nor.c +1 -1
@@ -71,4 +71,4 @@ static int spl_nor_load_image(struct spl_image_info *spl_image,return 0 ; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_NOR , spl_nor_load_image); +SPL_LOAD_IMAGE_METHOD ("NOR" ,0 ,BOOT_DEVICE_NOR , spl_nor_load_image);
common/spl/spl_onenand.c +2 -1
@@ -36,4 +36,5 @@ static int spl_onenand_load_image(struct spl_image_info *spl_image,return 0 ; }/* Use priorty 1 so that Ubi can override this */ -SPL_LOAD_IMAGE_METHOD (1 ,BOOT_DEVICE_ONENAND , spl_onenand_load_image); +SPL_LOAD_IMAGE_METHOD ("OneNAND" ,1 ,BOOT_DEVICE_ONENAND , + spl_onenand_load_image);
common/spl/spl_sata.c +1 -1
@@ -57,4 +57,4 @@ static int spl_sata_load_image(struct spl_image_info *spl_image,return 0 ; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_SATA , spl_sata_load_image); +SPL_LOAD_IMAGE_METHOD ("SATA" ,0 ,BOOT_DEVICE_SATA , spl_sata_load_image);
common/spl/spl_spi.c +1 -1
@@ -125,4 +125,4 @@ static int spl_spi_load_image(struct spl_image_info *spl_image,return err; }/* Use priorty 1 so that boards can override this */ -SPL_LOAD_IMAGE_METHOD (1 ,BOOT_DEVICE_SPI , spl_spi_load_image); +SPL_LOAD_IMAGE_METHOD ("SPI" ,1 ,BOOT_DEVICE_SPI , spl_spi_load_image);
common/spl/spl_ubi.c +2 -2
@@ -78,5 +78,5 @@ out:return ret; }/* Use priorty 0 so that Ubi will override NAND and ONENAND methods */ -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_NAND , spl_ubi_load_image); -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_ONENAND , spl_ubi_load_image); +SPL_LOAD_IMAGE_METHOD ("NAND" ,0 ,BOOT_DEVICE_NAND , spl_ubi_load_image); +SPL_LOAD_IMAGE_METHOD ("OneNAND" ,0 ,BOOT_DEVICE_ONENAND , spl_ubi_load_image);
common/spl/spl_usb.c +1 -1
@@ -65,4 +65,4 @@ static int spl_usb_load_image(struct spl_image_info *spl_image,return 0 ; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_USB , spl_usb_load_image); +SPL_LOAD_IMAGE_METHOD ("USB" ,0 ,BOOT_DEVICE_USB , spl_usb_load_image);
common/spl/spl_ymodem.c +1 -1
@@ -132,4 +132,4 @@ end_stream:printf ("Loaded %d bytes\n" , size);return 0 ; } -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_UART , spl_ymodem_load_image); +SPL_LOAD_IMAGE_METHOD ("UART" ,0 ,BOOT_DEVICE_UART , spl_ymodem_load_image);
drivers/mtd/spi/sunxi_spi_spl.c +1 -1
@@ -284,4 +284,4 @@ static int spl_spi_load_image(struct spl_image_info *spl_image,return 0 ; }/* Use priorty 0 to override the default if it happens to be linked in */ -SPL_LOAD_IMAGE_METHOD (0 ,BOOT_DEVICE_SPI , spl_spi_load_image); +SPL_LOAD_IMAGE_METHOD("sunxi SPI" 0, BOOT_DEVICE_SPI, spl_spi_load_image);
include/spl.h +14 -1
@@ -152,10 +152,14 @@ struct spl_boot_device {/** * Holds information about a way of loading an SPL image * +* @name: User-friendly name for this method (e.g. "MMC") * @boot_device: Boot device that this loader supports * @load_image: Function to call to load image */ struct spl_image_loader { +#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT +const char *name; +#endif uint boot_device;/** * load_image() - Load an SPL image
@@ -177,11 +181,20 @@ struct spl_image_loader {* _boot_device is the BOOT_DEVICE_... value * _method is the load_image function to call */ -#define SPL_LOAD_IMAGE_METHOD (_priority, _boot_device, _method) \ +#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT +#define SPL_LOAD_IMAGE_METHOD (_name, _priority, _boot_device, _method) \ SPL_LOAD_IMAGE(_method ## _priority ## _boot_device) = { \ + .name = _name, \ .boot_device = _boot_device, \ .load_image = _method, \ } +#else +#define SPL_LOAD_IMAGE_METHOD (_name, _priority, _boot_device, _method) \ + SPL_LOAD_IMAGE(_method ## _priority ## _boot_device) = { \ + .boot_device = _boot_device, \ + .load_image = _method, \ + } +#endif /* SPL FAT image functions */ int spl_load_image_fat(struct spl_image_info *spl_image,
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 2/8 spl: Add a name to the SPL load-image methods
Quoted 8 lines · Simon Glass
It is useful to name each method so that we can print out this name when using the method. Currently this happens using a separate function. In preparation for unifying this, add a name to each method.
The name is only available if we have libcommon support (i.e can use
printf()).Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/dc407e8d/attachment.sig>
PATCH v2 3/8 spl: Move the loading code into its own function
In reply to Simon GlassCreate a boot_from_devices() function to handle trying each device. This helps to reduce the size of the already-large board_init_r() function.
---
Changes in v2:
- Drop incorrect use of ARRAY_SIZE in boot_from_devices()
- Add a function comment to boot_from_devices()
common/spl/spl.c | 41 +++++++++++++++++++++++++++++------------ 1 file changed, 29 insertions(+), 12 deletions(-)
common/spl/spl.c +29 -12
@@ -374,12 +374,36 @@ static int spl_load_image(struct spl_image_info *spl_image, u32 boot_device) bootdev.boot_device = boot_device; bootdev.boot_device_name =NULL ; -if (loader) -return loader->load_image (spl_image, &bootdev); +return loader->load_image (spl_image, &bootdev); +} + +/** +* boot_from_devices() - Try loading an booting U-Boot from a list of devices +* +* @spl_image: Place to put the image details if successful +* @spl_boot_list: List of boot devices to try +* @count: Number of elements in spl_boot_list +* @return 0 if OK, -ve on error +*/ +static int boot_from_devices (struct spl_image_info *spl_image, +u32 spl_boot_list[],int count) +{ +int i; + +for (i =0 ; i < count && spl_boot_list[i] !=BOOT_DEVICE_NONE ; i++) { +struct spl_image_loader *loader; + +announce_boot_device (spl_boot_list[i]); + loader =spl_ll_find_loader (spl_boot_list[i]);#if defined(CONFIG_SPL_SERIAL_SUPPORT ) && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) -puts ("SPL: Unsupported Boot Device!\n" ); +if (!loader) +puts ("SPL: Unsupported Boot Device!\n" );#endif +if (loader && !spl_load_image (spl_image, spl_boot_list[i])) +return 0 ; + } +return -ENODEV ; }
@@ -393,7 +417,6 @@ void board_init_r(gd_t *dummy1, ulong dummy2) BOOT_DEVICE_NONE, };struct spl_image_info spl_image; -int i;debug (">>spl:board_init_r()\n" );
@@ -420,15 +443,9 @@ void board_init_r(gd_t *dummy1, ulong dummy2)memset (&spl_image,'\0' ,sizeof (spl_image));board_boot_order (spl_boot_list); -for (i =0 ; i <ARRAY_SIZE (spl_boot_list) && - spl_boot_list[i] !=BOOT_DEVICE_NONE ; i++) { -announce_boot_device (spl_boot_list[i]); -if (!spl_load_image (&spl_image, spl_boot_list[i])) -break ; - } -if (i ==ARRAY_SIZE (spl_boot_list) || - spl_boot_list[i] ==BOOT_DEVICE_NONE ) { +if (boot_from_devices (&spl_image, spl_boot_list, +ARRAY_SIZE (spl_boot_list))) {puts ("SPL: failed to boot from all boot devices\n" );hang (); }
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 3/8 spl: Move the loading code into its own function
Quoted 4 lines · Simon Glass
Create a
boot_from_devices()function to handle trying each device. This helps to reduce the size of the already-largeboard_init_r()function.Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/733d9285/attachment.sig>
PATCH v2 4/8 spl: Pass the loader into spl_load_image()
In reply to Simon GlassRather than have this function figure out the correct loader again, pass it in as a parameter.
---
Changes in v2: None
common/spl/spl.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
common/spl/spl.c +4 -4
@@ -367,12 +367,12 @@ static struct spl_image_loader *spl_ll_find_loader(uint boot_device)return NULL ; } -static int spl_load_image (struct spl_image_info *spl_image,u32 boot_device) +static int spl_load_image (struct spl_image_info *spl_image, +struct spl_image_loader *loader) {struct spl_boot_device bootdev; -struct spl_image_loader *loader =spl_ll_find_loader (boot_device); - bootdev.boot_device = boot_device; + bootdev.boot_device = loader->boot_device; bootdev.boot_device_name =NULL ;return loader->load_image (spl_image, &bootdev);
@@ -400,7 +400,7 @@ static int boot_from_devices(struct spl_image_info *spl_image,if (!loader)puts ("SPL: Unsupported Boot Device!\n" );#endif -if (loader && !spl_load_image (spl_image, spl_boot_list[i])) +if (loader && !spl_load_image (spl_image, loader))return 0 ; }
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 4/8 spl: Pass the loader into spl_load_image()
Quoted 4 lines · Simon Glass
Rather than have this function figure out the correct loader again, pass it in as a parameter.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/5182b91d/attachment.sig>
PATCH v2 5/8 spl: Drop announce_boot_device()
In reply to Simon GlassThis task can be handled by inline code now. Drop this function.
---
Changes in v2: None
common/spl/spl.c | 86 ++------------------------------------------------------ 1 file changed, 3 insertions(+), 83 deletions(-)
common/spl/spl.c +3 -83
@@ -269,87 +269,6 @@ __weak void board_boot_order(u32 *spl_boot_list) spl_boot_list[0 ] =spl_boot_device (); } -#ifdef CONFIG_SPL_BOARD_LOAD_IMAGE -__weak void spl_board_announce_boot_device (void ) { } -#endif - -#ifdef CONFIG_SPL_LIBCOMMON_SUPPORT -struct boot_device_name { - u32 boot_dev; - const char *name; -}; - -struct boot_device_name boot_name_table[] = { -#ifdef CONFIG_SPL_RAM_DEVICE - { BOOT_DEVICE_RAM, "RAM" }, -#endif -#ifdef CONFIG_SPL_MMC_SUPPORT - { BOOT_DEVICE_MMC1, "MMC1" }, - { BOOT_DEVICE_MMC2, "MMC2" }, - { BOOT_DEVICE_MMC2_2, "MMC2_2" }, -#endif -#ifdef CONFIG_SPL_NAND_SUPPORT - { BOOT_DEVICE_NAND, "NAND" }, -#endif -#ifdef CONFIG_SPL_ONENAND_SUPPORT - { BOOT_DEVICE_ONENAND, "OneNAND" }, -#endif -#ifdef CONFIG_SPL_NOR_SUPPORT - { BOOT_DEVICE_NOR, "NOR" }, -#endif -#ifdef CONFIG_SPL_YMODEM_SUPPORT - { BOOT_DEVICE_UART, "UART" }, -#endif -#if defined(CONFIG_SPL_SPI_SUPPORT) || defined(CONFIG_SPL_SPI_FLASH_SUPPORT) - { BOOT_DEVICE_SPI, "SPI" }, -#endif -#ifdef CONFIG_SPL_ETH_SUPPORT -#ifdef CONFIG_SPL_ETH_DEVICE - { BOOT_DEVICE_CPGMAC, "eth device" }, -#else - { BOOT_DEVICE_CPGMAC, "net" }, -#endif -#endif -#ifdef CONFIG_SPL_USBETH_SUPPORT - { BOOT_DEVICE_USBETH, "USB eth" }, -#endif -#ifdef CONFIG_SPL_USB_SUPPORT - { BOOT_DEVICE_USB, "USB" }, -#endif -#ifdef CONFIG_SPL_DFU_SUPPORT - { BOOT_DEVICE_DFU, "USB DFU" }, -#endif -#ifdef CONFIG_SPL_SATA_SUPPORT - { BOOT_DEVICE_SATA, "SATA" }, -#endif - /* Keep this entry last */ - { BOOT_DEVICE_NONE, "unknown boot device" }, -}; - -static void announce_boot_device(u32 boot_device) -{ - int i; - - puts("Trying to boot from "); - -#ifdef CONFIG_SPL_BOARD_LOAD_IMAGE - if (boot_device == BOOT_DEVICE_BOARD) { - spl_board_announce_boot_device(); - puts("\n"); - return; - } -#endif - for (i = 0; i < ARRAY_SIZE(boot_name_table) - 1; i++) { - if (boot_name_table[i].boot_dev == boot_device) - break; - } - - printf("%s\n", boot_name_table[i].name); -} -#else -static inline void announce_boot_device(u32 boot_device) { } -#endif -static struct spl_image_loader *spl_ll_find_loader (uint boot_device) { struct spl_image_loader *drv =
@@ -394,10 +313,11 @@ static int boot_from_devices(struct spl_image_info *spl_image,for (i =0 ; i < count && spl_boot_list[i] !=BOOT_DEVICE_NONE ; i++) {struct spl_image_loader *loader; -announce_boot_device (spl_boot_list[i]); loader =spl_ll_find_loader (spl_boot_list[i]);#if defined(CONFIG_SPL_SERIAL_SUPPORT ) && defined(CONFIG_SPL_LIBCOMMON_SUPPORT ) -if (!loader) +if (loader) +printf ("Trying to boot from %s" , loader->name); +else puts ("SPL: Unsupported Boot Device!\n" );#endif if (loader && !spl_load_image (spl_image, loader))
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 5/8 spl: Drop announce_boot_device()
Quoted 3 lines · Simon Glass
This task can be handled by inline code now. Drop this function.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/c034e311/attachment.sig>
PATCH v2 6/8 spl: sunxi: Drop spl_board_announce_boot_device()
In reply to Simon GlassThis function is not used anymore. Drop it.
---
Changes in v2: None
arch/arm/mach-sunxi/board.c | 9 --------- 1 file changed, 9 deletions(-)
arch/arm/mach-sunxi/board.c +0 -9
@@ -247,15 +247,6 @@ u32 spl_boot_device(void)return -1 ;/* Never reached */ } -/* -* Properly announce BOOT_DEVICE_BOARD as "FEL". -* Overrides weak function from common/spl/spl.c -*/ -void spl_board_announce_boot_device (void ) -{ -printf ("FEL" ); -} -/* No confirmation data available in SPL yet. Hardcode bootmode */ u32 spl_boot_mode (const u32 boot_device) {
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 6/8 spl: sunxi: Drop spl_board_announce_boot_device()
Quoted 3 lines · Simon Glass
This function is not used anymore. Drop it.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/9edc3014/attachment.sig>
PATCH v2 7/8 spl: uniphier: Drop spl_board_announce_boot_device()
In reply to Simon GlassThis function is not used anymore. Drop it.
---
Changes in v2: None
arch/arm/mach-uniphier/boot-mode/spl_board.c | 5 ----- 1 file changed, 5 deletions(-)
arch/arm/mach-uniphier/boot-mode/spl_board.c +0 -5
@@ -12,11 +12,6 @@#include "../soc-info.h" -void spl_board_announce_boot_device (void ) -{ -printf ("eMMC" ); -} -struct uniphier_romfunc_table {void *mmc_send_cmd;void *mmc_card_blockaddr;
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 7/8 spl: uniphier: Drop spl_board_announce_boot_device()
Quoted 3 lines · Simon Glass
This function is not used anymore. Drop it.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/b6beb717/attachment.sig>
PATCH v2 8/8 spl: sandbox: Drop spl_board_announce_boot_device()
In reply to Simon GlassThis function is not used anymore. Drop it.
---
Changes in v2: None
arch/sandbox/cpu/spl.c | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-)
arch/sandbox/cpu/spl.c +3 -14
@@ -25,19 +25,6 @@ u32 spl_boot_device(void)return BOOT_DEVICE_BOARD ; } -void spl_board_announce_boot_device (void ) -{ -char fname[256 ]; -int ret; - - ret =os_find_u_boot (fname,sizeof (fname)); -if (ret) { -printf ("(%s not found, error %d)\n" , fname, ret); -return ; - } -printf ("%s\n" , fname); -} -static int spl_board_load_image (struct spl_image_info *spl_image,struct spl_boot_device *bootdev) {
@@ -45,8 +32,10 @@ static int spl_board_load_image(struct spl_image_info *spl_image,int ret; ret =os_find_u_boot (fname,sizeof (fname)); -if (ret) +if (ret) { +printf ("(%s not found, error %d)\n" , fname, ret);return ret; + }/* Hopefully this will not return */ return os_spl_to_uboot (fname);
Signature · 1 line
2.8.0.rc3.226.g39d4020
PATCH v2 8/8 spl: sandbox: Drop spl_board_announce_boot_device()
Quoted 3 lines · Simon Glass
This function is not used anymore. Drop it.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/db7fd402/attachment.sig>
PATCH v2 1/8 spl: Use a single underscore in the SPL_LOAD_IMAGE_METHOD() macro
In reply to Simon GlassQuoted 4 lines · Simon Glass
A double underscore is normally reserved for compiler predefines. Use a single underscore instead.
Signed-off-by Simon Glass <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20161212/db0e02ff/attachment.sig>