diff mbox series

[U-Boot] pxe: Try even board specific boot

Message ID 20181017142423.18356-1-michal.hrusecky@nic.cz
State Changes Requested
Delegated to: Tom Rini
Headers show
Series [U-Boot] pxe: Try even board specific boot | expand

Commit Message

Michal Hrusecky Oct. 17, 2018, 2:24 p.m. UTC
From: Michal Hrusecky <michal.hrusecky@nic.cz>

Add path containing board name (if available) to the list of paths tried via
PXE by default. Some SoC families are quite diverse and sometimes it makes
sense to have special image just for a specific boards.

Signed-off-by: Michal Hrusecky <michal.hrusecky@nic.cz>
---
 cmd/pxe.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Tom Rini Nov. 27, 2018, 3:51 a.m. UTC | #1
On Wed, Oct 17, 2018 at 04:24:23PM +0200, michal.hrusecky@nic.cz wrote:

> From: Michal Hrusecky <michal.hrusecky@nic.cz>
> 
> Add path containing board name (if available) to the list of paths tried via
> PXE by default. Some SoC families are quite diverse and sometimes it makes
> sense to have special image just for a specific boards.
> 
> Signed-off-by: Michal Hrusecky <michal.hrusecky@nic.cz>
> ---
>  cmd/pxe.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/cmd/pxe.c b/cmd/pxe.c
> index 274555319b..0742b3b4f9 100644
> --- a/cmd/pxe.c
> +++ b/cmd/pxe.c
> @@ -21,6 +21,9 @@
>  #define MAX_TFTP_PATH_LEN 127
>  
>  const char *pxe_default_paths[] = {
> +#ifdef CONFIG_SYS_BOARD
> +	"default-" CONFIG_SYS_ARCH "-" CONFIG_SYS_SOC "-" CONFIG_SYS_BOARD,
> +#endif
>  #ifdef CONFIG_SYS_SOC
>  	"default-" CONFIG_SYS_ARCH "-" CONFIG_SYS_SOC,
>  #endif

This fails to build in a number of combinations, but the first example
is just sandbox_defconfig, please fix, thanks!
diff mbox series

Patch

diff --git a/cmd/pxe.c b/cmd/pxe.c
index 274555319b..0742b3b4f9 100644
--- a/cmd/pxe.c
+++ b/cmd/pxe.c
@@ -21,6 +21,9 @@ 
 #define MAX_TFTP_PATH_LEN 127
 
 const char *pxe_default_paths[] = {
+#ifdef CONFIG_SYS_BOARD
+	"default-" CONFIG_SYS_ARCH "-" CONFIG_SYS_SOC "-" CONFIG_SYS_BOARD,
+#endif
 #ifdef CONFIG_SYS_SOC
 	"default-" CONFIG_SYS_ARCH "-" CONFIG_SYS_SOC,
 #endif