All of lore.kernel.org
 help / color / mirror / Atom feed
* AST2500 support questions
@ 2016-06-07 18:43 Shay Slobodkin
  2016-06-07 21:38 ` Rick Altherr
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Shay Slobodkin @ 2016-06-07 18:43 UTC (permalink / raw)
  To: openbmc

[-- Attachment #1: Type: text/plain, Size: 2580 bytes --]

Hi,

Following the latest great news of adding support for AST2500 into main code, we boost up our work to align with yours.
Several questions regarding our current status, appreciate the assistance hopefully it will be merged into openbmc code as well soon.

1. We were trying to fetch latest code from origin, hoping AST2500 will be inside already.
After fetch, we couldn't find the new AST2500 addition under:
meta-openbmc-bsp/meta-aspeed/ or meta-openbmc-machines/
Is it held somewhere else, on a different git branch?


2. We have loaded ast2500-evb with aspped-ast2500-evb.dtb file on aspeed evb, but we faced some problems with DTB.
We tried kernels 4.6 and 4.7 from:
<https://github.com/shenki/linux/tree/dev-4.7>
<https://github.com/openbmc/linux/tree/dev-4.6>

We tried to boot it with uImage and separate DTB image using the command 'bootm <KERNEL_ADDR> - <DTB_ADDR>'
but the kernel seems to halt during boot, the only messages we got were:

## Booting kernel from Legacy Image at 83000000 ...
   Image Name:   Linux-4.7.0-rc1-12701-gca25849-d
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    2102392 Bytes = 2 MiB
   Load Address: 80800000
   Entry Point:  80800000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 82000000
   Booting using the fdt blob at 0x82000000
   Loading Kernel Image ... OK
OK
   Loading Device Tree to 9eb7b000, end 9eb7f971 ... OK
Starting kernel ...
Uncompressing Linux... done, booting the kernel.

We added CONFIG_OF_LIBFDT to ast-g5.h and it allow us to get to boot with a separate DTB file (aspeed-ast2500-evb.dtb) as seen above.

We also tried to boot zImage, we failed with the following message (for that we added CONFIG_CMD_BOOTZ to u-boot config):

ast# bootz 0x83000000

Our initial try, we received this output:

Starting kernel ...
Uncompressing Linux... done, booting the kernel.
no ATAGS support: can't continue

Then we added CONFFIG_ATAGS to kernel config and failed with the below:

Starting kernel ...
Uncompressing Linux... done, booting the kernel.
Error: unrecognized/unsupported machine ID (r1 = 0x000022b8).
Available machine support:
ID (hex)        NAME
ffffffff        Generic DT based system
ffffffff        ASpeed SoC


Which u-boot command do you suggest for booting with DTB file?
How did you guys managed to boot?

3. We saw in a latest updates that there is a new u-boot https://github.com/legoater/u-boot/tree/v2016.05-ast2500.
Is it stable enough for using it?

Thank you guys for the great support,
Shay

[-- Attachment #2: Type: text/html, Size: 7783 bytes --]

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

* Re: AST2500 support questions
  2016-06-07 18:43 AST2500 support questions Shay Slobodkin
@ 2016-06-07 21:38 ` Rick Altherr
  2016-06-08 12:16 ` Cédric Le Goater
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Rick Altherr @ 2016-06-07 21:38 UTC (permalink / raw)
  To: Shay Slobodkin; +Cc: openbmc

[-- Attachment #1: Type: text/plain, Size: 3996 bytes --]

openbmc/openbmc master only has AST2400 support.  All of the AST2500
support is in separate branches for now as it is incomplete and AST2400
support on those branches hasn't been tested yet.  If you want to build an
AST2500 image, you can use my kc8apf/openbmc ast2500 branch
<https://github.com/kc8apf/openbmc/tree/ast2500> which will build an image
for the EVB.  I know the resulting u-boot gets far enough to load a kernel
but I haven't tried booting the full image yet.  Xo Wang has been trying
that and I believe his recent kernel pull request
<https://github.com/openbmc/linux/pull/93> is needed for the root to
mount.  This is all a big work in progress.  I'm hoping to pull all the
changes from my ast2500 branch into openbmc/openbmc sometime this week.
Please feel free to mail out patches or share trees in the meantime.

On Tue, Jun 7, 2016 at 11:43 AM, Shay Slobodkin <shays@mellanox.com> wrote:

> Hi,
>
>
>
> Following the latest great news of adding support for AST2500 into main
> code, we boost up our work to align with yours.
>
> Several questions regarding our current status, appreciate the assistance
> hopefully it will be merged into openbmc code as well soon.
>
>
>
> 1. We were trying to fetch latest code from origin, hoping AST2500 will be
> inside already.
>
> After fetch, we couldn’t find the new AST2500 addition under:
>
> meta-openbmc-bsp/meta-aspeed/ or meta-openbmc-machines/
>
> Is it held somewhere else, on a different git branch?
>
>
>
>
>
> 2. We have loaded ast2500-evb with aspped-ast2500-evb.dtb file on aspeed
> evb, but we faced some problems with DTB.
>
> We tried kernels 4.6 and 4.7 from:
>
> <https://github.com/shenki/linux/tree/dev-4.7>
>
> <https://github.com/openbmc/linux/tree/dev-4.6>
>
>
>
> We tried to boot it with uImage and separate DTB image using the command
> ‘bootm <KERNEL_ADDR> - <DTB_ADDR>’
>
> but the kernel seems to halt during boot, the only messages we got were:
>
>
>
> ## Booting kernel from Legacy Image at 83000000 ...
>
>    Image Name:   Linux-4.7.0-rc1-12701-gca25849-d
>
>    Image Type:   ARM Linux Kernel Image (uncompressed)
>
>    Data Size:    2102392 Bytes = 2 MiB
>
>    Load Address: 80800000
>
>    Entry Point:  80800000
>
>    Verifying Checksum ... OK
>
> ## Flattened Device Tree blob at 82000000
>
>    Booting using the fdt blob at 0x82000000
>
>    Loading Kernel Image ... OK
>
> OK
>
>    Loading Device Tree to 9eb7b000, end 9eb7f971 ... OK
>
> Starting kernel ...
>
> Uncompressing Linux... done, booting the kernel.
>
>
>
> We added CONFIG_OF_LIBFDT to ast-g5.h and it allow us to get to boot with
> a separate DTB file (aspeed-ast2500-evb.dtb) as seen above.
>
>
>
> We also tried to boot zImage, we failed with the following message (for
> that we added CONFIG_CMD_BOOTZ to u-boot config):
>
>
>
> ast# bootz 0x83000000
>
>
>
> Our initial try, we received this output:
>
>
>
> Starting kernel ...
>
> Uncompressing Linux... done, booting the kernel.
>
> no ATAGS support: can't continue
>
>
>
> Then we added CONFFIG_ATAGS to kernel config and failed with the below:
>
>
>
> Starting kernel ...
>
> Uncompressing Linux... done, booting the kernel.
>
> Error: unrecognized/unsupported machine ID (r1 = 0x000022b8).
>
> Available machine support:
>
> ID (hex)        NAME
>
> ffffffff        Generic DT based system
>
> ffffffff        ASpeed SoC
>
>
>
>
>
> Which u-boot command do you suggest for booting with DTB file?
>
> How did you guys managed to boot?
>
>
>
> 3. We saw in a latest updates that there is a new u-boot
> https://github.com/legoater/u-boot/tree/v2016.05-ast2500.
>
> Is it stable enough for using it?
>
>
>
> Thank you guys for the great support,
>
> Shay
>
> _______________________________________________
> openbmc mailing list
> openbmc@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/openbmc
>
>

[-- Attachment #2: Type: text/html, Size: 7783 bytes --]

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

* Re: AST2500 support questions
  2016-06-07 18:43 AST2500 support questions Shay Slobodkin
  2016-06-07 21:38 ` Rick Altherr
