romil shah
2011-09-08 20:41:53 UTC
Hi,
Can someone explain me why EFI_MEMORY_DESCRIPTOR structure is reported as 48
bytes and not 40 bytes for x86_64 ?
typedef struct {
UINT32 Type;
EFI_PHYSICAL_ADDRESS PhysicalStart;
EFI_VIRTUAL_ADDRESS VirtualStart;
UINT64 NumberOfPages;
UINT64 Attribute;
} EFI_MEMORY_DESCRIPTOR;
According to the structure definition in the Spec and EDK2, it should be:
UINT32+4*UINT64 = 36 + 4 bytes padding = 40 bytes.
The GetMemoryMap call returns EFI_MEMORY_DESCRIPTOR size as 48 bytes instead
of 40 bytes.
Thanks,
--
Romil
Can someone explain me why EFI_MEMORY_DESCRIPTOR structure is reported as 48
bytes and not 40 bytes for x86_64 ?
typedef struct {
UINT32 Type;
EFI_PHYSICAL_ADDRESS PhysicalStart;
EFI_VIRTUAL_ADDRESS VirtualStart;
UINT64 NumberOfPages;
UINT64 Attribute;
} EFI_MEMORY_DESCRIPTOR;
According to the structure definition in the Spec and EDK2, it should be:
UINT32+4*UINT64 = 36 + 4 bytes padding = 40 bytes.
The GetMemoryMap call returns EFI_MEMORY_DESCRIPTOR size as 48 bytes instead
of 40 bytes.
Thanks,
--
Romil