From mboxrd@z Thu Jan 1 00:00:00 1970 Subject: Re: [edk2-devel] Possible [BUG] PeiCore: HOBs after cache-as-RAM teardown To: Michael Kubacki ,devel@edk2.groups.io From: "Benjamin Doron" X-Originating-Location: Richmond Hill, Ontario, CA (24.52.200.135) X-Originating-Platform: Linux Firefox 89 User-Agent: GROUPS.IO Web Poster MIME-Version: 1.0 Date: Tue, 13 Jul 2021 00:25:28 -0700 References: In-Reply-To: Message-ID: <15504.1626161128453356511@groups.io> Content-Type: multipart/alternative; boundary="Zn1Q3mXtXcXElQa5CrGv" --Zn1Q3mXtXcXElQa5CrGv Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hi Michael, I had missed the fact that the HobList pointer is updated in the entry to = PEI core when ShadowedPeiCore is NULL. It had seemed odd to me that nobody = else experienced issues, so in hindsight, that wouldn't have been the probl= em. I'm still not sure why CurrentWriteOffset is zeroed, which might imply = that the only SpiFlashDebug HOB available is the one just built ( https://g= ithub.com/tianocore/edk2-platforms/blob/master/Platform/Intel/KabylakeOpenB= oardPkg/Library/PeiSerialPortLibSpiFlash/PeiSerialPortLibSpiFlash.c#L300 ) = when I call SerialPortInitialize() again. I may have to debug this further. Regarding the test points, I guess I just assumed it would work, and witho= ut debug logs, I can't see where it would it fail. However, I'll have to as= sume that they're unrelated to this pointers-in-HOB issue. Best regards, Benjamin --Zn1Q3mXtXcXElQa5CrGv Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hi Michael,
I had missed the fact that the HobList pointer is updated = in the entry to PEI core when ShadowedPeiCore is NULL. It had seemed odd to= me that nobody else experienced issues, so in hindsight, that wouldn't hav= e been the problem. I'm still not sure why CurrentWriteOffset is zeroed, wh= ich might imply that the only SpiFlashDebug HOB avai= lable is the one just built (https://github.com/tianocore/edk2-pla= tforms/blob/master/Platform/Intel/KabylakeOpenBoardPkg/Library/PeiSerialPor= tLibSpiFlash/PeiSerialPortLibSpiFlash.c#L300) when I call SerialPortInitialize() again. I may have to debug this furt= her.

Regarding the test points, I guess I just assumed it would = work, and without debug logs, I can't see where it would it fail. However, = I'll have to assume that they're unrelated to this pointers-in-HOB issue.
Best regards,
Benjamin
--Zn1Q3mXtXcXElQa5CrGv--