@ 2016-06-08 12:16 ` Cédric Le Goater
  2016-06-09  0:54 ` Patrick Williams
  2016-06-09 18:35 ` Xo Wang
  3 siblings, 0 replies; 6+ messages in thread
From: Cédric Le Goater @ 2016-06-08 12:16 UTC (permalink / raw)
  To: Shay Slobodkin, openbmc

On 06/07/2016 08:43 PM, Shay Slobodkin wrote:
> Hi,
> 
>  
> 
> Following the latest great news of adding support for AST2500 into main code, we boost up our work to align with yours.
> 
> Several questions regarding our current status, appreciate the assistance hopefully it will be merged into openbmc code as well soon.
> 
>  
> 
> 1. We were trying to fetch latest code from origin, hoping AST2500 will be inside already.
> 
> After fetch, we couldn’t find the new AST2500 addition under:
> 
> meta-openbmc-bsp/meta-aspeed/ or meta-openbmc-machines/
> 
> Is it held somewhere else, on a different git branch?
> 
>  
> 
>  
> 
> 2. We have loaded ast2500-evb with aspped-ast2500-evb.dtb file on aspeed evb, but we faced some problems with DTB.
> 
> We tried kernels 4.6 and 4.7 from:
> 
> <https://github.com/shenki/linux/tree/dev-4.7>
> 
> <https://github.com/openbmc/linux/tree/dev-4.6>

I have added these for the ramfs :

	CONFIG_KERNEL_LZMA=y
	CONFIG_RD_LZMA=y
	CONFIG_SHMEM=y
	CONFIG_TMPFS=y
	CONFIG_DECOMPRESS_LZMA=y

and create the uImage as specified here : 

	https://github.com/openbmc/docs/blob/master/kernel-development.md

do the same with the ramfs. 


> We tried to boot it with uImage and separate DTB image using the command ‘bootm <KERNEL_ADDR> - <DTB_ADDR>’
> 
> but the kernel seems to halt during boot, the only messages we got were:
> 
>  
> 
> ## Booting kernel from Legacy Image at 83000000 ...
> 
>    Image Name:   Linux-4.7.0-rc1-12701-gca25849-d
> 
>    Image Type:   ARM Linux Kernel Image (uncompressed)
> 
>    Data Size:    2102392 Bytes = 2 MiB
> 
>    Load Address: 80800000
> 
>    Entry Point:  80800000
> 
>    Verifying Checksum ... OK
> 
> ## Flattened Device Tree blob at 82000000
> 
>    Booting using the fdt blob at 0x82000000
> 
>    Loading Kernel Image ... OK
> 
> OK
> 
>    Loading Device Tree to 9eb7b000, end 9eb7f971 ... OK
> 
> Starting kernel ...
> 
> Uncompressing Linux... done, booting the kernel.
> 
>  
> 
> We added CONFIG_OF_LIBFDT to ast-g5.h and it allow us to get to boot with a separate DTB file (aspeed-ast2500-evb.dtb) as seen above.
> 
>  
> 
> We also tried to boot zImage, we failed with the following message (for that we added CONFIG_CMD_BOOTZ to u-boot config):
> 
>  
> 
> ast# bootz 0x83000000
> 
>  
> 
> Our initial try, we received this output:
> 
>  
> 
> Starting kernel ...
> 
> Uncompressing Linux... done, booting the kernel.
> 
> no ATAGS support: can't continue
> 
>  
> 
> Then we added CONFFIG_ATAGS to kernel config and failed with the below:
> 
>  
> 
> Starting kernel ...
> 
> Uncompressing Linux... done, booting the kernel.
> 
> Error: unrecognized/unsupported machine ID (r1 = 0x000022b8).
> 
> Available machine support:
> 
> ID (hex)        NAME
> 
> ffffffff        Generic DT based system
> 
> ffffffff        ASpeed SoC
> 
>  
> 
>  
> 
> Which u-boot command do you suggest for booting with DTB file?
> 
> How did you guys managed to boot?
> 
>  
> 
> 3. We saw in a latest updates that there is a new u-boot https://github.com/legoater/u-boot/tree/v2016.05-ast2500.
> 
> Is it stable enough for using it?

That is what use. I could not boot a openbmc kernel with the original uboot, 
probably because of how it  configured the HW. I did not investigate yet.

Cheers,

C. 

>  
> 
> Thank you guys for the great support,
> 
> Shay
> 
> 
> 
> _______________________________________________
> openbmc mailing list
> openbmc@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/openbmc
> 

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

* Re: AST2500 support questions
  2016-06-07 18:43 AST2500 support questions Shay Slobodkin
  2016-06-07 21:38 ` Rick Altherr
  2016-06-08 12:16 ` Cédric Le Goater
@ 2016-06-09  0:54 ` Patrick Williams
  2016-06-09 18:35 ` Xo Wang
  3 siblings, 0 replies; 6+ messages in thread
From: Patrick Williams @ 2016-06-09  0:54 UTC (permalink / raw)
  To: Shay Slobodkin; +Cc: openbmc

[-- Attachment #1: Type: text/plain, Size: 809 bytes --]

On Tue, Jun 07, 2016 at 06:43:13PM +0000, Shay Slobodkin wrote:
> Hi,
> 
> 3. We saw in a latest updates that there is a new u-boot https://github.com/legoater/u-boot/tree/v2016.05-ast2500.
> Is it stable enough for using it?
> 

Shay,

Like Rick said, work is going on to get all the AST2500 work upstreamed
into openbmc recipes.  There are a lot of moving parts to make that
happen and we've got a few different teams with a few different pieces
of hardware hacking on all the parts.

Cedric's repository is where he is doing some of the hacking.  You can
obviously use that if it seems to work for you.  Once the pieces
involved with supporting the AST2500 are ready you'll see the openbmc
recipes updated and they will point at an "official" openbmc-uboot tree.

-- 
Patrick Williams

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

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

* Re: AST2500 support questions
  2016-06-07 18:43 AST2500 support questions Shay Slobodkin
                   ` (2 preceding siblings ...)
  2016-06-09  0:54 ` Patrick Williams
@ 2016-06-09 18:35 ` Xo Wang
  2016-06-10  8:50   ` Joel Stanley
  3 siblings, 1 reply; 6+ messages in thread
From: Xo Wang @ 2016-06-09 18:35 UTC (permalink / raw)
  To: openbmc

Hi Shay,

Aside from confirming that AST2500 support is still a work-in-progress,
I wanted to answer your question about the current device-tree boot 
mechanism.

 > We tried to boot it with uImage and separate DTB image using the
 > command 'bootm <KERNEL_ADDR> - <DTB_ADDR>'

If I understand correctly, the configuration you tried is to load the 
DTB at 0x82000000 and pass that address to a CONFIG_OF_LIBFDT kernel in 
register r2. This should work and is probably considered the 
preferred/idiomatic ARM way, but not how the phosphor build is doing it.

 > Which u-boot command do you suggest for booting with DTB file?
 > How did you guys managed to boot?

The current OpenBMC boot mechanism for AST2400 that we ported to AST2500 
is to append the DTB to the zImage:

   # meta-phosphor/classes/kernel-cuimage.bbclass#L32
   cat linux.bin $dt > linux-dts.bin

The recipe will then run mkimage on this to create a u-boot container 
wrapped zImage+DTB file called cuImage. The kernel knows to look for the 
appended DTB if built with CONFIG_ARM_APPENDED_DTB.

 > ast# bootz 0x83000000

I think this will pass a pointer to ATAGS in r2 and bypass device-tree 
handling completely. ATAGS is considered legacy and isn't usefully 
populated by the OpenBMC u-boot, except to pass kernel boot arguments.

cheers
//xo

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

* Re: AST2500 support questions
  2016-06-09 18:35 ` Xo Wang
