-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Mpam ACPI and parser changes #5888
Conversation
@samimujawar - Gentle reminder on the series. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
MdePkg changes are approved
PR can not be merged due to conflict. Please rebase and resubmit |
@ZhichaoGao This patch series looks good to me. Is it possible to apply the push label, please? |
c8e9f9f
to
50be317
Compare
Hi, there was a CI failure yesterday as this patch-set introduces prototype changes for 2 widely used Parser APIs (d6f78b5 and b96f919). Anytime something gets merged upstream touching these prototypes, I would need to manual re-adapt the patch-set so that everything upstream utilizes the new prototype. The following PRs were merged after this patch-set was posted for review 3 weeks back. I have updated the patch-set now to align everything on upstream with the new prototype. Tagging @ZhichaoGao @lgao4 as well - as it introduces prototype changes, gentle request if we can get this merged before upstream moves further. Thanks! |
Add definitions, macros and types for elements associated with MPAM ACPI 2.0 specification. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Liming Gao <[email protected]> Cc: Michael D Kinney <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Zhiguang Liu <[email protected]> Acked-by: Liming Gao <[email protected]> Reviewed-by: Pierre Gondois <[email protected]> Reviewed-by: Sami Mujawar <[email protected]>
As of now, the field-validator implemented by FNPTR_FIELD_VALIDATOR function pointer takes two parameters, the pointer to the field and a context pointer. For cases where the validator has to have access to the length of the field, there is no clean way to currently do it. In order to resolve this, this commit updates the field-validator's prototype to take the length of the field as an additional parameter. This enhancement allows field validators to perform more comprehensive validation, especially when the length of the field is critical to the validation logic. This change should improve the overall robustness and flexibility of AcpiView. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Zhichao Gao <[email protected]> Reviewed-by: Sami Mujawar <[email protected]>
As of now, the print-formatter implemented by the FNPTR_PRINT_FORMATTER function pointer takes two parameters, the format string and the pointer to the field. For cases where the print-formatter has to have access to the length of the field, there is no clean way to currently do it. In order to resolve this, update the print-formatter's prototype to take the length of the field as a third parameter. This change should improve the overall robustness and flexibility of AcpiView. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Zhichao Gao <[email protected]> Reviewed-by: Sami Mujawar <[email protected]>
Certain ACPI tables like MPAM has fields which are 16 bytes long. Routines similar to Dump12Chars but for 16 characters are required to print such fields. Add Dump16Chars routine to satisfy this requirement. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Zhichao Gao <[email protected]> Reviewed-by: Pierre Gondois <[email protected]> Reviewed-by: Zhichao Gao <[email protected]> Reviewed-by: Sami Mujawar <[email protected]>
Most of the ACPI tables have fields that are marked reserved. Implement functions "DumpReserved" and "DumpReservedBits" aligning with the print-formatter prototype to print out reserved fields. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Zhichao Gao <[email protected]> Reviewed-by: Sami Mujawar <[email protected]>
Add a parser for the MPAM (Memory system resource partitioning and monitoring) ACPI table. This parser would parse all MPAM related structures embedded as part of the ACPI table. Necessary validations are also performed where and when required. Signed-off-by: Rohit Mathew <[email protected]> Cc: James Morse <[email protected]> Cc: Sami Mujawar <[email protected]> Cc: Thomas Abraham <[email protected]> Cc: Yeo Reum Yun <[email protected]> Cc: Zhichao Gao <[email protected]> Reviewed-by: Zhichao Gao <[email protected]>
a9312b1
to
0525aa8
Compare
Description
This series adds the following
An MPAM ACPI table formulated using the newly added MPAM ACPI definitions=
were
validated on the linux kernel tree at [1]. The same table was parsed via
acpiview using the newly added parser. Certain aspects of the MPAM ACPI
specification are still not implemented by the kernel tree. These aspects were
verified only using acpiview.
Changes since V1:
Changes since V2:
Changes since v3:
Changes since v4:
Changes from v5:
Addressed comments from Sami regarding Parser.
Breaking change?
This PR can cause a break in the build as it touches the code. However all the build CIs have gone through and therefore I don't anticipate build failures post merge. For boot, the scope of this PR is mostly restricted for UEFI shell. It adds a new parser for MPAM ACPI table which is relevant only when UEFI shell is up.
How This Was Tested
This PR was tested using different versions of non-mainline kernel supporting MPAM. The description of the changes detail this.
Integration Instructions
N/A