mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-21 06:49:35 +00:00
types: Split aligned and packed guids
On ia64 alignment requirements are strict. When we pass a pointer to UUID it needs to be at least 4-byte aligned or EFI will crash. On the other hand in device path there is no padding for UUID, so we need 2 types in one formor another. Make 4-byte aligned and unaligned types The code is structured in a way to accept unaligned inputs in most cases and supply 4-byte aligned outputs. Efiemu case is a bit ugly because there inputs and outputs are reversed and so we need careful casts to account for this inversion. Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
1 parent
5fc985bfdd
commit
7de6fe9635
9 files changed
+54
-24
No files matched your search
@@ -1039,7 +1039,7 @@ grub_efi_find_configuration_table (const grub_guid_t *target_guid)
|
||||
|
||||
for (i = 0; i < grub_efi_system_table->num_table_entries; i++)
|
||||
{
|
||||
grub_guid_t *guid =
|
||||
grub_packed_guid_t *guid =
|
||||
&grub_efi_system_table->configuration_table[i].vendor_guid;
|
||||
|
||||
if (! grub_memcmp (guid, target_guid, sizeof (grub_guid_t)))
|
||||
|
||||
Reference in new issue
Block a user