OpenBMC porting to portwell pcomc660-ast2600 device.
Lior Weintraub
liorw at pliops.com
Thu May 11 20:27:25 AEST 2023
I think I have a clue what the issue is (still no solution).
I took the Linux kernel dev-6.1 from https://github.com/openbmc/linux into a separate folder and just tried to apply the Portwell patch manually:
error: patch failed: arch/arm/boot/dts/aspeed-g6.dtsi:304
error: arch/arm/boot/dts/aspeed-g6.dtsi: patch does not apply
error: patch failed: drivers/usb/host/ehci-hcd.c:634
error: drivers/usb/host/ehci-hcd.c: patch does not apply
error: patch failed: drivers/usb/host/ehci.h:218
error: drivers/usb/host/ehci.h: patch does not apply
1. I will try to find what causes these errors
2. I wonder why (maybe it is a Yocto question) there is no indication to this fail during the bitbake phase.
Cheers,
Lior.
-----Original Message-----
From: Lior Weintraub
Sent: Thursday, May 11, 2023 12:46 PM
To: Andrew Jeffery <andrew at aj.id.au>; Patrick Williams <patrick at stwcx.xyz>; Ryan Chen <ryan_chen at aspeedtech.com>
Cc: openbmc at lists.ozlabs.org
Subject: RE: OpenBMC porting to portwell pcomc660-ast2600 device.
Hi,
Portwell support helped resolving the u-boot compilation error with this modification on “meta-portwell/meta-pcomc660-ast2600/recipes-bsp/u-boot/u-boot-aspeed-sdk_2019.04.bbappend”
FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
SRCREV = "44a8c618c1215e0faac0f335f0afd56ed4240e76"
SRC_URI += "file://0001-2021-11-18-Add-PCOM-C660-AST2600-u-boot-support.patch"
SOCSEC_SIGN_ENABLE = "0"
Now there is another error:
make[1]: *** No rule to make target 'arch/arm/boot/dts/pcomc660-ast2600.dtb'. Stop.
Portwell have a patch with pcomc660-ast2600.dts so I am not sure why it was working on kernel version 5.18 and not on 6.1.
The patch is located on: https://github.com/wlbe4/openbmc/blob/portwell/meta-portwell/meta-pcomc660-ast2600/recipes-kernel/linux/linux-aspeed/0001-2021-11-18-Add-Pcom-C660-AST2600-support.patch
The linux-aspeed_git.bb file that adds this patch is located on: https://github.com/wlbe4/openbmc/blob/portwell/meta-portwell/meta-pcomc660-ast2600/recipes-kernel/linux/linux-aspeed_git.bb
I'm waiting for Portwell support but if you have an idea what can be the reason 😊
Cheers,
Lior.
-----Original Message-----
From: Lior Weintraub
Sent: Monday, April 17, 2023 9:55 AM
To: 'Andrew Jeffery' <andrew at aj.id.au>; Patrick Williams <patrick at stwcx.xyz>; Ryan Chen <ryan_chen at aspeedtech.com>
Cc: openbmc at lists.ozlabs.org
Subject: RE: OpenBMC porting to portwell pcomc660-ast2600 device.
Hi Andrew,
The AST2600 Development kit from Portwell comes with a slightly old version of OpenBMC.
The sources came as a tar.xz file and could be downloaded from: https://www.dropbox.com/s/t2nb11mkuoisj0s/PCOM-C660-AST2600_BSP_20211210.tar.xz?dl=0
What I try to do is to get the latest OpenBMC codebase and integrate meta-portwell layer from the old sources (dated from Dec. 2021).
If you take a look on the 3 last commits from https://github.com/wlbe4/openbmc/tree/portwell, you can see my migration attempt.
I have upgraded the linux-aspeed version they used (5.10.67) to 6.1.15 but left their patch as it includes the device tree for their platform.
I have removed the patch they had for u-boot-aspeed-sdk as an attempt to solve the errors I got even though I think this patch might be needed.
The current build error with u-boot-aspeed-sdk is:
build/pcomc660-ast2600/tmp/work/pcomc660_ast2600-openbmc-linux-gnueabi/u-boot-aspeed-sdk/1_v2019.04+gitAUTOINC+fd915728e1-r0/git/lib/smbios.c:84:58: error: 'U_BOOT_DMI_DATE' undeclared (first use in this function)
84 | t->bios_release_date = smbios_add_string(t->eos, U_BOOT_DMI_DATE);
Regarding the errors I had with obmc-console:
ERROR: /media/data/workspace/openbmc/openbmc-fork/meta-phosphor/recipes-phosphor/console/obmc-console_git.bb: Unable to get checksum for obmc-console SRC_URI entry obmc-console.conffile: file could not be found
Their original code included a bbappend file for the obmc-console:
FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}/:"
OBMC_CONSOLE_HOST_TTY = "ttyS0"
SRC_URI:remove = "file://${BPN}.conf"
SRC_URI:append = "file://server.ttyS0.conf"
do_install:append() {
# Remove upstream-provided configuration
rm -rf ${D}${sysconfdir}/${BPN}
# Install the server configuration
install -m 0755 -d ${D}${sysconfdir}/${BPN}
install -m 0644 ${WORKDIR}/*.conf ${D}${sysconfdir}/${BPN}/
# Remove upstream-provided server configuration
rm -f ${D}${sysconfdir}/${BPN}/server.ttyVUART0.conf
}
I suspected that their removal of "file://${BPN}.conf" wasn't welcomed by the obmc-console_git.bb recipe So I just commented it all out (except for the first line), copied the obmc-console.conf and the error was gone.
Their server.ttyS0.conf file included:
local-tty = ttyS0
baud = 115200
So I have and added the local-tty line to my obmc-console.conf copy.
I am not sure that the console will work after my changes as I currently don't have the board for testing (will arrive in 2 weeks time).
So I am currently focusing my efforts on migration and fixing the compilation errors.
Thanks for your help,
Lior.
-----Original Message-----
From: Andrew Jeffery <andrew at aj.id.au>
Sent: Monday, April 17, 2023 5:58 AM
To: Lior Weintraub <liorw at pliops.com>; Patrick Williams <patrick at stwcx.xyz>; Ryan Chen <ryan_chen at aspeedtech.com>
Cc: openbmc at lists.ozlabs.org
Subject: Re: OpenBMC porting to portwell pcomc660-ast2600 device.
CAUTION: External Sender
Hi Lior,
On Sat, 15 Apr 2023, at 20:08, Lior Weintraub wrote:
> Hi Guys,
>
> I have forked the openbmc project and opened a "portwell" branch from
> it's "master".
> The repo is under: https://github.com/wlbe4/openbmc I am trying to
> port OpenBMC into this board:
> https://portwell.com/solutions/openBMC.php
>
> My first commit to this branch was the original code of meta-portwell
> layer given to me by Portwell support (PCOM-C660-AST2600_BSP_20211210).
> The second commit tries to migrate meta-portwell layer to the latest
> Yocto syntax.
>
> Changes include (among others):
> 1. replace _append with :append
> 2. replace _prepend with :prepend
> 3. move bblayers.conf.sample, conf-notes.txt and local.conf.sample
> into templates/default folder.
> 4. Try to fix build errors on u-boot and aspeed-linux - Still there
> are errors
This doesn't give us any insight as to what the errors were. Can you provide more detail?
> 5. Try to fix obmc-console - The build errors are gone but not sure it
> will work (no platform for testing yet)
What build errors did you see?
>
> Some of the changes were just a syntax change but some requires deeper
> understanding.
> Few examples are the changes in obmc-concole, u-boot and aspeed-linux.
> Since the original version is based on older u-boot and linux kernel,
> the patches might not be relevant anymore.
>
> Can you please review the following changes on my repo:
> meta-portwell/meta-pcomc660-ast2600/recipes-phosphor/console/obmc-cons
> ole_%.bbappend
It's hard to say whether that's correct for your platform, but I don't think there's anything obviously wrong there.
> meta-portwell/meta-pcomc660-ast2600/classes/socsec-sign.bbclass
Can you unpack what were you trying to achieve by copying socsec-sign.bbclass?
> meta-portwell/meta-pcomc660-ast2600/conf/machine/pcomc660-ast2600.conf
> meta-portwell/meta-pcomc660-ast2600/recipes-bsp/u-boot/u-boot-aspeed-s
> dk_2019.04.bbappend
> meta-portwell/meta-pcomc660-ast2600/recipes-kernel/linux/linux-aspeed_
> git.bb
Have you tried building without applying patches to u-boot and linux-aspeed? It's not clear whether its your own patches that are breaking the build or if something else is afoot.
Andrew
More information about the openbmc
mailing list