qemu/edk2/fb0f2f86fea4bfc9e3a8784e3c1ceb9eeefc174f
DynamicTablesPkg/AcpiPcctLib: Fix AddressLength range check
`AddressLength` is a `UINT64` and `MAX_UINT32` is defined as
`((UINT32)0xFFFFFFFF)`, so `~MAX_UINT32` is a 32-bit zero and
`(AddressLength & ~MAX_UINT32) == 0` is always `TRUE`.
Compare `AddressLength` directly against `MAX_UINT32` to ensure that any
length truncation caused by the `UINT32` cast to the extended PCC
subspace Address Length field is properly detected.
Signed-off-by: Ilya Somkin <onto1024b@gmail.com>
1 file changed