Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DynamicTablesPkg: Correct parser for X64 architecture objects #6490

Merged
merged 2 commits into from
Dec 11, 2024

Conversation

abdattar
Copy link
Contributor

@abdattar abdattar commented Dec 2, 2024

  • Add array size to CmArchCommonSpmiInterfaceInfoParser to correctly parse the SPMI interface object.
  • Use the size of enum values instead of fixed sizes.
  • Apply #pragma pack to the X64 object structure to ensure the total size of the structure matches the parser's combined individual field sizes without padding.

Cc: Sami Mujawar [email protected]
Cc: Pierre Gondois [email protected]

Description

Fix for ASSERT in ParseCmObjDesc() for X64 architecture.

  • Breaking change?
    • Breaking change - Does this PR cause a break in build or boot behavior?
    • Examples: Does it add a new library class or move a module to a different repo.
  • Impacts security?
    • Security - Does this PR have a direct security impact?
    • Examples: Crypto algorithm change or buffer overflow fix.
  • Includes tests?
    • Tests - Does this PR include any explicit test code?
    • Examples: Unit tests or integration tests.

How This Was Tested

Tested on AMD platform.

Integration Instructions

N/A

@samimujawar samimujawar added the push Auto push patch series in PR if all checks pass label Dec 9, 2024
@abdattar
Copy link
Contributor Author

I think its showing two commit, let me rebase it.

- Add array size to CmArchCommonSpmiInterfaceInfoParser
   to correctly parse the SPMI interface object.
- Use the size of enum values instead of fixed sizes.
- Apply #pragma pack to the X64 object structure
   to ensure the total size of the structure matches
   the parser's combined individual field sizes without padding.

Cc: Sami Mujawar <[email protected]>
Cc: Pierre Gondois <[email protected]>
Signed-off-by: Abdul Lateef Attar <[email protected]>
@mergify mergify bot merged commit 95972f9 into tianocore:master Dec 11, 2024
126 checks passed
@abdattar abdattar deleted the ParserFix branch January 20, 2025 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
push Auto push patch series in PR if all checks pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants