Hi George,

>
Doesn't the _OSC method tell whether the GHES is enabled on the running kernel?

The ACPI spec defines   the APEI _OSC bit as:  “This bit is set if OSPM supports the ACPI Platform Error Interfaces. “
On the _OSC implementation further platform-specific actions can be taken.


Note that the intent was to simply point out the existence of _OSC APEI, but understand if it cannot be easily leveraged.



Regards,
Jose

 

From: George Cherian <gcherian@marvell.com>
Sent: Wednesday, March 18, 2026 1:30 PM
To: Jose Marinho <Jose.Marinho@arm.com>; Jaiprakash Singh <jaiprakashs@marvell.com>; Varun Wadekar <vwadekar@nvidia.com>; tf-a@lists.trustedfirmware.org; Manish Pandey2 <Manish.Pandey2@arm.com>
Cc: Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: Re: BERT Record Erase Only After Kernel Consumes

 

Hi Jose,

 

Doesn't the _OSC method tell whether the GHES is enabled on the running kernel?

But in Jaiprakash case he would need a notification till TF-A so that he can remove the stored BERT records from the persistent storage.

 

Regards,

-George

 

 

 


From: Jose Marinho <Jose.Marinho@arm.com>
Sent: Wednesday, March 18, 2026 16:26
To: Jaiprakash Singh <jaiprakashs@marvell.com>; Varun Wadekar <vwadekar@nvidia.com>; tf-a@lists.trustedfirmware.org <tf-a@lists.trustedfirmware.org>; Manish Pandey2 <Manish.Pandey2@arm.com>
Cc: George Cherian <gcherian@marvell.com>; Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: [EXTERNAL] RE: BERT Record Erase Only After Kernel Consumes

 

Hi, > Can you share more details? How and when OSPM can share _OSC flag with firmware? I believe this may vary across operating systems. For Linux, the APEI _OSC bit is set here [1]. The actual _OSC method call happens in acpi_osc_handshake().

ZjQcmQRYFpfptBannerStart

Prioritize security for external emails:

Confirm sender and content safety before clicking links or opening attachments

 

ZjQcmQRYFpfptBannerEnd

Hi,

> Can you share more details? How and when OSPM can share _OSC flag with firmware?
I believe this may vary across operating systems.

For Linux, the APEI _OSC bit is set here [1].
The actual _OSC method call happens in acpi_osc_handshake().

On ACPI platforms, that bit just depends on CONFIG_ACPI_APEI_GHES being enabled.



Regards,
Jose


[1] https://github.com/torvalds/linux/blob/master/drivers/acpi/bus.c#L489

 

From: Jaiprakash Singh <jaiprakashs@marvell.com>
Sent: Wednesday, March 18, 2026 10:17 AM
To: Jose Marinho <Jose.Marinho@arm.com>; Varun Wadekar <vwadekar@nvidia.com>; tf-a@lists.trustedfirmware.org; Manish Pandey2 <Manish.Pandey2@arm.com>
Cc: George Cherian <gcherian@marvell.com>; Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: RE: BERT Record Erase Only After Kernel Consumes

 

Hi Jose,

 

Thanks for reply.

 

Can you share more details? How and when OSPM can share _OSC flag with firmware?

 

Thanks

 

Regards,

Jaiprakash

 

From: Jose Marinho <Jose.Marinho@arm.com>
Sent: Wednesday, March 18, 2026 2:23 PM
To: Jaiprakash Singh <jaiprakashs@marvell.com>; Varun Wadekar <vwadekar@nvidia.com>; tf-a@lists.trustedfirmware.org; Manish Pandey2 <Manish.Pandey2@arm.com>
Cc: George Cherian <gcherian@marvell.com>; Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: [EXTERNAL] RE: BERT Record Erase Only After Kernel Consumes

 

Hi Jaiprakash The OS tells firmware it will consume BERT by setting the APEI bit in the _OSC [1]. The platform firmware can propagate this signal where needed. Is this the handshake you are after? Regards, Jose [1] https://uefi.org/specs/ACPI/6.6/06_Device_Configuration.html#platform-wide-osc-capabilities-dword-2

ZjQcmQRYFpfptBannerStart

Prioritize security for external emails:

Confirm sender and content safety before clicking links or opening attachments

    Report Suspicious    ‌

ZjQcmQRYFpfptBannerEnd

Hi Jaiprakash


The OS tells firmware it will consume BERT by setting the APEI bit in the _OSC [1].
The platform firmware can propagate this signal where needed.

Is this the handshake you are after?


Regards,

Jose

[1] https://uefi.org/specs/ACPI/6.6/06_Device_Configuration.html#platform-wide-osc-capabilities-dword-2

 

From: Jaiprakash Singh via TF-A <tf-a@lists.trustedfirmware.org>
Sent: Wednesday, March 18, 2026 4:09 AM
To: Varun Wadekar <vwadekar@nvidia.com>; tf-a@lists.trustedfirmware.org; Manish Pandey2 <Manish.Pandey2@arm.com>
Cc: George Cherian <gcherian@marvell.com>; Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: [TF-A] Re: BERT Record Erase Only After Kernel Consumes

 

Hi Varun,

 

Yes, that’s possible.

 

But if firmware deletes Bert records from non-volatile memory before Kernel boots, there is a possibility

that Kernel gets crash even before it can dump bert records and bert records will be lost forever.

 

Proper solution would be – Kernel let firmware know that it has consumed bert or in some other way

firmware can confirm that Kernel is booted till prompt and now it is safe to delete all bert records.

 

Thanks

 

Regards,

Jaiprakash

 

 

From: Varun Wadekar <vwadekar@nvidia.com>
Sent: Tuesday, March 17, 2026 10:18 PM
To: Jaiprakash Singh <jaiprakashs@marvell.com>; tf-a@lists.trustedfirmware.org; Manish Pandey <manish.pandey2@arm.com>
Cc: George Cherian <gcherian@marvell.com>; Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: [EXTERNAL] Re: BERT Record Erase Only After Kernel Consumes

 

Hi, In this sequence, is it possible for firmware to delete the non-volatile memory contents after copying to GHES DRAM buffer in step 6? -Varun From: Jaiprakash Singh <jaiprakashs@marvell.com> Date: Tuesday, 17 March 2026 at 10:26 To:

ZjQcmQRYFpfptBannerStart

Prioritize security for external emails:

Confirm sender and content safety before clicking links or opening attachments

    Report Suspicious    ‌

ZjQcmQRYFpfptBannerEnd

Hi,

 

In this sequence, is it possible for firmware to delete the non-volatile memory contents after copying to GHES DRAM buffer in step 6?

 

-Varun

 

From: Jaiprakash Singh <jaiprakashs@marvell.com>
Date: Tuesday, 17 March 2026 at 10:26
To:
tf-a@lists.trustedfirmware.org <tf-a@lists.trustedfirmware.org>, Manish Pandey <manish.pandey2@arm.com>
Cc: Varun Wadekar <
vwadekar@nvidia.com>, George Cherian <gcherian@marvell.com>, Ashwin Kumar Sundararamakrishnan <asundararama@marvell.com>
Subject: BERT Record Erase Only After Kernel Consumes

You don't often get email from jaiprakashs@marvell.com. Learn why this is important

 

External email: Use caution opening links or attachments

 

Hi All,

 

BERT (Boot Error Record Table) captures errors which occurred in previous boot.

Below is the Flow with FFH (firmware first handling)

 

  1. Kernel is running
  2. Fatal error happens, which requires reboot
  3. Firmware decides to reboot system, before that capture current snapshot and save it as bert record on non-volatile memory
  4. System reboot
  5. On next boot, firmware read bert record from non-volatile memory
  6. Copy bert record to ghes dram buffer
  7. Kernel boots
  8. Kernel reads ghes dram buffer and prints bert record.

 

Problem in this flow is “When firmware should erase or delete bert records from non-volatile memory”?

 

Ideally, when Kernel has consumed Bert record after that only firmware should erase them from non-volatile memory.

But there is no communication from Kernel to firmware that it has consume bert record and now it is safe to erase them.

 

Is there already a solution for this problem available in Kernel or firmware?

Can generic SMC call from Kernel to firmware be a solution?

Any other suggestion?

 

Thanks

 

Regards,

Jaiprakash