@ 2016-06-10  8:50   ` Joel Stanley
  0 siblings, 0 replies; 6+ messages in thread
From: Joel Stanley @ 2016-06-10  8:50 UTC (permalink / raw)
  To: Xo Wang; +Cc: OpenBMC Maillist

On Thu, Jun 9, 2016 at 1:35 PM, Xo Wang <xow@google.com> wrote:
>> We tried to boot it with uImage and separate DTB image using the
>> command 'bootm <KERNEL_ADDR> - <DTB_ADDR>'
>
> If I understand correctly, the configuration you tried is to load the DTB at
> 0x82000000 and pass that address to a CONFIG_OF_LIBFDT kernel in register
> r2. This should work and is probably considered the preferred/idiomatic ARM
> way, but not how the phosphor build is doing it.

Yep. We would prefer to do it this way, but I believe the bootm
command in the u-boot tree we're running lacks support. On the
ast2500, where we're using u-boot 2016.05, we can stop appending the
device tree to the kernel and do things this way.

I think we will hold off until we move to a common, modern u-boot for
all platforms.

Cheers,

Joel

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

end of thread, other threads:[~2016-06-10  8:50 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-07 18:43 AST2500 support questions Shay Slobodkin
2016-06-07 21:38 ` Rick Altherr
2016-06-08 12:16 ` Cédric Le Goater
2016-06-09  0:54 ` Patrick Williams
2016-06-09 18:35 ` Xo Wang
2016-06-10  8:50   ` Joel Stanley

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.