public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
@ 2015-11-27  2:36 Chin Liang See
  2015-11-27  3:18 ` Stefan Roese
  2015-11-27 10:36 ` Marek Vasut
  0 siblings, 2 replies; 10+ messages in thread
From: Chin Liang See @ 2015-11-27  2:36 UTC (permalink / raw)
  To: u-boot

Adding new environment usbload which will load zImage and
Linux DTB from USB mass storage through FAT file system.

Signed-off-by: Chin Liang See <clsee@altera.com>
Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
Cc: Dinh Nguyen <dinh.linux@gmail.com>
Cc: Pavel Machek <pavel@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Stefan Roese <sr@denx.de>
---
Changes for v2
- Using load command instead of fatload
---
 include/configs/socfpga_arria5_socdk.h   | 5 ++++-
 include/configs/socfpga_cyclone5_socdk.h | 5 ++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/include/configs/socfpga_arria5_socdk.h b/include/configs/socfpga_arria5_socdk.h
index 9337a58..1d335c4 100644
--- a/include/configs/socfpga_arria5_socdk.h
+++ b/include/configs/socfpga_arria5_socdk.h
@@ -99,7 +99,10 @@
 		"sf read ${fdt_addr} ${qspifdtaddr} ${fdtimagesize};\0" \
 	"qspiboot=setenv bootargs " CONFIG_BOOTARGS \
 		" root=${qspiroot} rw rootfstype=${qspirootfstype};"\
-		"bootm ${loadaddr} - ${fdt_addr}\0"
+		"bootm ${loadaddr} - ${fdt_addr}\0" \
+	"usbload=usb reset;" \
+		"load usb 0 ${loadaddr} ${bootimage};" \
+		"load usb 0 ${fdt_addr} ${fdtimage}\0"
 
 /* The rest of the configuration is shared */
 #include <configs/socfpga_common.h>
diff --git a/include/configs/socfpga_cyclone5_socdk.h b/include/configs/socfpga_cyclone5_socdk.h
index 3b2cfb0..d045127 100644
--- a/include/configs/socfpga_cyclone5_socdk.h
+++ b/include/configs/socfpga_cyclone5_socdk.h
@@ -99,7 +99,10 @@
 		"sf read ${fdt_addr} ${qspifdtaddr} ${fdtimagesize};\0" \
 	"qspiboot=setenv bootargs " CONFIG_BOOTARGS \
 		" root=${qspiroot} rw rootfstype=${qspirootfstype};"\
-		"bootm ${loadaddr} - ${fdt_addr}\0"
+		"bootm ${loadaddr} - ${fdt_addr}\0" \
+	"usbload=usb reset;" \
+		"load usb 0 ${loadaddr} ${bootimage};" \
+		"load usb 0 ${fdt_addr} ${fdtimage}\0"
 
 /* The rest of the configuration is shared */
 #include <configs/socfpga_common.h>
-- 
2.2.0

^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27  2:36 [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB Chin Liang See
@ 2015-11-27  3:18 ` Stefan Roese
  2015-11-27 10:36 ` Marek Vasut
  1 sibling, 0 replies; 10+ messages in thread
From: Stefan Roese @ 2015-11-27  3:18 UTC (permalink / raw)
  To: u-boot

On 27.11.2015 03:36, Chin Liang See wrote:
> Adding new environment usbload which will load zImage and
> Linux DTB from USB mass storage through FAT file system.
>
> Signed-off-by: Chin Liang See <clsee@altera.com>
> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> Cc: Dinh Nguyen <dinh.linux@gmail.com>
> Cc: Pavel Machek <pavel@denx.de>
> Cc: Marek Vasut <marex@denx.de>
> Cc: Stefan Roese <sr@denx.de>
> ---
> Changes for v2
> - Using load command instead of fatload
> ---
>   include/configs/socfpga_arria5_socdk.h   | 5 ++++-
>   include/configs/socfpga_cyclone5_socdk.h | 5 ++++-
>   2 files changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/include/configs/socfpga_arria5_socdk.h b/include/configs/socfpga_arria5_socdk.h
> index 9337a58..1d335c4 100644
> --- a/include/configs/socfpga_arria5_socdk.h
> +++ b/include/configs/socfpga_arria5_socdk.h
> @@ -99,7 +99,10 @@
>   		"sf read ${fdt_addr} ${qspifdtaddr} ${fdtimagesize};\0" \
>   	"qspiboot=setenv bootargs " CONFIG_BOOTARGS \
>   		" root=${qspiroot} rw rootfstype=${qspirootfstype};"\
> -		"bootm ${loadaddr} - ${fdt_addr}\0"
> +		"bootm ${loadaddr} - ${fdt_addr}\0" \
> +	"usbload=usb reset;" \
> +		"load usb 0 ${loadaddr} ${bootimage};" \
> +		"load usb 0 ${fdt_addr} ${fdtimage}\0"
>
>   /* The rest of the configuration is shared */
>   #include <configs/socfpga_common.h>
> diff --git a/include/configs/socfpga_cyclone5_socdk.h b/include/configs/socfpga_cyclone5_socdk.h
> index 3b2cfb0..d045127 100644
> --- a/include/configs/socfpga_cyclone5_socdk.h
> +++ b/include/configs/socfpga_cyclone5_socdk.h
> @@ -99,7 +99,10 @@
>   		"sf read ${fdt_addr} ${qspifdtaddr} ${fdtimagesize};\0" \
>   	"qspiboot=setenv bootargs " CONFIG_BOOTARGS \
>   		" root=${qspiroot} rw rootfstype=${qspirootfstype};"\
> -		"bootm ${loadaddr} - ${fdt_addr}\0"
> +		"bootm ${loadaddr} - ${fdt_addr}\0" \
> +	"usbload=usb reset;" \
> +		"load usb 0 ${loadaddr} ${bootimage};" \
> +		"load usb 0 ${fdt_addr} ${fdtimage}\0"
>
>   /* The rest of the configuration is shared */
>   #include <configs/socfpga_common.h>

Reviewed-by: Stefan Roese <sr@denx.de>

Thanks,
Stefan

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27  2:36 [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB Chin Liang See
  2015-11-27  3:18 ` Stefan Roese
@ 2015-11-27 10:36 ` Marek Vasut
  2015-11-27 12:23   ` Chin Liang See
  1 sibling, 1 reply; 10+ messages in thread
From: Marek Vasut @ 2015-11-27 10:36 UTC (permalink / raw)
  To: u-boot

On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See wrote:
> Adding new environment usbload which will load zImage and
> Linux DTB from USB mass storage through FAT file system.
> 
> Signed-off-by: Chin Liang See <clsee@altera.com>
> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> Cc: Dinh Nguyen <dinh.linux@gmail.com>
> Cc: Pavel Machek <pavel@denx.de>
> Cc: Marek Vasut <marex@denx.de>
> Cc: Stefan Roese <sr@denx.de>
> ---
> Changes for v2
> - Using load command instead of fatload

The distro_bootcmd can do this and even let's you boot debian/fedora on such
a machine in a standardized way. Should we switch to distro_bootcmd instead
of adding new ad-hoc stuff ?

Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27 10:36 ` Marek Vasut
@ 2015-11-27 12:23   ` Chin Liang See
  2015-11-27 12:29     ` Marek Vasut
  0 siblings, 1 reply; 10+ messages in thread
From: Chin Liang See @ 2015-11-27 12:23 UTC (permalink / raw)
  To: u-boot

On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See wrote:
> > Adding new environment usbload which will load zImage and
> > Linux DTB from USB mass storage through FAT file system.
> > 
> > Signed-off-by: Chin Liang See <clsee@altera.com>
> > Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> > Cc: Dinh Nguyen <dinh.linux@gmail.com>
> > Cc: Pavel Machek <pavel@denx.de>
> > Cc: Marek Vasut <marex@denx.de>
> > Cc: Stefan Roese <sr@denx.de>
> > ---
> > Changes for v2
> > - Using load command instead of fatload
> 
> The distro_bootcmd can do this and even let's you boot debian/fedora
> on such
> a machine in a standardized way. Should we switch to distro_bootcmd
> instead
> of adding new ad-hoc stuff ?

It seems to me that we need to add script into the fs to get that work,
right? 

Thanks
Chin Liang

> 
> Best regards,
> Marek Vasut

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27 12:23   ` Chin Liang See
@ 2015-11-27 12:29     ` Marek Vasut
  2015-11-27 16:57       ` Vagrant Cascadian
  0 siblings, 1 reply; 10+ messages in thread
From: Marek Vasut @ 2015-11-27 12:29 UTC (permalink / raw)
  To: u-boot

On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See wrote:
> On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See wrote:
> > > Adding new environment usbload which will load zImage and
> > > Linux DTB from USB mass storage through FAT file system.
> > > 
> > > Signed-off-by: Chin Liang See <clsee@altera.com>
> > > Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> > > Cc: Dinh Nguyen <dinh.linux@gmail.com>
> > > Cc: Pavel Machek <pavel@denx.de>
> > > Cc: Marek Vasut <marex@denx.de>
> > > Cc: Stefan Roese <sr@denx.de>
> > > ---
> > > Changes for v2
> > > - Using load command instead of fatload
> > 
> > The distro_bootcmd can do this and even let's you boot debian/fedora
> > on such
> > a machine in a standardized way. Should we switch to distro_bootcmd
> > instead
> > of adding new ad-hoc stuff ?
> 
> It seems to me that we need to add script into the fs to get that work,
> right?

Yes, that's right. CCing Vagrant, he's the debian guru around here.

Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27 12:29     ` Marek Vasut
@ 2015-11-27 16:57       ` Vagrant Cascadian
  2015-12-01 15:00         ` Chin Liang See
  0 siblings, 1 reply; 10+ messages in thread
From: Vagrant Cascadian @ 2015-11-27 16:57 UTC (permalink / raw)
  To: u-boot

On 2015-11-27, Marek Vasut wrote:
> On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See wrote:
>> On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
>> > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See wrote:
>> > > Adding new environment usbload which will load zImage and
>> > > Linux DTB from USB mass storage through FAT file system.
...
>> > The distro_bootcmd can do this and even let's you boot debian/fedora
>> > on such
>> > a machine in a standardized way. Should we switch to distro_bootcmd
>> > instead
>> > of adding new ad-hoc stuff ?
>> 
>> It seems to me that we need to add script into the fs to get that work,
>> right?

Yes and no. Currently Debian uses a bootscript generated with
flash-kernel, such as:

  https://anonscm.debian.org/cgit/d-i/flash-kernel.git/tree/bootscript/all/bootscr.uboot-generic

But you can also use a syslinux formatted plain text file, such as
extlinux.conf or pxelinux.conf/default, described in
u-boot/doc/README.distro. They look something like this:

  label Boot
  kernel /boot/vmlinuz
  append ro root=/dev/sda2 console=ttyS0,115200n8
  fdtdir /boot/dtbs/
  initrd /boot/initrd.img

The (only) reason debian hasn't yet switched to syslinux-style config
files is that is that the console settings vary wildly by board, and the
"chosen" console property isn't yet consistantly supported on all boards
and kernel versions in use. That may change soon.

But the distro_bootcmd support supports both syslinux-style files and
bootscripts out-of-the-box. Because of the standardization, for any
board you would hope to see working out of the box on Debian(and I
suspect Fedora as well), supporting distro_bootcmd in u-boot upstream
would be ideal.


live well,
  vagrant
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 818 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20151127/e4034670/attachment.sig>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-11-27 16:57       ` Vagrant Cascadian
@ 2015-12-01 15:00         ` Chin Liang See
  2015-12-01 15:12           ` Marek Vasut
  0 siblings, 1 reply; 10+ messages in thread
From: Chin Liang See @ 2015-12-01 15:00 UTC (permalink / raw)
  To: u-boot

Hi Vagrant,

On Fri, 2015-11-27 at 08:57 -0800, Vagrant Cascadian wrote:
> On 2015-11-27, Marek Vasut wrote:
> > On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See wrote:
> > > On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> > > > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See
> > > > wrote:
> > > > > Adding new environment usbload which will load zImage and
> > > > > Linux DTB from USB mass storage through FAT file system.
> ...
> > > > The distro_bootcmd can do this and even let's you boot
> > > > debian/fedora
> > > > on such
> > > > a machine in a standardized way. Should we switch to
> > > > distro_bootcmd
> > > > instead
> > > > of adding new ad-hoc stuff ?
> > > 
> > > It seems to me that we need to add script into the fs to get that
> > > work,
> > > right?
> 
> Yes and no. Currently Debian uses a bootscript generated with
> flash-kernel, such as:
> 
>   https://anonscm.debian.org/cgit/d-i/flash-kernel.git/tree/bootscrip
> t/all/bootscr.uboot-generic
> 
> But you can also use a syslinux formatted plain text file, such as
> extlinux.conf or pxelinux.conf/default, described in
> u-boot/doc/README.distro. They look something like this:
> 
>   label Boot
>   kernel /boot/vmlinuz
>   append ro root=/dev/sda2 console=ttyS0,115200n8
>   fdtdir /boot/dtbs/
>   initrd /boot/initrd.img
> 
> The (only) reason debian hasn't yet switched to syslinux-style config
> files is that is that the console settings vary wildly by board, and
> the
> "chosen" console property isn't yet consistantly supported on all
> boards
> and kernel versions in use. That may change soon.
> 
> But the distro_bootcmd support supports both syslinux-style files and
> bootscripts out-of-the-box. Because of the standardization, for any
> board you would hope to see working out of the box on Debian(and I
> suspect Fedora as well), supporting distro_bootcmd in u-boot upstream
> would be ideal.
> 
> 
> live well,
>   vagrant


Thanks for the pointers and this looks great. I can imagine how this
cool feature easing user when come to update the boot device and boot
file name without the need to update the U-Boot source.

To take this advantage socfpga, ubifs support for NOR and NAND boot
need to be happened first :)

Thanks
Chin Liang

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-12-01 15:00         ` Chin Liang See
@ 2015-12-01 15:12           ` Marek Vasut
  2015-12-01 15:34             ` Chin Liang See
  0 siblings, 1 reply; 10+ messages in thread
From: Marek Vasut @ 2015-12-01 15:12 UTC (permalink / raw)
  To: u-boot

On Tuesday, December 01, 2015 at 04:00:33 PM, Chin Liang See wrote:
> Hi Vagrant,
> 
> On Fri, 2015-11-27 at 08:57 -0800, Vagrant Cascadian wrote:
> > On 2015-11-27, Marek Vasut wrote:
> > > On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See wrote:
> > > > On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> > > > > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See
> > > > > 
> > > > > wrote:
> > > > > > Adding new environment usbload which will load zImage and
> > > > > > Linux DTB from USB mass storage through FAT file system.
> > 
> > ...
> > 
> > > > > The distro_bootcmd can do this and even let's you boot
> > > > > debian/fedora
> > > > > on such
> > > > > a machine in a standardized way. Should we switch to
> > > > > distro_bootcmd
> > > > > instead
> > > > > of adding new ad-hoc stuff ?
> > > > 
> > > > It seems to me that we need to add script into the fs to get that
> > > > work,
> > > > right?
> > 
> > Yes and no. Currently Debian uses a bootscript generated with
> > 
> > flash-kernel, such as:
> >   https://anonscm.debian.org/cgit/d-i/flash-kernel.git/tree/bootscrip
> > 
> > t/all/bootscr.uboot-generic
> > 
> > But you can also use a syslinux formatted plain text file, such as
> > extlinux.conf or pxelinux.conf/default, described in
> > 
> > u-boot/doc/README.distro. They look something like this:
> >   label Boot
> >   kernel /boot/vmlinuz
> >   append ro root=/dev/sda2 console=ttyS0,115200n8
> >   fdtdir /boot/dtbs/
> >   initrd /boot/initrd.img
> > 
> > The (only) reason debian hasn't yet switched to syslinux-style config
> > files is that is that the console settings vary wildly by board, and
> > the
> > "chosen" console property isn't yet consistantly supported on all
> > boards
> > and kernel versions in use. That may change soon.
> > 
> > But the distro_bootcmd support supports both syslinux-style files and
> > bootscripts out-of-the-box. Because of the standardization, for any
> > board you would hope to see working out of the box on Debian(and I
> > suspect Fedora as well), supporting distro_bootcmd in u-boot upstream
> > would be ideal.
> > 
> > 
> > live well,
> > 
> >   vagrant
> 
> Thanks for the pointers and this looks great. I can imagine how this
> cool feature easing user when come to update the boot device and boot
> file name without the need to update the U-Boot source.
> 
> To take this advantage socfpga, ubifs support for NOR and NAND boot
> need to be happened first :)

I already sent you a patch how to do that.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-12-01 15:12           ` Marek Vasut
@ 2015-12-01 15:34             ` Chin Liang See
  2015-12-01 15:38               ` Marek Vasut
  0 siblings, 1 reply; 10+ messages in thread
From: Chin Liang See @ 2015-12-01 15:34 UTC (permalink / raw)
  To: u-boot

On Tue, 2015-12-01 at 16:12 +0100, Marek Vasut wrote:
> On Tuesday, December 01, 2015 at 04:00:33 PM, Chin Liang See wrote:
> > Hi Vagrant,
> > 
> > On Fri, 2015-11-27 at 08:57 -0800, Vagrant Cascadian wrote:
> > > On 2015-11-27, Marek Vasut wrote:
> > > > On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See
> > > > wrote:
> > > > > On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> > > > > > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See
> > > > > > 
> > > > > > wrote:
> > > > > > > Adding new environment usbload which will load zImage and
> > > > > > > Linux DTB from USB mass storage through FAT file system.
> > > 
> > > ...
> > > 
> > > > > > The distro_bootcmd can do this and even let's you boot
> > > > > > debian/fedora
> > > > > > on such
> > > > > > a machine in a standardized way. Should we switch to
> > > > > > distro_bootcmd
> > > > > > instead
> > > > > > of adding new ad-hoc stuff ?
> > > > > 
> > > > > It seems to me that we need to add script into the fs to get
> > > > > that
> > > > > work,
> > > > > right?
> > > 
> > > Yes and no. Currently Debian uses a bootscript generated with
> > > 
> > > flash-kernel, such as:
> > >   https://anonscm.debian.org/cgit/d-i/flash-kernel.git/tree/boots
> > > crip
> > > 
> > > t/all/bootscr.uboot-generic
> > > 
> > > But you can also use a syslinux formatted plain text file, such
> > > as
> > > extlinux.conf or pxelinux.conf/default, described in
> > > 
> > > u-boot/doc/README.distro. They look something like this:
> > >   label Boot
> > >   kernel /boot/vmlinuz
> > >   append ro root=/dev/sda2 console=ttyS0,115200n8
> > >   fdtdir /boot/dtbs/
> > >   initrd /boot/initrd.img
> > > 
> > > The (only) reason debian hasn't yet switched to syslinux-style
> > > config
> > > files is that is that the console settings vary wildly by board,
> > > and
> > > the
> > > "chosen" console property isn't yet consistantly supported on all
> > > boards
> > > and kernel versions in use. That may change soon.
> > > 
> > > But the distro_bootcmd support supports both syslinux-style files
> > > and
> > > bootscripts out-of-the-box. Because of the standardization, for
> > > any
> > > board you would hope to see working out of the box on Debian(and
> > > I
> > > suspect Fedora as well), supporting distro_bootcmd in u-boot
> > > upstream
> > > would be ideal.
> > > 
> > > 
> > > live well,
> > > 
> > >   vagrant
> > 
> > Thanks for the pointers and this looks great. I can imagine how
> > this
> > cool feature easing user when come to update the boot device and
> > boot
> > file name without the need to update the U-Boot source.
> > 
> > To take this advantage socfpga, ubifs support for NOR and NAND boot
> > need to be happened first :)
> 
> I already sent you a patch how to do that.

Yup, thanks again for that. Hope can continue on that as was attending
customer support / requests :)

Thanks
Chin Liang

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB
  2015-12-01 15:34             ` Chin Liang See
@ 2015-12-01 15:38               ` Marek Vasut
  0 siblings, 0 replies; 10+ messages in thread
From: Marek Vasut @ 2015-12-01 15:38 UTC (permalink / raw)
  To: u-boot

On Tuesday, December 01, 2015 at 04:34:41 PM, Chin Liang See wrote:
> On Tue, 2015-12-01 at 16:12 +0100, Marek Vasut wrote:
> > On Tuesday, December 01, 2015 at 04:00:33 PM, Chin Liang See wrote:
> > > Hi Vagrant,
> > > 
> > > On Fri, 2015-11-27 at 08:57 -0800, Vagrant Cascadian wrote:
> > > > On 2015-11-27, Marek Vasut wrote:
> > > > > On Friday, November 27, 2015 at 01:23:34 PM, Chin Liang See
> > > > > 
> > > > > wrote:
> > > > > > On Fri, 2015-11-27 at 11:36 +0100, Marek Vasut wrote:
> > > > > > > On Friday, November 27, 2015 at 03:36:42 AM, Chin Liang See
> > > > > > > 
> > > > > > > wrote:
> > > > > > > > Adding new environment usbload which will load zImage and
> > > > > > > > Linux DTB from USB mass storage through FAT file system.
> > > > 
> > > > ...
> > > > 
> > > > > > > The distro_bootcmd can do this and even let's you boot
> > > > > > > debian/fedora
> > > > > > > on such
> > > > > > > a machine in a standardized way. Should we switch to
> > > > > > > distro_bootcmd
> > > > > > > instead
> > > > > > > of adding new ad-hoc stuff ?
> > > > > > 
> > > > > > It seems to me that we need to add script into the fs to get
> > > > > > that
> > > > > > work,
> > > > > > right?
> > > > 
> > > > Yes and no. Currently Debian uses a bootscript generated with
> > > > 
> > > > flash-kernel, such as:
> > > >   https://anonscm.debian.org/cgit/d-i/flash-kernel.git/tree/boots
> > > > 
> > > > crip
> > > > 
> > > > t/all/bootscr.uboot-generic
> > > > 
> > > > But you can also use a syslinux formatted plain text file, such
> > > > as
> > > > extlinux.conf or pxelinux.conf/default, described in
> > > > 
> > > > u-boot/doc/README.distro. They look something like this:
> > > >   label Boot
> > > >   kernel /boot/vmlinuz
> > > >   append ro root=/dev/sda2 console=ttyS0,115200n8
> > > >   fdtdir /boot/dtbs/
> > > >   initrd /boot/initrd.img
> > > > 
> > > > The (only) reason debian hasn't yet switched to syslinux-style
> > > > config
> > > > files is that is that the console settings vary wildly by board,
> > > > and
> > > > the
> > > > "chosen" console property isn't yet consistantly supported on all
> > > > boards
> > > > and kernel versions in use. That may change soon.
> > > > 
> > > > But the distro_bootcmd support supports both syslinux-style files
> > > > and
> > > > bootscripts out-of-the-box. Because of the standardization, for
> > > > any
> > > > board you would hope to see working out of the box on Debian(and
> > > > I
> > > > suspect Fedora as well), supporting distro_bootcmd in u-boot
> > > > upstream
> > > > would be ideal.
> > > > 
> > > > 
> > > > live well,
> > > > 
> > > >   vagrant
> > > 
> > > Thanks for the pointers and this looks great. I can imagine how
> > > this
> > > cool feature easing user when come to update the boot device and
> > > boot
> > > file name without the need to update the U-Boot source.
> > > 
> > > To take this advantage socfpga, ubifs support for NOR and NAND boot
> > > need to be happened first :)
> > 
> > I already sent you a patch how to do that.
> 
> Yup, thanks again for that. Hope can continue on that as was attending
> customer support / requests :)

NP, take your time.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2015-12-01 15:38 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-27  2:36 [U-Boot] [PATCH v2] arm: socfpga: Enable load zImage and Linux DTB from USB Chin Liang See
2015-11-27  3:18 ` Stefan Roese
2015-11-27 10:36 ` Marek Vasut
2015-11-27 12:23   ` Chin Liang See
2015-11-27 12:29     ` Marek Vasut
2015-11-27 16:57       ` Vagrant Cascadian
2015-12-01 15:00         ` Chin Liang See
2015-12-01 15:12           ` Marek Vasut
2015-12-01 15:34             ` Chin Liang See
2015-12-01 15:38               ` Marek Vasut

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox