[U-Boot] imx6, spl and falcon boot

Hi,
First off, sorry I'm not used to using mailing lists. I'm not sure if this is the best way to dig for information. We've recently switched to uboot/linux from wince and I'm trying to understand how configuring uboot works. I'm also trying to find out how to use the SPL framework and possibly falcon mode with a i.mx6 nitrogen6x board. I'd be delighted if any one could help!
Thanks,

Am 15.02.2013 21:45, schrieb Chaves, Kevin:
Hi,
First off, sorry I'm not used to using mailing lists. I'm not sure if this is the best way to dig for information. We've recently switched to uboot/linux from wince and I'm trying to understand how configuring uboot works. I'm also trying to find out how to use the SPL framework and possibly falcon mode with a i.mx6 nitrogen6x board. I'd be delighted if any one could help!
I haven't used spl and falcon mode, so I can't help with these.
Regarding the general support for the i.mx6 nitrogen6x this isn't in U-Boot mainline, yet.
Try to git pull the most recent U-Boot mainline from git://git.denx.de/u-boot.git [1] and apply the patch
http://patchwork.ozlabs.org/patch/216991/
You should then be able to build one of the supported boards
nitrogen6q nitrogen6dl nitrogen6s nitrogen6q2g nitrogen6dl2g nitrogen6s1g
by
make nitrogen6xxx_config make
(replace the 'xxx' with the ending matching your board, e.g. 'q' if you have a Quad board).
Best regards
Dirk
[1] http://git.denx.de/cgi-bin/gitweb.cgi?p=u-boot.git;a=summary

Excellent thanks, the "falcon" boot or mode is booting directly into the kernel from the SPL and skipping uboot altogether.
-----Original Message----- From: Dirk Behme [mailto:dirk.behme@gmail.com] Sent: Saturday, February 16, 2013 2:32 AM To: Chaves, Kevin Cc: u-boot@lists.denx.de; Eric Nelson Subject: Re: [U-Boot] imx6, spl and falcon boot
Am 15.02.2013 21:45, schrieb Chaves, Kevin:
Hi,
First off, sorry I'm not used to using mailing lists. I'm not sure if this is the best way to dig for information. We've recently switched to uboot/linux from wince and I'm trying to understand how configuring uboot works. I'm also trying to find out how to use the SPL framework and possibly falcon mode with a i.mx6 nitrogen6x board. I'd be delighted if any one could help!
I haven't used spl and falcon mode, so I can't help with these.
Regarding the general support for the i.mx6 nitrogen6x this isn't in U-Boot mainline, yet.
Try to git pull the most recent U-Boot mainline from git://git.denx.de/u-boot.git [1] and apply the patch
http://patchwork.ozlabs.org/patch/216991/
You should then be able to build one of the supported boards
nitrogen6q nitrogen6dl nitrogen6s nitrogen6q2g nitrogen6dl2g nitrogen6s1g
by
make nitrogen6xxx_config make
(replace the 'xxx' with the ending matching your board, e.g. 'q' if you have a Quad board).
Best regards
Dirk
[1] http://git.denx.de/cgi-bin/gitweb.cgi?p=u-boot.git;a=summary

Ok is there documentation anywhere that can show the requirements for supporting SPL if I'd like to be able to implement it, same with falcon mode? I've already got support for nitrogen6x through another vendor but they won't support the spl.
I'm taking a look at board/woodburn/woodburn.c to see what was done for another board that supports SPL. It just looks like void board_init_f(ulong dummy) needs to be implemented for the SPL.
Someone recommend I look at another set of patch notes that have better docs, but I see it mostly has the falcon mode in it. http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/146987/focus=147040
-----Original Message----- From: Dirk Behme [mailto:dirk.behme@gmail.com] Sent: Saturday, February 16, 2013 2:32 AM To: Chaves, Kevin Cc: u-boot@lists.denx.de; Eric Nelson Subject: Re: [U-Boot] imx6, spl and falcon boot
Am 15.02.2013 21:45, schrieb Chaves, Kevin:
Hi,
First off, sorry I'm not used to using mailing lists. I'm not sure if this is the best way to dig for information. We've recently switched to uboot/linux from wince and I'm trying to understand how configuring uboot works. I'm also trying to find out how to use the SPL framework and possibly falcon mode with a i.mx6 nitrogen6x board. I'd be delighted if any one could help!
I haven't used spl and falcon mode, so I can't help with these.
Regarding the general support for the i.mx6 nitrogen6x this isn't in U-Boot mainline, yet.
Try to git pull the most recent U-Boot mainline from git://git.denx.de/u-boot.git [1] and apply the patch
http://patchwork.ozlabs.org/patch/216991/
You should then be able to build one of the supported boards
nitrogen6q nitrogen6dl nitrogen6s nitrogen6q2g nitrogen6dl2g nitrogen6s1g
by
make nitrogen6xxx_config make
(replace the 'xxx' with the ending matching your board, e.g. 'q' if you have a Quad board).
Best regards
Dirk
[1] http://git.denx.de/cgi-bin/gitweb.cgi?p=u-boot.git;a=summary

Hi,
On Mon, Feb 18, 2013 at 11:44:36AM -0700, Chaves, Kevin wrote :
Ok is there documentation anywhere that can show the requirements for supporting SPL if I'd like to be able to implement it, same with falcon mode? I've already got support for nitrogen6x through another vendor but they won't support the spl.
I'm taking a look at board/woodburn/woodburn.c to see what was done for another board that supports SPL. It just looks like void board_init_f(ulong dummy) needs to be implemented for the SPL.
Someone recommend I look at another set of patch notes that have better docs, but I see it mostly has the falcon mode in it. http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/146987/focus=147040
i.Mx6 doen't really require an SPL as the romcode is already able to do quite a lot. If what your are looking for is booting directly your kernel, you can have a look at that "bootloader" (it is actually much less than that):
https://github.com/alexandrebelloni/whoosh
It supports sabrelite and sabresd, it should be quite fast to port to nitrogen6x. I can do it but I don't have access to the hardware...yet.
Regards,

On Mon, Feb 18, 2013 at 6:36 PM, Alexandre Belloni alexandre.belloni@piout.net wrote:
Hi,
On Mon, Feb 18, 2013 at 11:44:36AM -0700, Chaves, Kevin wrote :
Ok is there documentation anywhere that can show the requirements for supporting SPL if I'd like to be able to implement it, same with falcon mode? I've already got support for nitrogen6x through another vendor but they won't support the spl.
I'm taking a look at board/woodburn/woodburn.c to see what was done for another board that supports SPL. It just looks like void board_init_f(ulong dummy) needs to be implemented for the SPL.
Someone recommend I look at another set of patch notes that have better docs, but I see it mostly has the falcon mode in it. http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/146987/focus=147040
i.Mx6 doen't really require an SPL as the romcode is already able to do quite a lot. If what your are looking for is booting directly your kernel, you can have a look at that "bootloader" (it is actually much less than that):
https://github.com/alexandrebelloni/whoosh
It supports sabrelite and sabresd, it should be quite fast to port to nitrogen6x. I can do it but I don't have access to the hardware...yet.
The point of using the Falcon mode here would be to allow boot onto interactive mode, when need, and boot fast by default. The whoosh goal is *very* nice but it is different. :-)

On Mon, Feb 18, 2013 at 06:56:36PM -0300, Otavio Salvador wrote :
The point of using the Falcon mode here would be to allow boot onto interactive mode, when need, and boot fast by default. The whoosh goal is *very* nice but it is different. :-)
Yeah, exactly, the use case is different but it was not clearly stated that using u-boot was mandatory in the first mail ;)
Anyway, last time I looked, SPL was not supported on i.mx6, is it now ?

This is almost exactly what we want to do, we just want to be able to hold a key down during the boot and switch it to a recovery settings with a different kernel/rfs, would this be supported as well?
-----Original Message----- From: Alexandre Belloni [mailto:alexandre.belloni@piout.net] Sent: Monday, February 18, 2013 4:37 PM To: Chaves, Kevin Cc: Dirk Behme; u-boot@lists.denx.de Subject: Re: [U-Boot] imx6, spl and falcon boot
Hi,
On Mon, Feb 18, 2013 at 11:44:36AM -0700, Chaves, Kevin wrote :
Ok is there documentation anywhere that can show the requirements for supporting SPL if I'd like to be able to implement it, same with falcon mode? I've already got support for nitrogen6x through another vendor but they won't support the spl.
I'm taking a look at board/woodburn/woodburn.c to see what was done for another board that supports SPL. It just looks like void board_init_f(ulong dummy) needs to be implemented for the SPL.
Someone recommend I look at another set of patch notes that have better docs, but I see it mostly has the falcon mode in it. http://thread.gmane.org/gmane.comp.boot-loaders.u-boot/146987/focus=14 7040
i.Mx6 doen't really require an SPL as the romcode is already able to do quite a lot. If what your are looking for is booting directly your kernel, you can have a look at that "bootloader" (it is actually much less than that):
https://github.com/alexandrebelloni/whoosh
It supports sabrelite and sabresd, it should be quite fast to port to nitrogen6x. I can do it but I don't have access to the hardware...yet.
Regards,
-- Alexandre Belloni

On Mon, Feb 18, 2013 at 02:59:24PM -0700, Chaves, Kevin wrote :
This is almost exactly what we want to do, we just want to be able to hold a key down during the boot and switch it to a recovery settings with a different kernel/rfs, would this be supported as well?
No, that is not supported and probably won't be. Some people will argue that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.

Dear Alexandre Belloni,
In message 20130219112532.GB24397@piout.net you wrote:
No, that is not supported and probably won't be. Some people will argue
I think you are wrong. This is definitely a "not supported _yet_".
that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.
Yes, some people will think so, and some will actually do that. Others (and I would expect these to be the majority) will realize the benefits of being able to switch on demand (say, key press, jumper setting, etc.) between different boot modes, boot images, etc.
I am absolutely sure that SPL support for iMX6 will be added rather sooner than later.
Best regards,
Wolfgang Denk

On Tue, Feb 19, 2013 at 12:35:01PM +0100, Wolfgang Denk wrote :
Dear Alexandre Belloni,
In message 20130219112532.GB24397@piout.net you wrote:
No, that is not supported and probably won't be. Some people will argue
I think you are wrong. This is definitely a "not supported _yet_".
that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.
Yes, some people will think so, and some will actually do that. Others (and I would expect these to be the majority) will realize the benefits of being able to switch on demand (say, key press, jumper setting, etc.) between different boot modes, boot images, etc.
I am absolutely sure that SPL support for iMX6 will be added rather sooner than later.
Yeah, don't misinterpret me, I was just saying that it will not be supported in whoosh. I also believe that SPL and falcon mode will come to i.mx6 and I'm also interested in getting that support ;)

Thanks for the response, so the whoosh does not support holding a key to get into another image? I guess that won't work. So if I wanted to support the SPL on the nitrogent6x are there any instruction on what requirements it has to support it.
I'm guessing all the work I'd need to do is in board/boundary/nitrogen6x? Also how would I normally configure and build an spl for a working board. There is a lot of config options in the README for the spl.
-----Original Message----- From: Alexandre Belloni [mailto:alexandre.belloni@piout.net] Sent: Tuesday, February 19, 2013 9:00 AM To: Wolfgang Denk Cc: Chaves, Kevin; u-boot@lists.denx.de; Dirk Behme Subject: Re: [U-Boot] imx6, spl and falcon boot
On Tue, Feb 19, 2013 at 12:35:01PM +0100, Wolfgang Denk wrote :
Dear Alexandre Belloni,
In message 20130219112532.GB24397@piout.net you wrote:
No, that is not supported and probably won't be. Some people will argue
I think you are wrong. This is definitely a "not supported _yet_".
that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.
Yes, some people will think so, and some will actually do that. Others (and I would expect these to be the majority) will realize the benefits of being able to switch on demand (say, key press, jumper setting, etc.) between different boot modes, boot images, etc.
I am absolutely sure that SPL support for iMX6 will be added rather sooner than later.
Yeah, don't misinterpret me, I was just saying that it will not be supported in whoosh. I also believe that SPL and falcon mode will come to i.mx6 and I'm also interested in getting that support ;)
-- Alexandre Belloni

Hi Kevin,
I'm a bit late to this party, but have a couple of comments...
On 02/19/2013 08:20 AM, Chaves, Kevin wrote:
Thanks for the response, so the whoosh does not support holding a key to get into another image? I guess that won't work.
Note that there's already support for key-handling in our Nitrogen6X code: https://github.com/boundarydevices/u-boot-imx6/blob/production/board/boundar...
So if I wanted to support the SPL on the nitrogent6x are there any instruction on what requirements it has to support it.
The use of SPL seems to be a separate topic.
Is your objective simply a faster boot?
We don't have any specific plans to add SPL support for Nitrogen6x, but are interested in hearing what you're after.
I'm guessing all the work I'd need to do is in board/boundary/nitrogen6x? Also how would I normally configure and build an spl for a working board. There is a lot of config options in the README for the spl.
-----Original Message----- From: Alexandre Belloni [mailto:alexandre.belloni@piout.net] Sent: Tuesday, February 19, 2013 9:00 AM To: Wolfgang Denk Cc: Chaves, Kevin; u-boot@lists.denx.de; Dirk Behme Subject: Re: [U-Boot] imx6, spl and falcon boot
On Tue, Feb 19, 2013 at 12:35:01PM +0100, Wolfgang Denk wrote :
Dear Alexandre Belloni,
In message 20130219112532.GB24397@piout.net you wrote:
No, that is not supported and probably won't be. Some people will argue
I think you are wrong. This is definitely a "not supported _yet_".
that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.
Yes, some people will think so, and some will actually do that. Others (and I would expect these to be the majority) will realize the benefits of being able to switch on demand (say, key press, jumper setting, etc.) between different boot modes, boot images, etc.
I am absolutely sure that SPL support for iMX6 will be added rather sooner than later.
Yeah, don't misinterpret me, I was just saying that it will not be supported in whoosh. I also believe that SPL and falcon mode will come to i.mx6 and I'm also interested in getting that support ;)
Whoosh seems pretty compelling with such a small code base. Does it really boot faster though? Do you have any numbers for TTP (Time-to-penguin) on a SABRE Lite or SABRE SD?
Regards,
Eric

