audk/DynamicTablesPkg/Library/Acpi/Arm/AcpiPpttLibArm
Sami Mujawar 96bb6704e0 DynamicTablesPkg: Fix Proc node length assignment
The length field for the Processor Hierarchy node structure is
8-bit wide while the number of private resource field is 32-bit
wide. Therefore, the GetProcHierarchyNodeSize() returns the size
as a 32-bit value.

The VS2017 compiler reports 'warning C4244: '=': conversion from
'UINT32' to 'UINT8', possible loss of data' while assigning the
length field of the Processor Hierarchy node structure.

To fix this, a type cast is added. In addition, there is a check
to ensure that the Processor Hierarchy node size does not exceed
MAX_UINT8.

Signed-off-by: Sami Mujawar <sami.mujawar@arm.com>
Reviewed-by: Alexei Fedorov <Alexei.Fedorov@arm.com>
2020-03-29 16:53:35 +00:00
..
AcpiPpttLibArm.inf DynamicTablesPkg: Fix missing local header warning 2020-03-29 16:53:35 +00:00
PpttGenerator.c DynamicTablesPkg: Fix Proc node length assignment 2020-03-29 16:53:35 +00:00
PpttGenerator.h DynamicTablesPkg: Add dynamic PPTT table generation support 2019-06-11 08:36:18 +01:00