Skip to content

fix-acpipatcher-oemtableid-comparison - #855

Merged
chris1111 merged 2 commits into
CloverHackyColor:masterfrom
YBronst:master
Oct 25, 2026
Merged

chris1111 merged 2 commits into
CloverHackyColor:masterfrom
YBronst:master

Conversation

@YBronst

@YBronst YBronst commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

Description

Fix OemTableId comparison and RSDT index calculation in AcpiPatcher
Authored-by: Jules jules@agent.ai

Summary of Fixes in AcpiPatcher.cpp

  • Symmetrical OemTableId Comparison: In DropTableFromRSDT and DropTableFromXSDT, OemTableId_NoSpace is now applied symmetrically to both sides of the comparison:

    OemTableId_NoSpace(Table->OemTableId) == OemTableId_NoSpace(TableId)

    This ensures that ACPI tables with trailing spaces in their OEM Table IDs (e.g. "A M I ") match correctly against TableId values configured in config.plist.

  • Correct Index Pointer Calculation in DropTableFromRSDT: Replaced IndexFromXsdtEntryPtr(Ptr) with IndexFromRsdtEntryPtr(Ptr) inside DropTableFromRSDT. Since RSDT uses 32-bit (UINT32) entry pointers while XSDT uses 64-bit (UINT64) pointers, using IndexFromRsdtEntryPtr calculates the correct array index offset for RSDT entries.


All changes have been verified and are ready to be merged!

Type of change

  • Bugfix
  • New functionality
  • Code improvements
  • Documentation update

Checklist

  • Tested my changes locally
  • Added relevant comments to the code
  • Updated the relevant documentation

Additional information

Include any extra details relevant to your PR.

Applied symmetric OemTableId_NoSpace comparison to both Table->OemTableId
and TableId in DropTableFromRSDT and DropTableFromXSDT. Fixed RSDT entry
index macro usage in DropTableFromRSDT.

Authored-by: Jules <jules@agent.ai>
Fix OemTableId comparison and RSDT index calculation in AcpiPatcher
Authored-by: Jules jules@agent.ai
@chris1111
chris1111 merged commit 85f46f3 into CloverHackyColor:master Oct 25, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants