2020-07-29 20:47:36 +08:00
|
|
|
From d49469ac1d2173db50595517e4bb8d5fe8f2a68b Mon Sep 17 00:00:00 2001
|
2019-09-30 10:52:04 -04:00
|
|
|
From: Peter Jones <pjones@redhat.com>
|
|
|
|
|
Date: Tue, 27 Feb 2018 13:55:35 -0500
|
2020-07-29 20:47:36 +08:00
|
|
|
Subject: [PATCH 094/220] align struct efi_variable better...
|
2019-09-30 10:52:04 -04:00
|
|
|
|
|
|
|
|
---
|
|
|
|
|
include/grub/efiemu/runtime.h | 2 +-
|
|
|
|
|
include/grub/types.h | 1 +
|
|
|
|
|
2 files changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
|
|
|
|
|
|
diff --git a/include/grub/efiemu/runtime.h b/include/grub/efiemu/runtime.h
|
2020-07-29 20:47:36 +08:00
|
|
|
index 36d2ded..9d93ba8 100644
|
2019-09-30 10:52:04 -04:00
|
|
|
--- a/include/grub/efiemu/runtime.h
|
|
|
|
|
+++ b/include/grub/efiemu/runtime.h
|
|
|
|
|
@@ -33,5 +33,5 @@ struct efi_variable
|
|
|
|
|
grub_uint32_t namelen;
|
|
|
|
|
grub_uint32_t size;
|
|
|
|
|
grub_efi_uint32_t attributes;
|
|
|
|
|
-} GRUB_PACKED;
|
|
|
|
|
+} GRUB_PACKED GRUB_ALIGNED(8);
|
|
|
|
|
#endif /* ! GRUB_EFI_EMU_RUNTIME_HEADER */
|
|
|
|
|
diff --git a/include/grub/types.h b/include/grub/types.h
|
2020-07-29 20:47:36 +08:00
|
|
|
index 035a4b5..2fc4be4 100644
|
2019-09-30 10:52:04 -04:00
|
|
|
--- a/include/grub/types.h
|
|
|
|
|
+++ b/include/grub/types.h
|
|
|
|
|
@@ -29,6 +29,7 @@
|
|
|
|
|
#else
|
|
|
|
|
#define GRUB_PACKED __attribute__ ((packed))
|
|
|
|
|
#endif
|
|
|
|
|
+#define GRUB_ALIGNED(x) __attribute__((aligned (x)))
|
|
|
|
|
|
|
|
|
|
#ifdef GRUB_BUILD
|
|
|
|
|
# define GRUB_CPU_SIZEOF_VOID_P BUILD_SIZEOF_VOID_P
|
2020-07-29 20:47:36 +08:00
|
|
|
--
|
|
|
|
|
1.8.3.1
|
|
|
|
|
|