mirror of
https://git.proxmox.com/git/grub2
synced 2025-08-07 08:46:21 +00:00
Backport another patch on top of efifwsetup to fix a build failure in grub-core/kern/efi/efi.c.
This commit is contained in:
parent
6c18452532
commit
f7766ed83a
54
debian/patches/efifwsetup.patch
vendored
54
debian/patches/efifwsetup.patch
vendored
@ -1,9 +1,10 @@
|
|||||||
Description: Add efifwsetup module to reboot into firmware setup menu
|
Description: Add efifwsetup module to reboot into firmware setup menu
|
||||||
Author: Peter Jones <pjones@redhat.com>
|
Author: Peter Jones <pjones@redhat.com>
|
||||||
Origin: upstream, http://bazaar.launchpad.net/~vcs-imports/grub/grub2-bzr/revision/4575
|
Origin: upstream, http://bazaar.launchpad.net/~vcs-imports/grub/grub2-bzr/revision/4575
|
||||||
|
Origin: upstream, http://bazaar.launchpad.net/~vcs-imports/grub/grub2-bzr/revision/4579
|
||||||
Forwarded: not-needed
|
Forwarded: not-needed
|
||||||
Applied-Upstream: http://bazaar.launchpad.net/~vcs-imports/grub/grub2-bzr/revision/4575
|
Applied-Upstream: http://bazaar.launchpad.net/~vcs-imports/grub/grub2-bzr/revision/4575
|
||||||
Last-Update: 2012-09-18
|
Last-Update: 2012-09-19
|
||||||
|
|
||||||
Index: b/grub-core/Makefile.core.def
|
Index: b/grub-core/Makefile.core.def
|
||||||
===================================================================
|
===================================================================
|
||||||
@ -117,6 +118,48 @@ Index: b/grub-core/commands/efi/efifwsetup.c
|
|||||||
+ if (cmd)
|
+ if (cmd)
|
||||||
+ grub_unregister_command (cmd);
|
+ grub_unregister_command (cmd);
|
||||||
+}
|
+}
|
||||||
|
Index: b/grub-core/efiemu/runtime/efiemu.c
|
||||||
|
===================================================================
|
||||||
|
--- a/grub-core/efiemu/runtime/efiemu.c
|
||||||
|
+++ b/grub-core/efiemu/runtime/efiemu.c
|
||||||
|
@@ -78,7 +78,7 @@
|
||||||
|
|
||||||
|
grub_efi_status_t
|
||||||
|
efiemu_set_variable (grub_efi_char16_t *variable_name,
|
||||||
|
- grub_efi_guid_t *vendor_guid,
|
||||||
|
+ const grub_efi_guid_t *vendor_guid,
|
||||||
|
grub_efi_uint32_t attributes,
|
||||||
|
grub_efi_uintn_t data_size,
|
||||||
|
void *data);
|
||||||
|
@@ -131,11 +131,11 @@
|
||||||
|
|
||||||
|
/* Some standard functions because we need to be standalone */
|
||||||
|
static void
|
||||||
|
-efiemu_memcpy (void *to, void *from, int count)
|
||||||
|
+efiemu_memcpy (void *to, const void *from, int count)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
for (i = 0; i < count; i++)
|
||||||
|
- ((grub_uint8_t *) to)[i] = ((grub_uint8_t *) from)[i];
|
||||||
|
+ ((grub_uint8_t *) to)[i] = ((const grub_uint8_t *) from)[i];
|
||||||
|
}
|
||||||
|
|
||||||
|
static int
|
||||||
|
@@ -503,10 +503,10 @@
|
||||||
|
|
||||||
|
grub_efi_status_t
|
||||||
|
EFI_FUNC (efiemu_set_variable) (grub_efi_char16_t *variable_name,
|
||||||
|
- grub_efi_guid_t *vendor_guid,
|
||||||
|
- grub_efi_uint32_t attributes,
|
||||||
|
- grub_efi_uintn_t data_size,
|
||||||
|
- void *data)
|
||||||
|
+ const grub_efi_guid_t *vendor_guid,
|
||||||
|
+ grub_efi_uint32_t attributes,
|
||||||
|
+ grub_efi_uintn_t data_size,
|
||||||
|
+ void *data)
|
||||||
|
{
|
||||||
|
struct efi_variable *efivar;
|
||||||
|
grub_uint8_t *ptr;
|
||||||
Index: b/grub-core/kern/efi/efi.c
|
Index: b/grub-core/kern/efi/efi.c
|
||||||
===================================================================
|
===================================================================
|
||||||
--- a/grub-core/kern/efi/efi.c
|
--- a/grub-core/kern/efi/efi.c
|
||||||
@ -171,6 +214,15 @@ Index: b/include/grub/efi/api.h
|
|||||||
#define GRUB_EFI_VARIABLE_NON_VOLATILE 0x0000000000000001
|
#define GRUB_EFI_VARIABLE_NON_VOLATILE 0x0000000000000001
|
||||||
#define GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS 0x0000000000000002
|
#define GRUB_EFI_VARIABLE_BOOTSERVICE_ACCESS 0x0000000000000002
|
||||||
#define GRUB_EFI_VARIABLE_RUNTIME_ACCESS 0x0000000000000004
|
#define GRUB_EFI_VARIABLE_RUNTIME_ACCESS 0x0000000000000004
|
||||||
|
@@ -1066,7 +1068,7 @@
|
||||||
|
|
||||||
|
grub_efi_status_t
|
||||||
|
(*set_variable) (grub_efi_char16_t *variable_name,
|
||||||
|
- grub_efi_guid_t *vendor_guid,
|
||||||
|
+ const grub_efi_guid_t *vendor_guid,
|
||||||
|
grub_efi_uint32_t attributes,
|
||||||
|
grub_efi_uintn_t data_size,
|
||||||
|
void *data);
|
||||||
Index: b/include/grub/efi/efi.h
|
Index: b/include/grub/efi/efi.h
|
||||||
===================================================================
|
===================================================================
|
||||||
--- a/include/grub/efi/efi.h
|
--- a/include/grub/efi/efi.h
|
||||||
|
@ -78,7 +78,7 @@ efiemu_get_next_variable_name (grub_efi_uintn_t *variable_name_size,
|
|||||||
|
|
||||||
grub_efi_status_t
|
grub_efi_status_t
|
||||||
efiemu_set_variable (grub_efi_char16_t *variable_name,
|
efiemu_set_variable (grub_efi_char16_t *variable_name,
|
||||||
grub_efi_guid_t *vendor_guid,
|
const grub_efi_guid_t *vendor_guid,
|
||||||
grub_efi_uint32_t attributes,
|
grub_efi_uint32_t attributes,
|
||||||
grub_efi_uintn_t data_size,
|
grub_efi_uintn_t data_size,
|
||||||
void *data);
|
void *data);
|
||||||
@ -131,11 +131,11 @@ extern grub_uint32_t efiemu_time_accuracy;
|
|||||||
|
|
||||||
/* Some standard functions because we need to be standalone */
|
/* Some standard functions because we need to be standalone */
|
||||||
static void
|
static void
|
||||||
efiemu_memcpy (void *to, void *from, int count)
|
efiemu_memcpy (void *to, const void *from, int count)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
for (i = 0; i < count; i++)
|
for (i = 0; i < count; i++)
|
||||||
((grub_uint8_t *) to)[i] = ((grub_uint8_t *) from)[i];
|
((grub_uint8_t *) to)[i] = ((const grub_uint8_t *) from)[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
@ -503,10 +503,10 @@ grub_efi_status_t EFI_FUNC
|
|||||||
|
|
||||||
grub_efi_status_t
|
grub_efi_status_t
|
||||||
EFI_FUNC (efiemu_set_variable) (grub_efi_char16_t *variable_name,
|
EFI_FUNC (efiemu_set_variable) (grub_efi_char16_t *variable_name,
|
||||||
grub_efi_guid_t *vendor_guid,
|
const grub_efi_guid_t *vendor_guid,
|
||||||
grub_efi_uint32_t attributes,
|
grub_efi_uint32_t attributes,
|
||||||
grub_efi_uintn_t data_size,
|
grub_efi_uintn_t data_size,
|
||||||
void *data)
|
void *data)
|
||||||
{
|
{
|
||||||
struct efi_variable *efivar;
|
struct efi_variable *efivar;
|
||||||
grub_uint8_t *ptr;
|
grub_uint8_t *ptr;
|
||||||
|
@ -1068,7 +1068,7 @@ struct grub_efi_runtime_services
|
|||||||
|
|
||||||
grub_efi_status_t
|
grub_efi_status_t
|
||||||
(*set_variable) (grub_efi_char16_t *variable_name,
|
(*set_variable) (grub_efi_char16_t *variable_name,
|
||||||
grub_efi_guid_t *vendor_guid,
|
const grub_efi_guid_t *vendor_guid,
|
||||||
grub_efi_uint32_t attributes,
|
grub_efi_uint32_t attributes,
|
||||||
grub_efi_uintn_t data_size,
|
grub_efi_uintn_t data_size,
|
||||||
void *data);
|
void *data);
|
||||||
|
Loading…
Reference in New Issue
Block a user