July 4, 2021
FIO
Allocating Memory Above 2GB Some UEFI implementations, notably those based on IP from AMI, have a limitation on the amount of memory available for allocation via the gBS->AllocatePool and gBS->AllocatePages(AllocateAnyAddress, ...) APIs. Specifically they won't allow allocation of any memory above about 2GB, regardless of allocation size. Furthermore, some implementations (such as on the ASUS Z170) appear to have a catastrophic failure whereby if a module causes the system to run out of memory under 2GB the system subsequently becomes unbootable and must be recovered using the ASUS Flashback feature, or RMA'd. On other AMI-based systems, the system just locks up and can be successfully rebooted (ASUS Z97), while some others fail the request and return NULL.
Read more