It's not so much a faster boot I'm looking for but just relying less on uboot to initialize the device. The initial idea by my superiors is make an infallible way to update uboot, since they think they'll screw it up and have to support a field update. So we wanted to make two images with uboot/kernel/rfs, one for recovery and have a way to switch the settings on startup. That way we have a small first stage boot that won't ever need to be updated so long as it can boot from two different partitions.
I realized it probably wasn't that useful to keep uboot around since the spl+falcon will increase the boot time. Figured I could kill two birds with one stone here. Faster boot, and no need to update the bootloader in the field, or at least minimize how much could change in its start up procedure so there is less to "fix" in the future.
-----Original Message----- From: Eric Nelson [mailto:eric.nelson@boundarydevices.com] Sent: Tuesday, February 19, 2013 11:34 AM To: Chaves, Kevin Cc: Alexandre Belloni; Wolfgang Denk; u-boot@lists.denx.de; Dirk Behme Subject: Re: [U-Boot] imx6, spl and falcon boot
Hi Kevin,
I'm a bit late to this party, but have a couple of comments...
On 02/19/2013 08:20 AM, Chaves, Kevin wrote:
Thanks for the response, so the whoosh does not support holding a key to get into another image? I guess that won't work.
Note that there's already support for key-handling in our Nitrogen6X code: https://github.com/boundarydevices/u-boot-imx6/blob/production/board/boundar...
So if I wanted to support the SPL on the nitrogent6x are there any instruction on what requirements it has to support it.
The use of SPL seems to be a separate topic.
Is your objective simply a faster boot?
We don't have any specific plans to add SPL support for Nitrogen6x, but are interested in hearing what you're after.
I'm guessing all the work I'd need to do is in board/boundary/nitrogen6x? Also how would I normally configure and build an spl for > a working board. There is a lot of config options > in the README for the spl.
-----Original Message----- From: Alexandre Belloni [mailto:alexandre.belloni@piout.net] Sent: Tuesday, February 19, 2013 9:00 AM To: Wolfgang Denk Cc: Chaves, Kevin; u-boot@lists.denx.de; Dirk Behme Subject: Re: [U-Boot] imx6, spl and falcon boot
On Tue, Feb 19, 2013 at 12:35:01PM +0100, Wolfgang Denk wrote :
Dear Alexandre Belloni,
In message 20130219112532.GB24397@piout.net you wrote:
No, that is not supported and probably won't be. Some people will argue
I think you are wrong. This is definitely a "not supported _yet_".
that you probably don't need a bootloader once you are able to boot a linux kernel as you can probably do everything you want from there.
Yes, some people will think so, and some will actually do that. Others (and I would expect these to be the majority) will realize the benefits of being able to switch on demand (say, key press, jumper setting, etc.) between different boot modes, boot images, etc.
I am absolutely sure that SPL support for iMX6 will be added rather sooner than later.
Yeah, don't misinterpret me, I was just saying that it will not be supported in whoosh. I also believe that SPL and falcon mode will > come to i.mx6 and I'm also interested in getting that support ;)
Whoosh seems pretty compelling with such a small code base. Does it really boot faster though? Do you have any numbers for TTP (Time-to-penguin) on a SABRE Lite or SABRE SD?
Regards,
Eric

On Tue, Feb 19, 2013 at 3:22 PM, Chaves, Kevin kevin.chaves@thermofisher.com wrote:
It's not so much a faster boot I'm looking for but just relying less on uboot to initialize the device. The initial idea by my superiors is make an infallible way to update uboot, since they think they'll screw it up and have to support a field update. So we wanted to make two images with uboot/kernel/rfs, one for recovery and have a way to switch the settings on startup. That way we have a small first stage boot that won't ever need to be updated so long as it can boot from two different partitions.
I realized it probably wasn't that useful to keep uboot around since the spl+falcon will increase the boot time. Figured I could kill two birds with one stone here. Faster boot, and no need to update the bootloader in the field, or at least minimize how much could change in its start up procedure so there is less to "fix" in the future.
If you just want the fallback and upgrade mode, you can get it with current u-boot + whatdog + bootcount and fw_env in target (or kexec).
Regards,

So uboot can recover if it's bad using watchdog? How does this work if the binary is clobbered?
-----Original Message----- From: otavio.salvador@gmail.com [mailto:otavio.salvador@gmail.com] On Behalf Of Otavio Salvador Sent: Tuesday, February 19, 2013 1:34 PM To: Chaves, Kevin Cc: Eric Nelson; u-boot@lists.denx.de; Dirk Behme Subject: Re: [U-Boot] imx6, spl and falcon boot
On Tue, Feb 19, 2013 at 3:22 PM, Chaves, Kevin kevin.chaves@thermofisher.com wrote:
It's not so much a faster boot I'm looking for but just relying less on uboot to initialize the device. The initial idea by my superiors is make an infallible way to update uboot, since they think they'll screw it up and have to support a field update. So we wanted to make two images with uboot/kernel/rfs, one for recovery and have a way to switch the settings on startup. That way we have a small first stage boot that won't ever need to be updated so long as it can boot from two different partitions.
I realized it probably wasn't that useful to keep uboot around since the spl+falcon will increase the boot time. Figured I could kill two birds with one stone here. Faster boot, and no need to update the bootloader in the field, or at least minimize how much could change in its start up procedure so there is less to "fix" in the future.
If you just want the fallback and upgrade mode, you can get it with current u-boot + whatdog + bootcount and fw_env in target (or kexec).
Regards,

