Re: [PATCH] ARM: OMAP: xload: Fix compile without CONFIG_MTD

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 01, 2022 at 10:14:52AM +0300, Alexander Shiyan wrote:
> arm-linux-ld: arch/arm/mach-omap/xload.o: in function read_mtd_barebox':
> /home/ARM/barebox/arch/arm/mach-omap/xload.c:75: undefined reference to mtd_peb_read_file'
> 
> Signed-off-by: Alexander Shiyan <eagle.alexander923@xxxxxxxxx>
> ---
>  arch/arm/mach-omap/xload.c | 72 ++++++++++++++++++--------------------
>  1 file changed, 34 insertions(+), 38 deletions(-)
> 
>  static __noreturn int omap_xload(void)
>  {
> -	void *func;
> +	void *func = NULL;
>  
>  	if (!barebox_part)
>  		barebox_part = &default_part;
> @@ -310,10 +308,8 @@ static __noreturn int omap_xload(void)
>  		} else if (IS_ENABLED(CONFIG_FS_OMAP4_USBBOOT)) {
>  			printf("booting from USB\n");
>  			func = omap4_xload_boot_usb();
> -		} else {
> +		} else
>  			printf("booting from USB not enabled\n");
> -			func = NULL;
> -		}
>  		break;
>  	case BOOTSOURCE_NAND:
>  		printf("booting from NAND\n");
> @@ -327,16 +323,16 @@ static __noreturn int omap_xload(void)
>  		if (IS_ENABLED(CONFIG_OMAP_SERIALBOOT)) {
>  			printf("booting from serial\n");
>  			func = omap_serial_boot();
> -			break;
>  		}
> +		break;
>  	case BOOTSOURCE_NET:
>  		if (IS_ENABLED(CONFIG_AM33XX_NET_BOOT)) {
>  			printf("booting from NET\n");
>  			func = am33xx_net_boot();
> -			break;
>  		} else {
>  			printf("booting from network not enabled\n");
>  		}
> +		break;


Despite being the first hunk a no-op, these ones look quite useful.
Should we make a separate patch from it?

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux