diff mbox

[U-Boot,V2] arm: novena: Switch novena to config_distro_bootcmd

Message ID 1448408230-23337-1-git-send-email-marex@denx.de
State Awaiting Upstream
Delegated to: Stefano Babic
Headers show

Commit Message

Marek Vasut Nov. 24, 2015, 11:37 p.m. UTC
From: Vagrant Cascadian <vagrant@aikidev.net>

Switch Novena to distro bootcmd, so it can be used with debian easily.

Signed-off-by: Vagrant Cascadian <vagrant@aikidev.net>
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Sean Cross <xobs@kosagi.com>
Cc: Stefano Babic <sbabic@denx.de>
---
 include/configs/novena.h | 23 ++++++++++++++++++++++-
 1 file changed, 22 insertions(+), 1 deletion(-)

V2: Add fdtfile to specify the device tree blob.
    Fix fdt_addr_r to point past kernel address.

Comments

Vagrant Cascadian Nov. 25, 2015, 9:30 p.m. UTC | #1
On 2015-11-24, Marek Vasut wrote:
> From: Vagrant Cascadian <vagrant@aikidev.net>
>
> Switch Novena to distro bootcmd, so it can be used with debian easily.
>
> Signed-off-by: Vagrant Cascadian <vagrant@aikidev.net>
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Sean Cross <xobs@kosagi.com>
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  include/configs/novena.h | 23 ++++++++++++++++++++++-
>  1 file changed, 22 insertions(+), 1 deletion(-)
>
> V2: Add fdtfile to specify the device tree blob.
>     Fix fdt_addr_r to point past kernel address.

Tested-by: Vagrant Cascadian <vagrant@aikidev.net>

> diff --git a/include/configs/novena.h b/include/configs/novena.h
> index 718989f..fc953f6 100644
> --- a/include/configs/novena.h
> +++ b/include/configs/novena.h
> @@ -16,6 +16,7 @@
>  #define CONFIG_FIT
>  #define CONFIG_KEYBOARD
>  
> +#include <config_distro_defaults.h>
>  #include "mx6_common.h"
>  
>  /* U-Boot Commands */
> @@ -58,7 +59,7 @@
>  /* Booting Linux */
>  #define CONFIG_BOOTFILE			"fitImage"
>  #define CONFIG_BOOTARGS			"console=ttymxc1,115200 "
> -#define CONFIG_BOOTCOMMAND		"run net_nfs"
> +#define CONFIG_BOOTCOMMAND		"run distro_bootcmd ; run net_nfs"
>  #define CONFIG_HOSTNAME			novena
>  
>  /* Physical Memory Map */
> @@ -190,6 +191,7 @@
>  #endif
>  
>  /* Extra U-Boot environment. */
> +#ifndef CONFIG_SPL_BUILD
>  #define CONFIG_EXTRA_ENV_SETTINGS					\
>  	"fdt_high=0xffffffff\0"						\
>  	"initrd_high=0xffffffff\0"					\
> @@ -199,6 +201,11 @@
>  	"rootdev=/dev/mmcblk0p2\0"					\
>  	"netdev=eth0\0"							\
>  	"kernel_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
> +	"pxefile_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
> +	"scriptaddr="__stringify(CONFIG_LOADADDR)"\0"			\
> +	"ramdisk_addr_r=0x28000000\0"		   			\
> +	"fdt_addr_r=0x18000000\0"					\
> +	"fdtfile=imx6q-novena.dtb\0"					\
>  	"addcons="							\
>  		"setenv bootargs ${bootargs} "				\
>  		"console=${consdev},${baudrate}\0"			\
> @@ -242,5 +249,19 @@
>  		"fatwrite mmc 0:1 ${loadaddr} u-boot.img ${filesize} ; "\
>  		"fi ; "							\
>  		"fi\0"							\
> +	BOOTENV
> +
> +#define BOOT_TARGET_DEVICES(func) \
> +	func(MMC, mmc, 0) \
> +	func(USB, usb, 0) \
> +	func(SATA, sata, 0) \
> +	func(PXE, pxe, na) \
> +	func(DHCP, dhcp, na)
> +
> +#include <config_distro_bootcmd.h>
> +
> +#else
> +#define CONFIG_EXTRA_ENV_SETTINGS
> +#endif /* CONFIG_SPL_BUILD */
>  
>  #endif				/* __CONFIG_H */
> -- 
> 2.1.4
Vagrant Cascadian Dec. 12, 2015, 11:16 p.m. UTC | #2
On 2015-11-24, Marek Vasut <marex@denx.de> wrote:
> From: Vagrant Cascadian <vagrant@aikidev.net>
>
> Switch Novena to distro bootcmd

Anything remaining on this? Can we hope to see it in 2016.01?


> so it can be used with debian easily.

I suspect other distros would appreciate this too. :)


live well,
  vagrant


> Signed-off-by: Vagrant Cascadian <vagrant@aikidev.net>
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Sean Cross <xobs@kosagi.com>
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  include/configs/novena.h | 23 ++++++++++++++++++++++-
>  1 file changed, 22 insertions(+), 1 deletion(-)
>
> V2: Add fdtfile to specify the device tree blob.
>     Fix fdt_addr_r to point past kernel address.
>
> diff --git a/include/configs/novena.h b/include/configs/novena.h
> index 718989f..fc953f6 100644
> --- a/include/configs/novena.h
> +++ b/include/configs/novena.h
> @@ -16,6 +16,7 @@
>  #define CONFIG_FIT
>  #define CONFIG_KEYBOARD
>  
> +#include <config_distro_defaults.h>
>  #include "mx6_common.h"
>  
>  /* U-Boot Commands */
> @@ -58,7 +59,7 @@
>  /* Booting Linux */
>  #define CONFIG_BOOTFILE			"fitImage"
>  #define CONFIG_BOOTARGS			"console=ttymxc1,115200 "
> -#define CONFIG_BOOTCOMMAND		"run net_nfs"
> +#define CONFIG_BOOTCOMMAND		"run distro_bootcmd ; run net_nfs"
>  #define CONFIG_HOSTNAME			novena
>  
>  /* Physical Memory Map */
> @@ -190,6 +191,7 @@
>  #endif
>  
>  /* Extra U-Boot environment. */
> +#ifndef CONFIG_SPL_BUILD
>  #define CONFIG_EXTRA_ENV_SETTINGS					\
>  	"fdt_high=0xffffffff\0"						\
>  	"initrd_high=0xffffffff\0"					\
> @@ -199,6 +201,11 @@
>  	"rootdev=/dev/mmcblk0p2\0"					\
>  	"netdev=eth0\0"							\
>  	"kernel_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
> +	"pxefile_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
> +	"scriptaddr="__stringify(CONFIG_LOADADDR)"\0"			\
> +	"ramdisk_addr_r=0x28000000\0"		   			\
> +	"fdt_addr_r=0x18000000\0"					\
> +	"fdtfile=imx6q-novena.dtb\0"					\
>  	"addcons="							\
>  		"setenv bootargs ${bootargs} "				\
>  		"console=${consdev},${baudrate}\0"			\
> @@ -242,5 +249,19 @@
>  		"fatwrite mmc 0:1 ${loadaddr} u-boot.img ${filesize} ; "\
>  		"fi ; "							\
>  		"fi\0"							\
> +	BOOTENV
> +
> +#define BOOT_TARGET_DEVICES(func) \
> +	func(MMC, mmc, 0) \
> +	func(USB, usb, 0) \
> +	func(SATA, sata, 0) \
> +	func(PXE, pxe, na) \
> +	func(DHCP, dhcp, na)
> +
> +#include <config_distro_bootcmd.h>
> +
> +#else
> +#define CONFIG_EXTRA_ENV_SETTINGS
> +#endif /* CONFIG_SPL_BUILD */
>  
>  #endif				/* __CONFIG_H */
> -- 
> 2.1.4
Stefano Babic Dec. 14, 2015, 11:24 a.m. UTC | #3
Hi Vagrant,

On 13/12/2015 00:16, Vagrant Cascadian wrote:
> On 2015-11-24, Marek Vasut <marex@denx.de> wrote:
>> From: Vagrant Cascadian <vagrant@aikidev.net>
>>
>> Switch Novena to distro bootcmd
> 
> Anything remaining on this? Can we hope to see it in 2016.01?
> 
> 
>> so it can be used with debian easily.
> 
> I suspect other distros would appreciate this too. :)
> 

It was missed because it was assigned to Albert - I have picked it up.

Applied to u-boot-imx, thanks !

Best regards,
Stefano Babic
Marek Vasut Dec. 22, 2015, 1:19 a.m. UTC | #4
On Monday, December 14, 2015 at 12:24:33 PM, Stefano Babic wrote:
> Hi Vagrant,
> 
> On 13/12/2015 00:16, Vagrant Cascadian wrote:
> > On 2015-11-24, Marek Vasut <marex@denx.de> wrote:
> >> From: Vagrant Cascadian <vagrant@aikidev.net>
> >> 
> >> Switch Novena to distro bootcmd
> > 
> > Anything remaining on this? Can we hope to see it in 2016.01?
> > 
> >> so it can be used with debian easily.
> > 
> > I suspect other distros would appreciate this too. :)
> 
> It was missed because it was assigned to Albert - I have picked it up.
> 
> Applied to u-boot-imx, thanks !

This is still not in u-boot/master :-(

Best regards,
Marek Vasut
Marek Vasut Dec. 29, 2015, 6:50 p.m. UTC | #5
On Tuesday, December 22, 2015 at 02:19:10 AM, Marek Vasut wrote:
> On Monday, December 14, 2015 at 12:24:33 PM, Stefano Babic wrote:
> > Hi Vagrant,
> > 
> > On 13/12/2015 00:16, Vagrant Cascadian wrote:
> > > On 2015-11-24, Marek Vasut <marex@denx.de> wrote:
> > >> From: Vagrant Cascadian <vagrant@aikidev.net>
> > >> 
> > >> Switch Novena to distro bootcmd
> > > 
> > > Anything remaining on this? Can we hope to see it in 2016.01?
> > > 
> > >> so it can be used with debian easily.
> > > 
> > > I suspect other distros would appreciate this too. :)
> > 
> > It was missed because it was assigned to Albert - I have picked it up.
> > 
> > Applied to u-boot-imx, thanks !
> 
> This is still not in u-boot/master :-(

This patch didn't make it into mainline for over a month.
This is actually required so we can use Debian on Novena.

Please apply.

Best regards,
Marek Vasut
diff mbox

Patch

diff --git a/include/configs/novena.h b/include/configs/novena.h
index 718989f..fc953f6 100644
--- a/include/configs/novena.h
+++ b/include/configs/novena.h
@@ -16,6 +16,7 @@ 
 #define CONFIG_FIT
 #define CONFIG_KEYBOARD
 
+#include <config_distro_defaults.h>
 #include "mx6_common.h"
 
 /* U-Boot Commands */
@@ -58,7 +59,7 @@ 
 /* Booting Linux */
 #define CONFIG_BOOTFILE			"fitImage"
 #define CONFIG_BOOTARGS			"console=ttymxc1,115200 "
-#define CONFIG_BOOTCOMMAND		"run net_nfs"
+#define CONFIG_BOOTCOMMAND		"run distro_bootcmd ; run net_nfs"
 #define CONFIG_HOSTNAME			novena
 
 /* Physical Memory Map */
@@ -190,6 +191,7 @@ 
 #endif
 
 /* Extra U-Boot environment. */
+#ifndef CONFIG_SPL_BUILD
 #define CONFIG_EXTRA_ENV_SETTINGS					\
 	"fdt_high=0xffffffff\0"						\
 	"initrd_high=0xffffffff\0"					\
@@ -199,6 +201,11 @@ 
 	"rootdev=/dev/mmcblk0p2\0"					\
 	"netdev=eth0\0"							\
 	"kernel_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
+	"pxefile_addr_r="__stringify(CONFIG_LOADADDR)"\0"		\
+	"scriptaddr="__stringify(CONFIG_LOADADDR)"\0"			\
+	"ramdisk_addr_r=0x28000000\0"		   			\
+	"fdt_addr_r=0x18000000\0"					\
+	"fdtfile=imx6q-novena.dtb\0"					\
 	"addcons="							\
 		"setenv bootargs ${bootargs} "				\
 		"console=${consdev},${baudrate}\0"			\
@@ -242,5 +249,19 @@ 
 		"fatwrite mmc 0:1 ${loadaddr} u-boot.img ${filesize} ; "\
 		"fi ; "							\
 		"fi\0"							\
+	BOOTENV
+
+#define BOOT_TARGET_DEVICES(func) \
+	func(MMC, mmc, 0) \
+	func(USB, usb, 0) \
+	func(SATA, sata, 0) \
+	func(PXE, pxe, na) \
+	func(DHCP, dhcp, na)
+
+#include <config_distro_bootcmd.h>
+
+#else
+#define CONFIG_EXTRA_ENV_SETTINGS
+#endif /* CONFIG_SPL_BUILD */
 
 #endif				/* __CONFIG_H */