On Tue, Feb 19, 2013 at 3:48 PM, Chaves, Kevin kevin.chaves@thermofisher.com wrote:
So uboot can recover if it's bad using watchdog? How does this work if the binary is clobbered?
Watchdog + bootcount.

Hi Eric,
On Tue, Feb 19, 2013 at 09:33:58AM -0700, Eric Nelson wrote :
Whoosh seems pretty compelling with such a small code base. Does it really boot faster though? Do you have any numbers for TTP (Time-to-penguin) on a SABRE Lite or SABRE SD?
I don't exactly have that number but I believe you can go under 100ms. If you have a look at my presentation at ELCE [1] or that video on youtube [2], we basically are able too boot an start an openGL application under 600ms from reset.
But that is a lot of self advertising, we can continue to discuss that off the ML if you want.
[1] http://www.elinux.org/images/d/d1/Alexandre_Belloni_boottime_optimizations.p... [2] https://www.youtube.com/watch?v=KPU4_QVPFZ0
Regards,

Hello Alexandre,
On 02/19/2013 10:26 PM, Alexandre Belloni wrote:
Hi Eric,
On Tue, Feb 19, 2013 at 09:33:58AM -0700, Eric Nelson wrote :
Whoosh seems pretty compelling with such a small code base. Does it really boot faster though? Do you have any numbers for TTP (Time-to-penguin) on a SABRE Lite or SABRE SD?
I don't exactly have that number but I believe you can go under 100ms. If you have a look at my presentation at ELCE [1] or that video on youtube [2], we basically are able too boot an start an openGL application under 600ms from reset.
But that is a lot of self advertising, we can continue to discuss that off the ML if you want.
Do you have a link for the sources of opengl application?
So I can make some comparison (I might have some time this weekend, just for the fun of it...) Or even later if opengl support bites me... I have a ti / spl boot so might be interesting to compare.
Out of curiosity, do you have any numbers for QNX?
Regards, Jeroen

On Wed, Feb 20, 2013 at 12:19:12AM +0100, Jeroen Hofstee wrote :
Do you have a link for the sources of opengl application?
Part of the challenge was that we didn't have access to the sources. It is a sample from vivante that is provided by freescale along with the proprietary driver.
So I can make some comparison (I might have some time this weekend, just for the fun of it...) Or even later if opengl support bites me... I have a ti / spl boot so might be interesting to compare.
Yeah, I wanted to test that on a pandaboard but I didn't have the time to finish.
Out of curiosity, do you have any numbers for QNX?
I didn't try that either.
Regards,

On 02/19/2013 02:26 PM, Alexandre Belloni wrote:
Hi Eric,
On Tue, Feb 19, 2013 at 09:33:58AM -0700, Eric Nelson wrote :
Whoosh seems pretty compelling with such a small code base. Does it really boot faster though? Do you have any numbers for TTP (Time-to-penguin) on a SABRE Lite or SABRE SD?
I don't exactly have that number but I believe you can go under 100ms. If you have a look at my presentation at ELCE [1] or that video on youtube [2], we basically are able too boot an start an openGL application under 600ms from reset.
But that is a lot of self advertising, we can continue to discuss that off the ML if you want.
[1] http://www.elinux.org/images/d/d1/Alexandre_Belloni_boottime_optimizations.p... [2] https://www.youtube.com/watch?v=KPU4_QVPFZ0
Self advertisement or not, this is cool.
Great job Alexandre!
participants (7)
-
Alexandre Belloni
-
Chaves, Kevin
-
Dirk Behme
-
Eric Nelson
-
Jeroen Hofstee
-
Otavio Salvador
-
Wolfgang Denk