RFC: ACPI code first proposal, _OSC to negotiate use of Memory Section 2 CPER.
Hi All,
In the discussion of Pierre's patch #1 the question of how a firmware could know to send the newer Memory Error Section 2 CPER rather than the older record given it currently has no way of knowing what the OS supports.
Having discussed the problem inside Qualcomm, we can to the same conclusion as in Pierre's thread - an _OSC is probably the easiest way to solve this. Andrei then drew up a code first ECN proposal. The text is below, tweaked for plain text rendering. Link to proposal #2
Please draw the attention of others to this. Feedback welcome either on this thread, Pierre's thread or directly on the tianocore ticket.
thanks,
Jonathan
# Title: OS support for CPER Memory Error Section 2 records ## Status: Draft
## Document: ACPI Specification Version 6.6
## License: SPDX-License-Identifier: CC-BY-4.0
## Submitters: Qualcomm
## Summary of the change
Reserves an additional Platform-Wide OSPM Capability bit to negotiate supported CPER record format for Memory Error Section (older MES vs newer and richer MES2). Memory Error Section 2 records are defined in UEFI 2.11, Section N.2.6 (Appendix N, page 2171).
## Benefits of the change
Memory Error Section 2 (MES2) records were added in UEFI Specification 2.11, yet no mechanism to negotiate OSPM support for the new record type (Linux kernel support is still being added upstream at the moment).
This change proposes using a new Platform-Wide OSPM Capability to negotiate between firmware and the OS for enabling the new format. Until the added _OSC bit is reported by OSPM, the older Memory Error Section records will be used. Although this means a platform may in practice have to support generating both record formats, this is seen as a better than always emitting old- and new- style records which would leave the deduplication/reconciliation up to OSPM.
## Impact of the change
Platform firmware should only generate CPER MES2 records if OSPM declared support for MES2 records. Otherwise, platform firmware should only generate the older MES records.
## Detailed description of the change [normative updates]
6.2.11.2 Platform-Wide OSPM Capabilities
…
Table 6.13: Platform-Wide _OSC Capabilities DWORD 2
+---------+--------------------------+--------------------------------------------------+ | Bits | Field Name | Definition | +---------+--------------------------+--------------------------------------------------+ | … | | | +---------+--------------------------+--------------------------------------------------+ | 22 | Functional Fixed | The OS sets this bit to indicate support for | | | Hardware | the usage of Functional FixedHardware | | | | (FFixedHW) OperationRegions. | +---------+--------------------------+--------------------------------------------------+ | 23 | CPER Memory Error | The OS sets this bit to indicate support for | | | Section 2 Support | MES2 CPER records. If not set, OS support for | | | | older CPER MES records is assumed. | +---------+--------------------------+--------------------------------------------------+ | 31:24 | | Reserved (must be 0) | +---------+--------------------------+--------------------------------------------------+
[1] https://lore.kernel.org/all/[email protected]/
[2] https://github.com/tianocore/edk2/issues/13430
Quoted 6 lines · On Fri, 30 Oct 2026 14:38:02 -0700 Jonathan Cameron…
Hi All,
In the discussion of Pierre's patch #1 the question of how a firmware could know to send the newer Memory Error Section 2 CPER rather than the older record given it currently has no way of knowing what the OS supports.
Quoted 7 lines
Having discussed the problem inside Qualcomm, we can to the same conclusion as in Pierre's thread - an
_OSCis probably the easiest way to solve this. Andrei then drew up a code first ECN proposal. The text is below, tweaked for plain text rendering. Link to proposal #2Please draw the attention of others to this. Feedback welcome either on this thread, Pierre's thread or directly on the tianocore ticket.
This sounds to be the best approach on my eyes.
Quoted 41 lines
thanks,
Jonathan
# Title: OS support for CPER Memory Error Section 2 records ## Status: Draft
## Document: ACPI Specification Version 6.6
## License: SPDX-License-Identifier: CC-BY-4.0
## Submitters: Qualcomm## Summary of the change
Reserves an additional Platform-Wide OSPM Capability bit to negotiate supported CPER record format for Memory Error Section (older MES vs newer and richer MES2). Memory Error Section 2 records are defined in UEFI 2.11, Section N.2.6 (Appendix N, page 2171).## Benefits of the change
Memory Error Section 2 (MES2) records were added in UEFI Specification 2.11, yet no mechanism to negotiate OSPM support for the new record type (Linux kernel support is still being added upstream at the moment).This change proposes using a new Platform-Wide OSPM Capability to negotiate between firmware and the OS for enabling the new format. Until the added
_OSCbit is reported by OSPM, the older Memory Error Section records will be used. Although this means a platform may in practice have to support generating both record formats, this is seen as a better than always emitting old- and new- style records which would leave the deduplication/reconciliation up to OSPM.## Impact of the change
Platform firmware should only generate CPER MES2 records if OSPM declared support for MES2 records. Otherwise, platform firmware should only generate the older MES records.## Detailed description of the change [normative updates]
6.2.11.2 Platform-Wide OSPM Capabilities
…Table 6.13: Platform-Wide
_OSCCapabilities DWORD 2
Quoted 15 lines
+---------+--------------------------+--------------------------------------------------+ | Bits | Field Name | Definition | +---------+--------------------------+--------------------------------------------------+ | … | | | +---------+--------------------------+--------------------------------------------------+ | 22 | Functional Fixed | The OS sets this bit to indicate support for | | | Hardware | the usage of Functional FixedHardware | | | | (FFixedHW) OperationRegions. | +---------+--------------------------+--------------------------------------------------+ | 23 | CPER Memory Error | The OS sets this bit to indicate support for | | | Section 2 Support | MES2 CPER records. If not set, OS support for | | | | older CPER MES records is assumed. | +---------+--------------------------+--------------------------------------------------+ | 31:24 | | Reserved (must be 0) | +---------+--------------------------+--------------------------------------------------+
My only concern is that it may run out of bits soon if we use those for each new incompatible types on CPER records.
Quoted 5 lines
[1] https://lore.kernel.org/all/[email protected]/
[2] https://github.com/tianocore/edk2/issues/13430
Thanks,
Mauro
Quoted 76 lines · On Sat, 31 Oct 2026 12:00:53 +0100 Mauro Carvalho Chehab…
Quoted 6 lines · On Fri, 30 Oct 2026 14:38:02 -0700 Jonathan Cameron…
Hi All,
In the discussion of Pierre's patch #1 the question of how a firmware could know to send the newer Memory Error Section 2 CPER rather than the older record given it currently has no way of knowing what the OS supports.
Quoted 7 lines
Having discussed the problem inside Qualcomm, we can to the same conclusion as in Pierre's thread - an
_OSCis probably the easiest way to solve this. Andrei then drew up a code first ECN proposal. The text is below, tweaked for plain text rendering. Link to proposal #2Please draw the attention of others to this. Feedback welcome either on this thread, Pierre's thread or directly on the tianocore ticket.
This sounds to be the best approach on my eyes.
Quoted 41 lines
thanks,
Jonathan
# Title: OS support for CPER Memory Error Section 2 records ## Status: Draft
## Document: ACPI Specification Version 6.6
## License: SPDX-License-Identifier: CC-BY-4.0
## Submitters: Qualcomm## Summary of the change
Reserves an additional Platform-Wide OSPM Capability bit to negotiate supported CPER record format for Memory Error Section (older MES vs newer and richer MES2). Memory Error Section 2 records are defined in UEFI 2.11, Section N.2.6 (Appendix N, page 2171).## Benefits of the change
Memory Error Section 2 (MES2) records were added in UEFI Specification 2.11, yet no mechanism to negotiate OSPM support for the new record type (Linux kernel support is still being added upstream at the moment).This change proposes using a new Platform-Wide OSPM Capability to negotiate between firmware and the OS for enabling the new format. Until the added
_OSCbit is reported by OSPM, the older Memory Error Section records will be used. Although this means a platform may in practice have to support generating both record formats, this is seen as a better than always emitting old- and new- style records which would leave the deduplication/reconciliation up to OSPM.## Impact of the change
Platform firmware should only generate CPER MES2 records if OSPM declared support for MES2 records. Otherwise, platform firmware should only generate the older MES records.## Detailed description of the change [normative updates]
6.2.11.2 Platform-Wide OSPM Capabilities
…Table 6.13: Platform-Wide
_OSCCapabilities DWORD 2Quoted 15 lines
+---------+--------------------------+--------------------------------------------------+ | Bits | Field Name | Definition | +---------+--------------------------+--------------------------------------------------+ | … | | | +---------+--------------------------+--------------------------------------------------+ | 22 | Functional Fixed | The OS sets this bit to indicate support for | | | Hardware | the usage of Functional FixedHardware | | | | (FFixedHW) OperationRegions. | +---------+--------------------------+--------------------------------------------------+ | 23 | CPER Memory Error | The OS sets this bit to indicate support for | | | Section 2 Support | MES2 CPER records. If not set, OS support for | | | | older CPER MES records is assumed. | +---------+--------------------------+--------------------------------------------------+ | 31:24 | | Reserved (must be 0) | +---------+--------------------------+--------------------------------------------------+
Quoted 2 lines
My only concern is that it may run out of bits soon if we use those for each new incompatible types on CPER records.
I had the same concern. Not sure we need to agree it on the code first side of this proposal (as doesn't really affect implementation) but perhaps it makes sense to have a separate OSC for RAS features. Alternative is that we end up with a top level _OSC number 2 when we run out of bits.
Jonathan
Quoted 11 lines
Quoted 6 lines
[1] https://lore.kernel.org/all/[email protected]/
[2] https://github.com/tianocore/edk2/issues/13430Thanks,
Mauro
Quoted 82 lines · On Mon, 2 Nov 2026 09:00:16 -0800 Jonathan Cameron…
Quoted 76 lines · On Sat, 31 Oct 2026 12:00:53 +0100 Mauro Carvalho Chehab…
Quoted 6 lines · On Fri, 30 Oct 2026 14:38:02 -0700 Jonathan Cameron…
Hi All,
In the discussion of Pierre's patch #1 the question of how a firmware could know to send the newer Memory Error Section 2 CPER rather than the older record given it currently has no way of knowing what the OS supports.
Quoted 7 lines
Having discussed the problem inside Qualcomm, we can to the same conclusion as in Pierre's thread - an
_OSCis probably the easiest way to solve this. Andrei then drew up a code first ECN proposal. The text is below, tweaked for plain text rendering. Link to proposal #2Please draw the attention of others to this. Feedback welcome either on this thread, Pierre's thread or directly on the tianocore ticket.
This sounds to be the best approach on my eyes.
Quoted 41 lines
thanks,
Jonathan
# Title: OS support for CPER Memory Error Section 2 records ## Status: Draft
## Document: ACPI Specification Version 6.6
## License: SPDX-License-Identifier: CC-BY-4.0
## Submitters: Qualcomm## Summary of the change
Reserves an additional Platform-Wide OSPM Capability bit to negotiate supported CPER record format for Memory Error Section (older MES vs newer and richer MES2). Memory Error Section 2 records are defined in UEFI 2.11, Section N.2.6 (Appendix N, page 2171).## Benefits of the change
Memory Error Section 2 (MES2) records were added in UEFI Specification 2.11, yet no mechanism to negotiate OSPM support for the new record type (Linux kernel support is still being added upstream at the moment).This change proposes using a new Platform-Wide OSPM Capability to negotiate between firmware and the OS for enabling the new format. Until the added
_OSCbit is reported by OSPM, the older Memory Error Section records will be used. Although this means a platform may in practice have to support generating both record formats, this is seen as a better than always emitting old- and new- style records which would leave the deduplication/reconciliation up to OSPM.## Impact of the change
Platform firmware should only generate CPER MES2 records if OSPM declared support for MES2 records. Otherwise, platform firmware should only generate the older MES records.## Detailed description of the change [normative updates]
6.2.11.2 Platform-Wide OSPM Capabilities
…Table 6.13: Platform-Wide
_OSCCapabilities DWORD 2Quoted 15 lines
+---------+--------------------------+--------------------------------------------------+ | Bits | Field Name | Definition | +---------+--------------------------+--------------------------------------------------+ | … | | | +---------+--------------------------+--------------------------------------------------+ | 22 | Functional Fixed | The OS sets this bit to indicate support for | | | Hardware | the usage of Functional FixedHardware | | | | (FFixedHW) OperationRegions. | +---------+--------------------------+--------------------------------------------------+ | 23 | CPER Memory Error | The OS sets this bit to indicate support for | | | Section 2 Support | MES2 CPER records. If not set, OS support for | | | | older CPER MES records is assumed. | +---------+--------------------------+--------------------------------------------------+ | 31:24 | | Reserved (must be 0) | +---------+--------------------------+--------------------------------------------------+Quoted 2 lines
My only concern is that it may run out of bits soon if we use those for each new incompatible types on CPER records.
Quoted 6 lines
I had the same concern. Not sure we need to agree it on the code first side of this proposal (as doesn't really affect implementation) but perhaps it makes sense to have a separate OSC for RAS features. Alternative is that we end up with a top level
_OSCnumber 2 when we run out of bits.Jonathan
Seems we need to move to a highter bit. The plan is currently to keep it in this DWORD though as easy enough to add more DWORDs as needed.
If anyone has additional feedback please reply to this thread or the github issue in the next week as we'd like to move this forward.
If anyone plans to look at this and wants more time, let me know and we can slow things down to allow for that!
thanks,
Jonathan
Quoted 14 lines
Quoted 13 lines
Quoted 8 lines
[1] https://lore.kernel.org/all/[email protected]/
[2] https://github.com/tianocore/edk2/issues/13430Thanks,
Mauro