<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:PMingLiU;
        panose-1:2 2 5 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:PMingLiU;
        panose-1:2 1 6 1 0 1 1 1 1 1;}
/* Style Definitions */
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"\7D14\6587\5B57 \5B57\5143";
        margin:0cm;
        font-size:12.0pt;
        font-family:"Calibri",sans-serif;}
span.a
        {mso-style-name:"\7D14\6587\5B57 \5B57\5143";
        mso-style-priority:99;
        mso-style-link:\7D14\6587\5B57;
        font-family:"Calibri",sans-serif;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="ZH-TW" link="#0563C1" vlink="#954F72" style="word-wrap:break-word;text-justify-trim:punctuation">
<div class="WordSection1">
<p class="MsoPlainText"><span lang="EN-US">Hi OpenBMC team,<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">I had identified the root cause of the problem reported by dekriea on discord [1].<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">We have a 32MB NOR flash on ast2500 EVB, which means the kernel image will be placed at offset 512 KB by default, but u-boot is trying to load kernel image from the offset 1024 KB due to the incorrect setting in evb-ast2500_defconfig.<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">The evb-ast2500_defconfig was ported from Aspeed SDK, so the partition layout is different from OpenBMC 32MB flash layout which is defined in image-type-phosphor.bbclass[2] and openbmc-flash-layout.dtsi[3].<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">So we have three solutions for this issue:<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">1. Revise the CONFIG_BOOTCOMMAND and CONFIG_ENV_OFFSET/SIZE in evb-ast2500_defconfig of u-boot v2019.04.<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">2. Add .cfg to override CONFIG_BOOTCOMMAND and CONFIG_ENV_OFFSET/SIZE in machine evb-ast2500.<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">3. Add an ast2500_openbmc_defconfig for evb-ast2500 machine which is similar to ast2600[4].<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">Which solution is the community preferred?<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">Reference:<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">[1] <a href="https://discord.com/channels/775381525260664832/922871693008068638/960822924867145728">
https://discord.com/channels/775381525260664832/922871693008068638/960822924867145728</a><o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">[2] <a href="https://github.com/openbmc/openbmc/blob/master/meta-phosphor/classes/image_types_phosphor.bbclass#L40-L52">
https://github.com/openbmc/openbmc/blob/master/meta-phosphor/classes/image_types_phosphor.bbclass#L40-L52</a><o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">[3] <a href="https://github.com/openbmc/linux/blob/dev-5.15/arch/arm/boot/dts/openbmc-flash-layout.dtsi">
https://github.com/openbmc/linux/blob/dev-5.15/arch/arm/boot/dts/openbmc-flash-layout.dtsi</a><o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">[4] <a href="https://lists.ozlabs.org/pipermail/openbmc/2022-February/029334.html">
https://lists.ozlabs.org/pipermail/openbmc/2022-February/029334.html</a><o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">B.R.<o:p></o:p></span></p>
<p class="MsoPlainText"><span lang="EN-US">Howard<o:p></o:p></span></p>
</div>
</body>
</html>