Pull TPM updates from mjg59.

Resolves: rhbz#1318067

Signed-off-by: Peter Jones <pjones@redhat.com>
This commit is contained in:
Peter Jones 2016-04-05 15:28:47 -04:00
parent dcaf8f6883
commit 0ac23e2378
99 changed files with 1376 additions and 888 deletions

View File

@ -1,28 +0,0 @@
From bf4d21655b4331c9f01e0ccca30a736e0503ce71 Mon Sep 17 00:00:00 2001
From: Gustavo Luiz Duarte <gustavold@linux.vnet.ibm.com>
Date: Tue, 25 Sep 2012 18:40:55 -0400
Subject: [PATCH 01/85] Fix crash on http
Don't free file->data on receiving FIN flag since it is used all over without
checking. http_close() will be called later to free that memory.
https://bugzilla.redhat.com/show_bug.cgi?id=860834
---
grub-core/net/http.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/net/http.c b/grub-core/net/http.c
index 4684f8b..ef9538c 100644
--- a/grub-core/net/http.c
+++ b/grub-core/net/http.c
@@ -393,7 +393,7 @@ http_establish (struct grub_file *file, grub_off_t offset, int initial)
data->sock = grub_net_tcp_open (file->device->net->server,
HTTP_PORT, http_receive,
- http_err, http_err,
+ http_err, NULL,
file);
if (!data->sock)
{
--
2.5.0

View File

@ -1,7 +1,7 @@
From 93a6fae012cadae03cbf81ebf82ae17894026e2c Mon Sep 17 00:00:00 2001
From ea9eb6e9fb40a19264fc453778087e7e5fec24fa Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Thu, 20 Sep 2012 18:07:39 -0300
Subject: [PATCH 07/85] IBM client architecture (CAS) reboot support
Subject: [PATCH 01/88] IBM client architecture (CAS) reboot support
This is an implementation of IBM client architecture (CAS) reboot for GRUB.
@ -25,10 +25,10 @@ parameters
4 files changed, 90 insertions(+)
diff --git a/grub-core/kern/ieee1275/openfw.c b/grub-core/kern/ieee1275/openfw.c
index 5c12157..81276fa 100644
index ddb7783..6db8b98 100644
--- a/grub-core/kern/ieee1275/openfw.c
+++ b/grub-core/kern/ieee1275/openfw.c
@@ -591,3 +591,65 @@ grub_ieee1275_canonicalise_devname (const char *path)
@@ -561,3 +561,65 @@ grub_ieee1275_canonicalise_devname (const char *path)
return NULL;
}
@ -157,7 +157,7 @@ index a8502d9..ab78ca8 100644
{
char *line;
diff --git a/include/grub/ieee1275/ieee1275.h b/include/grub/ieee1275/ieee1275.h
index 6d4e7d5..6a21f5d 100644
index 8e42513..9f26c69 100644
--- a/include/grub/ieee1275/ieee1275.h
+++ b/include/grub/ieee1275/ieee1275.h
@@ -234,6 +234,8 @@ int EXPORT_FUNC(grub_ieee1275_devalias_next) (struct grub_ieee1275_devalias *ali
@ -166,9 +166,9 @@ index 6d4e7d5..6a21f5d 100644
struct grub_ieee1275_devalias *alias);
+int EXPORT_FUNC(grub_ieee1275_cas_reboot) (char *script);
+int EXPORT_FUNC(grub_ieee1275_set_boot_last_label) (const char *text);
int EXPORT_FUNC(grub_ieee1275_parse_net_options) (const char *path);
#define FOR_IEEE1275_DEVALIASES(alias) for (grub_ieee1275_devalias_init_iterator (&(alias)); grub_ieee1275_devalias_next (&(alias));)
--
2.5.0
2.5.5

View File

@ -1,16 +1,21 @@
From 297d32d320c94cdea94d8be4d06e6c574a5221f3 Mon Sep 17 00:00:00 2001
From 6c2b5d14fe79a8e0eefabef4b711133b5ce02c94 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Wed, 24 Apr 2013 10:51:48 -0300
Subject: [PATCH 08/85] for ppc, reset console display attr when clear screen
Subject: [PATCH 02/88] for ppc, reset console display attr when clear screen
v2: Also use \x0c instead of a literal ^L to make future patches less
awkward.
This should fix this bugzilla:
https://bugzilla.redhat.com/show_bug.cgi?id=908519
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/term/terminfo.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/term/terminfo.c b/grub-core/term/terminfo.c
index f0d3e3d..7cb7909 100644
index f0d3e3d..9bb75c1 100644
--- a/grub-core/term/terminfo.c
+++ b/grub-core/term/terminfo.c
@@ -151,7 +151,7 @@ grub_terminfo_set_current (struct grub_term_output *term,
@ -18,10 +23,10 @@ index f0d3e3d..7cb7909 100644
* ANSI escape sequence. Using video console, Apple Open Firmware
* (version 3.1.1) only recognizes the literal ^L. So use both. */
- data->cls = grub_strdup (" \e[2J");
+ data->cls = grub_strdup (" \e[2J\e[m");
+ data->cls = grub_strdup ("\x0c\e[2J\e[m");
data->reverse_video_on = grub_strdup ("\e[7m");
data->reverse_video_off = grub_strdup ("\e[m");
if (grub_strcmp ("ieee1275", str) == 0)
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 0ca5375206e061c0229301c19d1311f8b0499c11 Mon Sep 17 00:00:00 2001
From 4b4bbc963438157b29fec6b38b6567e16d1e2e56 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Tue, 11 Jun 2013 15:14:05 -0300
Subject: [PATCH 09/85] Disable GRUB video support for IBM power machines
Subject: [PATCH 03/88] Disable GRUB video support for IBM power machines
Should fix the problem in bugzilla:
https://bugzilla.redhat.com/show_bug.cgi?id=973205
@ -48,7 +48,7 @@ index 0b150ec..813ab38 100644
GRUB_MOD_FINI(ieee1275_fb)
diff --git a/include/grub/ieee1275/ieee1275.h b/include/grub/ieee1275/ieee1275.h
index 6a21f5d..663935d 100644
index 9f26c69..ab4f284 100644
--- a/include/grub/ieee1275/ieee1275.h
+++ b/include/grub/ieee1275/ieee1275.h
@@ -146,6 +146,8 @@ enum grub_ieee1275_flag
@ -61,5 +61,5 @@ index 6a21f5d..663935d 100644
extern int EXPORT_FUNC(grub_ieee1275_test_flag) (enum grub_ieee1275_flag flag);
--
2.5.0
2.5.5

View File

@ -1,28 +0,0 @@
From eaa05aa39e24bff667f48310871f64f367a78e3b Mon Sep 17 00:00:00 2001
From: Robert Marshall <rmarshall@redhat.com>
Date: Fri, 29 Jan 2016 14:49:24 -0500
Subject: [PATCH 03/85] Failed config now returns exit code (#1252311)
Grub would notify the user if the new config was invalid, however, it
did not exit properly with exit code 1. Added the proper exit code.
Resolves: rhbz#1252311
---
util/grub-mkconfig.in | 1 +
1 file changed, 1 insertion(+)
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
index 203b076..f8496d2 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
@@ -273,6 +273,7 @@ Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
%s file attached." "${grub_cfg}.new" >&2
echo >&2
+ exit 1
else
# none of the children aborted with error, install the new grub.cfg
mv -f ${grub_cfg}.new ${grub_cfg}
--
2.5.0

View File

@ -1,7 +1,7 @@
From e0bb91aa1752a0a2bc3c4b0bdc4c49430b470ebc Mon Sep 17 00:00:00 2001
From 668d1227194fc45d19dec7c90b4d004378c822af Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 7 Jul 2015 10:13:14 -0400
Subject: [PATCH 14/85] Fix bzr's ignore artificats in .gitignore
Subject: [PATCH 04/88] Fix bzr's ignore artificats in .gitignore
We lost a man page because of incompatibilities between bzr's ignore
system and .gitignore, so solve that slightly better.
@ -367,5 +367,5 @@ index 18ab8e8..06c9f3a 100644
-/grub-fs-tester
+xzcompress_test
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 7401bf6fb1f319f6f910391f57680e9794678878 Mon Sep 17 00:00:00 2001
From 3be0a8cb87161ffb64ef9e94cf893e228a84f630 Mon Sep 17 00:00:00 2001
From: Marcel Kolaja <mkolaja@redhat.com>
Date: Tue, 21 Jan 2014 10:57:08 -0500
Subject: [PATCH 18/85] Honor a symlink when generating configuration by
Subject: [PATCH 05/88] Honor a symlink when generating configuration by
grub2-mkconfig
Honor a symlink when generating configuration by grub2-mkconfig, so that
@ -25,5 +25,5 @@ index f8496d2..3b070fd 100644
fi
--
2.5.0
2.5.5

View File

@ -0,0 +1,55 @@
From 3dca3dbb01a52fdc90f548a2461c8fc8e04336ab Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 3 Apr 2013 14:35:34 -0400
Subject: [PATCH 06/88] Move bash completion script (#922997)
Apparently these go in a new place now.
---
configure.ac | 11 +++++++++++
util/bash-completion.d/Makefile.am | 1 -
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 57e1713..21023ae 100644
--- a/configure.ac
+++ b/configure.ac
@@ -287,6 +287,14 @@ AC_SUBST(grubdirname)
AC_DEFINE_UNQUOTED(GRUB_DIR_NAME, "$grubdirname",
[Default grub directory name])
+PKG_PROG_PKG_CONFIG
+AS_IF([$($PKG_CONFIG --exists bash-completion)], [
+ bashcompletiondir=$($PKG_CONFIG --variable=completionsdir bash-completion)
+] , [
+ bashcompletiondir=${datadir}/bash-completion/completions
+])
+AC_SUBST(bashcompletiondir)
+
#
# Checks for build programs.
#
@@ -475,6 +483,9 @@ HOST_CFLAGS="$HOST_CFLAGS $grub_cv_cc_w_extra_flags"
# Check for target programs.
#
+# This makes sure pkg.m4 is available.
+m4_pattern_forbid([^_?PKG_[A-Z_]+$],[*** pkg.m4 missing, please install pkg-config])
+
# Find tools for the target.
if test "x$target_alias" != x && test "x$host_alias" != "x$target_alias"; then
tmp_ac_tool_prefix="$ac_tool_prefix"
diff --git a/util/bash-completion.d/Makefile.am b/util/bash-completion.d/Makefile.am
index 136287c..61108f0 100644
--- a/util/bash-completion.d/Makefile.am
+++ b/util/bash-completion.d/Makefile.am
@@ -6,7 +6,6 @@ EXTRA_DIST = $(bash_completion_source)
CLEANFILES = $(bash_completion_script) config.log
-bashcompletiondir = $(sysconfdir)/bash_completion.d
bashcompletion_DATA = $(bash_completion_script)
$(bash_completion_script): $(bash_completion_source) $(top_builddir)/config.status
--
2.5.5

View File

@ -1,7 +1,7 @@
From 78b35097d8647b555deb8ece7ef141587529923d Mon Sep 17 00:00:00 2001
From fcbba25979fc9e26ab8e6eed5c84668a5f134b12 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 4 Dec 2014 15:36:09 -0500
Subject: [PATCH 02/85] Update to minilzo-2.08
Subject: [PATCH 07/88] Update to minilzo-2.08
This fixes CVE-2014-4607 - lzo: lzo1x_decompress_safe() integer overflow
@ -8786,5 +8786,5 @@ index 74fefa9..7937454 100644
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From beee9fcaeb35cf95c6bcf272034d691235542121 Mon Sep 17 00:00:00 2001
From 99745ca3450dbbd364569a13b61fbf2a36cb3a88 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Tue, 30 Oct 2012 15:19:39 -0200
Subject: [PATCH 06/85] Add vlan-tag support on IBM PPC machines
Subject: [PATCH 08/88] Add vlan-tag support on IBM PPC machines
This patch adds support for virtual LAN (VLAN) tagging. VLAN tagging allows
multiple VLANs in a bridged network to share the same physical network link but
@ -32,7 +32,7 @@ index 1259022..5fa26e1 100644
ptr = canon + grub_strlen (canon) - 1;
while (ptr > canon && (*ptr == ',' || *ptr == ':'))
diff --git a/grub-core/kern/ieee1275/openfw.c b/grub-core/kern/ieee1275/openfw.c
index ddb7783..5c12157 100644
index 6db8b98..81276fa 100644
--- a/grub-core/kern/ieee1275/openfw.c
+++ b/grub-core/kern/ieee1275/openfw.c
@@ -23,6 +23,7 @@
@ -159,22 +159,22 @@ index c397b1b..faaca67 100644
return err;
diff --git a/include/grub/ieee1275/ieee1275.h b/include/grub/ieee1275/ieee1275.h
index 8e42513..6d4e7d5 100644
index ab4f284..663935d 100644
--- a/include/grub/ieee1275/ieee1275.h
+++ b/include/grub/ieee1275/ieee1275.h
@@ -234,6 +234,7 @@ int EXPORT_FUNC(grub_ieee1275_devalias_next) (struct grub_ieee1275_devalias *ali
void EXPORT_FUNC(grub_ieee1275_children_peer) (struct grub_ieee1275_devalias *alias);
void EXPORT_FUNC(grub_ieee1275_children_first) (const char *devpath,
@@ -238,6 +238,7 @@ void EXPORT_FUNC(grub_ieee1275_children_first) (const char *devpath,
struct grub_ieee1275_devalias *alias);
int EXPORT_FUNC(grub_ieee1275_cas_reboot) (char *script);
int EXPORT_FUNC(grub_ieee1275_set_boot_last_label) (const char *text);
+int EXPORT_FUNC(grub_ieee1275_parse_net_options) (const char *path);
#define FOR_IEEE1275_DEVALIASES(alias) for (grub_ieee1275_devalias_init_iterator (&(alias)); grub_ieee1275_devalias_next (&(alias));)
diff --git a/include/grub/net.h b/include/grub/net.h
index 4dc066a..96aa9fa 100644
index 2192fa1..6ac9d72 100644
--- a/include/grub/net.h
+++ b/include/grub/net.h
@@ -563,4 +563,6 @@ extern char *grub_net_default_server;
@@ -561,4 +561,6 @@ extern char *grub_net_default_server;
#define GRUB_NET_INTERVAL 400
#define GRUB_NET_INTERVAL_ADDITION 20
@ -182,5 +182,5 @@ index 4dc066a..96aa9fa 100644
+
#endif /* ! GRUB_NET_HEADER */
--
2.5.0
2.5.5

View File

@ -1,21 +1,21 @@
From bc5d351596ec8d95b837e23f9775db6d8bd7fd29 Mon Sep 17 00:00:00 2001
From 10da6e0e6bf723e99332fb1c34e6355a98bbb83f Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 5 Sep 2014 10:07:04 -0400
Subject: [PATCH 17/85] Allow "fallback" to include entries by title, not just
Subject: [PATCH 09/88] Allow "fallback" to include entries by title, not just
number.
Resolves: rhbz#1026084
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/normal/menu.c | 76 +++++++++++++++++++++++++++++++------------------
1 file changed, 49 insertions(+), 27 deletions(-)
grub-core/normal/menu.c | 85 +++++++++++++++++++++++++++++++++----------------
1 file changed, 58 insertions(+), 27 deletions(-)
diff --git a/grub-core/normal/menu.c b/grub-core/normal/menu.c
index cd15f04..73a94aa 100644
index 719e2fb..2e8a7bd 100644
--- a/grub-core/normal/menu.c
+++ b/grub-core/normal/menu.c
@@ -163,12 +163,35 @@ grub_menu_set_timeout (int timeout)
@@ -163,16 +163,41 @@ grub_menu_set_timeout (int timeout)
}
}
@ -28,7 +28,7 @@ index cd15f04..73a94aa 100644
+ while (1)
+ {
+ if (*ptr2 == '>' && ptr2[1] != '>' && *ptr1 == 0)
+ return 1;
+ return ptr2 - spec;
+ if (*ptr2 == '>' && ptr2[1] != '>')
+ return 0;
+ if (*ptr2 == '>')
@ -36,10 +36,11 @@ index cd15f04..73a94aa 100644
+ if (*ptr1 != *ptr2)
+ return 0;
+ if (*ptr1 == 0)
+ return 1;
+ return ptr1 - id;
+ ptr1++;
+ ptr2++;
+ }
+ return 0;
+}
+
/* Get the first entry number from the value of the environment variable NAME,
@ -52,7 +53,12 @@ index cd15f04..73a94aa 100644
{
const char *val;
char *tail;
@@ -182,9 +205,32 @@ get_and_remove_first_entry_number (const char *name)
int entry;
+ int sz = 0;
val = grub_env_get (name);
if (! val)
@@ -182,9 +207,39 @@ get_and_remove_first_entry_number (const char *name)
entry = (int) grub_strtoul (val, &tail, 0);
@ -62,12 +68,13 @@ index cd15f04..73a94aa 100644
+ grub_menu_entry_t e = menu->entry_list;
+ int i;
+
+ grub_errno = GRUB_ERR_NONE;
+
+ for (i = 0; e; i++)
+ {
+ if (menuentry_eq (e->title, val)
+ || menuentry_eq (e->id, val))
+ sz = menuentry_eq (e->title, val);
+ if (sz < 1)
+ sz = menuentry_eq (e->id, val);
+
+ if (sz >= 1)
+ {
+ entry = i;
+ break;
@ -75,6 +82,9 @@ index cd15f04..73a94aa 100644
+ e = e->next;
+ }
+
+ if (sz > 0)
+ grub_errno = GRUB_ERR_NONE;
+
+ if (! e)
+ entry = -1;
+ }
@ -82,11 +92,14 @@ index cd15f04..73a94aa 100644
if (grub_errno == GRUB_ERR_NONE)
{
- /* Skip whitespace to find the next digit. */
+ if (sz > 0)
+ tail += sz;
+
+ /* Skip whitespace to find the next entry. */
while (*tail && grub_isspace (*tail))
tail++;
grub_env_set (name, tail);
@@ -347,7 +393,7 @@ grub_menu_execute_with_fallback (grub_menu_t menu,
@@ -347,7 +402,7 @@ grub_menu_execute_with_fallback (grub_menu_t menu,
grub_menu_execute_entry (entry, 1);
/* Deal with fallback entries. */
@ -95,7 +108,7 @@ index cd15f04..73a94aa 100644
>= 0)
{
grub_print_error ();
@@ -465,30 +511,6 @@ grub_menu_register_viewer (struct grub_menu_viewer *viewer)
@@ -465,30 +520,6 @@ grub_menu_register_viewer (struct grub_menu_viewer *viewer)
viewers = viewer;
}
@ -127,5 +140,5 @@ index cd15f04..73a94aa 100644
static int
get_entry_number (grub_menu_t menu, const char *name)
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 73545c78c604559e2af231f1b526265ba15c3839 Mon Sep 17 00:00:00 2001
From c13e60be8ff3c4b1c2ba0a1aebd4b09f8ec7dbc0 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 4 Sep 2014 16:49:25 -0400
Subject: [PATCH 20/85] Add GRUB_DISABLE_UUID.
Subject: [PATCH 10/88] Add GRUB_DISABLE_UUID.
This will cause "search --fs-uuid --set=root ..." not to be generated by
grub2-mkconfig, and instead simply attempt to use the grub device name
@ -95,5 +95,5 @@ index 60b31ca..cf35e41 100644
else
echo $device |sed 's, ,_,g'
--
2.5.0
2.5.5

View File

@ -1,50 +0,0 @@
From 2f3c6669c5f8d0255e6103508eb71667d8dec158 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <matthew.garrett@nebula.com>
Date: Wed, 12 Jun 2013 11:51:49 -0400
Subject: [PATCH 10/85] Add support for UEFI operating systems returned by
os-prober
os-prober returns UEFI operating systems in the form:
path:long-name:name
where path is the path under the EFI directory on the ESP. This is in
contrast to legacy OSes, where path is the device string. Handle this case.
---
util/grub.d/30_os-prober.in | 21 ++++++++++++++++++---
1 file changed, 18 insertions(+), 3 deletions(-)
diff --git a/util/grub.d/30_os-prober.in b/util/grub.d/30_os-prober.in
index 515a68c..9b8f596 100644
--- a/util/grub.d/30_os-prober.in
+++ b/util/grub.d/30_os-prober.in
@@ -328,8 +328,23 @@ EOF
EOF
;;
*)
- # TRANSLATORS: %s is replaced by OS name.
- gettext_printf "%s is not yet supported by grub-mkconfig.\n" " ${LONGNAME}" >&2
- ;;
+ case ${DEVICE} in
+ *.efi)
+ cat << EOF
+menuentry '$(echo "${LONGNAME}" | grub_quote)' {
+EOF
+ save_default_entry | grub_add_tab
+ cat << EOF
+ chainloader /EFI/${DEVICE}
+ boot
+}
+EOF
+ ;;
+ *)
+ echo -n " "
+ # TRANSLATORS: %s is replaced by OS name.
+ gettext_printf "%s is not yet supported by grub-mkconfig.\n" "${LONGNAME}" >&2
+ ;;
+ esac
esac
done
--
2.5.0

View File

@ -1,7 +1,7 @@
From 1f1a695cc6dedd19ecb7ff50c66a8f57d50e362b Mon Sep 17 00:00:00 2001
From 898b245564f15fbbe02692423d40e1dad08f60ad Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 26 Feb 2014 21:49:12 -0500
Subject: [PATCH 12/85] Make "exit" take a return code.
Subject: [PATCH 11/88] Make "exit" take a return code.
This adds "exit" with a return code. With this patch, any "exit"
command /may/ include a return code, and on platforms that support
@ -12,6 +12,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/commands/minicmd.c | 20 ++++++++++++++++----
grub-core/kern/efi/efi.c | 9 +++++++--
grub-core/kern/emu/main.c | 2 +-
grub-core/kern/emu/misc.c | 5 +++--
grub-core/kern/i386/coreboot/init.c | 2 +-
grub-core/kern/i386/qemu/init.c | 2 +-
@ -23,7 +24,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
grub-core/kern/uboot/init.c | 6 +++---
grub-core/kern/xen/init.c | 2 +-
include/grub/misc.h | 2 +-
13 files changed, 38 insertions(+), 20 deletions(-)
14 files changed, 39 insertions(+), 21 deletions(-)
diff --git a/grub-core/commands/minicmd.c b/grub-core/commands/minicmd.c
index a3a1182..b25ca4b 100644
@ -81,6 +82,19 @@ index caf9bcc..101307f 100644
for (;;) ;
}
diff --git a/grub-core/kern/emu/main.c b/grub-core/kern/emu/main.c
index f91280f..34634d3 100644
--- a/grub-core/kern/emu/main.c
+++ b/grub-core/kern/emu/main.c
@@ -66,7 +66,7 @@ grub_reboot (void)
}
void
-grub_exit (void)
+grub_exit (int retval __attribute__((unused)))
{
grub_reboot ();
}
diff --git a/grub-core/kern/emu/misc.c b/grub-core/kern/emu/misc.c
index d361feb..331fa62 100644
--- a/grub-core/kern/emu/misc.c
@ -241,5 +255,5 @@ index 2a9f87c..0620814 100644
grub_uint64_t d,
grub_uint64_t *r);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From cb62c40cb96d103e5675dc25ca17a38226e91305 Mon Sep 17 00:00:00 2001
From db6df67d0aca17b1ebf6a73dc21cc09ec44c2187 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 22 Jul 2015 11:21:01 -0400
Subject: [PATCH 13/85] Mark po/exclude.pot as binary so git won't try to diff
Subject: [PATCH 12/88] Mark po/exclude.pot as binary so git won't try to diff
nonprintables.
Signed-off-by: Peter Jones <pjones@redhat.com>
@ -18,5 +18,5 @@ index 0000000..33ffaa4
@@ -0,0 +1 @@
+po/exclude.pot binary
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 05f2dc34ddf1bd0ce75edfedfa68236c51165350 Mon Sep 17 00:00:00 2001
From 09d7e9f1a0bfbbdcf816c0165a95b2fee6a0297e Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 7 Dec 2015 14:20:49 -0500
Subject: [PATCH 11/85] Make efi machines load an env block from a variable
Subject: [PATCH 13/88] Make efi machines load an env block from a variable
Signed-off-by: Peter Jones <pjones@redhat.com>
---
@ -80,5 +80,5 @@ index e9c85de..a5b6c1d 100644
char **path);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 836b528eed2671f3014f4d0983377ca69dc0fec1 Mon Sep 17 00:00:00 2001
From 9a13b0203bf45cdc961bbc6bdcce763aec289038 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Tue, 27 Nov 2012 17:18:53 -0200
Subject: [PATCH 04/85] DHCP client ID and UUID options added.
Subject: [PATCH 14/88] DHCP client ID and UUID options added.
---
grub-core/net/bootp.c | 87 ++++++++++++++++++++++++++++++++++++++++++++++-----
@ -9,7 +9,7 @@ Subject: [PATCH 04/85] DHCP client ID and UUID options added.
2 files changed, 81 insertions(+), 8 deletions(-)
diff --git a/grub-core/net/bootp.c b/grub-core/net/bootp.c
index a088244..4532177 100644
index 189551a..a9c8f47 100644
--- a/grub-core/net/bootp.c
+++ b/grub-core/net/bootp.c
@@ -25,6 +25,49 @@
@ -112,7 +112,7 @@ index a088244..4532177 100644
/* If you need any other options please contact GRUB
development team. */
}
@@ -295,14 +374,6 @@ grub_net_process_dhcp (struct grub_net_buff *nb,
@@ -298,14 +377,6 @@ grub_net_process_dhcp (struct grub_net_buff *nb,
}
}
@ -128,7 +128,7 @@ index a088244..4532177 100644
grub_cmd_dhcpopt (struct grub_command *cmd __attribute__ ((unused)),
int argc, char **args)
diff --git a/include/grub/net.h b/include/grub/net.h
index 2192fa1..4dc066a 100644
index 6ac9d72..96aa9fa 100644
--- a/include/grub/net.h
+++ b/include/grub/net.h
@@ -456,6 +456,8 @@ enum
@ -141,5 +141,5 @@ index 2192fa1..4dc066a 100644
};
--
2.5.0
2.5.5

View File

@ -1,80 +0,0 @@
From ecaecc9bc12a86a64bffeb64879c621da10d5136 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 7 Jul 2015 12:04:28 -0400
Subject: [PATCH 15/85] Add some __unused__ where gcc 5.x is more picky about
it.
With some build flags, gcc 5.x throws more warnings about __unused__ not
being present than older compilers did. This patch adds the annotation.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/gettext/gettext.c | 10 +++++-----
grub-core/normal/menu.c | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/grub-core/gettext/gettext.c b/grub-core/gettext/gettext.c
index 4880cef..1b1986f 100644
--- a/grub-core/gettext/gettext.c
+++ b/grub-core/gettext/gettext.c
@@ -434,7 +434,7 @@ static char *
grub_gettext_env_write_lang (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, val, grub_env_get ("locale_dir"),
grub_env_get ("prefix"));
if (err)
@@ -451,7 +451,7 @@ grub_gettext_env_write_lang (struct grub_env_var *var
void
grub_gettext_reread_prefix (const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, grub_env_get ("lang"),
grub_env_get ("locale_dir"),
val);
@@ -463,7 +463,7 @@ static char *
read_main (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, grub_env_get ("lang"), val,
grub_env_get ("prefix"));
if (err)
@@ -475,7 +475,7 @@ static char *
read_secondary (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&secondary_context, grub_env_get ("lang"), val,
0);
if (err)
@@ -500,7 +500,7 @@ grub_cmd_translate (grub_command_t cmd __attribute__ ((unused)),
GRUB_MOD_INIT (gettext)
{
const char *lang;
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
lang = grub_env_get ("lang");
diff --git a/grub-core/normal/menu.c b/grub-core/normal/menu.c
index 719e2fb..cd15f04 100644
--- a/grub-core/normal/menu.c
+++ b/grub-core/normal/menu.c
@@ -807,7 +807,7 @@ run_menu (grub_menu_t menu, int nested, int *auto_boot)
/* Callback invoked immediately before a menu entry is executed. */
static void
-notify_booting (grub_menu_entry_t entry,
+notify_booting (grub_menu_entry_t __attribute__((unused)) entry,
void *userdata __attribute__((unused)))
{
grub_printf (" ");
--
2.5.0

View File

@ -1,7 +1,7 @@
From eb1adf51b18aaa62078bddf91439ca054b6f7965 Mon Sep 17 00:00:00 2001
From 03011792061af809b53023bb4458627af80f0b8f Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Wed, 5 Feb 2014 09:42:42 -0200
Subject: [PATCH 05/85] trim arp packets with abnormal size
Subject: [PATCH 15/88] trim arp packets with abnormal size
GRUB uses arp request to create the arp response. If the incoming packet
is foobared, GRUB needs to trim the arp response packet before sending it.
@ -27,5 +27,5 @@ index 4b68c41..f7c59d3 100644
struct grub_net_buff nb_reply;
struct arppkt *arp_reply;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 5212412d2c54f112cb68aa5dfc4711abdec9ce94 Mon Sep 17 00:00:00 2001
From ff07352c36d9d307428f55881d951f0513af40fa Mon Sep 17 00:00:00 2001
From: Prarit Bhargava <prarit@redhat.com>
Date: Wed, 12 Mar 2014 10:58:16 -0400
Subject: [PATCH 19/85] Fix bad test on GRUB_DISABLE_SUBMENU.
Subject: [PATCH 16/88] Fix bad test on GRUB_DISABLE_SUBMENU.
The file /etc/grub.d/10_linux does
@ -20,7 +20,7 @@ Resolves: rhbz#1063414
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 5a78513..6f835b7 100644
index de9044c..cf6331f 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -224,7 +224,11 @@ while [ "x$list" != "x" ] ; do
@ -37,5 +37,5 @@ index 5a78513..6f835b7 100644
"${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
--
2.5.0
2.5.5

View File

@ -1,26 +0,0 @@
From e704140ffbdc0bbe0cf9ddc66f1ffe51018078ae Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 3 Apr 2013 14:35:34 -0400
Subject: [PATCH 16/85] Move bash completion script (#922997)
Apparently these go in a new place now.
---
util/bash-completion.d/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/bash-completion.d/Makefile.am b/util/bash-completion.d/Makefile.am
index 136287c..0bcdb06 100644
--- a/util/bash-completion.d/Makefile.am
+++ b/util/bash-completion.d/Makefile.am
@@ -6,7 +6,7 @@ EXTRA_DIST = $(bash_completion_source)
CLEANFILES = $(bash_completion_script) config.log
-bashcompletiondir = $(sysconfdir)/bash_completion.d
+bashcompletiondir = $(datarootdir)/bash-completion/completions
bashcompletion_DATA = $(bash_completion_script)
$(bash_completion_script): $(bash_completion_source) $(top_builddir)/config.status
--
2.5.0

View File

@ -1,7 +1,7 @@
From c6addd5bf471e6596f6c180a8d83a31df59c6d69 Mon Sep 17 00:00:00 2001
From 672a3f12ad7f52da6e03e2dc361cfe6ef1b4e52b Mon Sep 17 00:00:00 2001
From: Mark Hamzy <hamzy@us.ibm.com>
Date: Wed, 28 Mar 2012 14:46:41 -0500
Subject: [PATCH 22/85] Migrate PPC from Yaboot to Grub2
Subject: [PATCH 17/88] Migrate PPC from Yaboot to Grub2
Add configuration support for serial terminal consoles. This will set the
maximum screen size so that text is not overwritten.
@ -12,7 +12,7 @@ maximum screen size so that text is not overwritten.
create mode 100644 util/grub.d/20_ppc_terminfo.in
diff --git a/Makefile.util.def b/Makefile.util.def
index ed9b4c6..dfd48fc 100644
index f9caccb..6d452da 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -487,6 +487,13 @@ script = {
@ -150,5 +150,5 @@ index 0000000..10d6658
+ terminfo -g ${X}x${Y} ${TERMINAL}
+EOF
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a0c5493ead025948d40154dde08cb8504a1c840c Mon Sep 17 00:00:00 2001
From 88c7ba4163340b2652f9009b65d850625588b6a9 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Wed, 19 Sep 2012 21:22:55 -0300
Subject: [PATCH 23/85] Add fw_path variable (revised)
Subject: [PATCH 18/88] Add fw_path variable (revised)
This patch makes grub look for its config file on efi where the app was
found. It was originally written by Matthew Garrett, and adapted to fix the
@ -77,5 +77,5 @@ index 249e19b..759c475 100644
prefix = grub_env_get ("prefix");
if (prefix)
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From e7f9069fb31f0b112d7cd56872253287ab8c99a5 Mon Sep 17 00:00:00 2001
From b1ce49059c27b9d2f35ced805acd09d867954a5e Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg@redhat.com>
Date: Tue, 10 Jul 2012 11:58:52 -0400
Subject: [PATCH 24/85] Add support for linuxefi
Subject: [PATCH 19/88] Add support for linuxefi
---
grub-core/Makefile.core.def | 8 +
@ -478,5 +478,5 @@ index da0ca3b..fc36bda 100644
/* Boot parameters for Linux based on 2.6.12. This is used by the setup
--
2.5.0
2.5.5

View File

@ -1,14 +1,14 @@
From 8c186e1142ec99ecde320a673cb72cbbcaa98936 Mon Sep 17 00:00:00 2001
From fa62e2f81abb3a06357cc48a1f983bd2579b7a28 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 16 Jul 2012 18:57:11 -0400
Subject: [PATCH 25/85] Use "linuxefi" and "initrdefi" where appropriate.
Subject: [PATCH 20/88] Use "linuxefi" and "initrdefi" where appropriate.
---
util/grub.d/10_linux.in | 18 ++++++++++++++++--
1 file changed, 16 insertions(+), 2 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 6f835b7..c41a9ca 100644
index cf6331f..8ccf012 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -129,17 +129,31 @@ linux_entry ()
@ -46,5 +46,5 @@ index 6f835b7..c41a9ca 100644
sed "s/^/$submenu_indentation/" << EOF
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From b231f595542985cba4fb6c079e0d1ee82fc5983c Mon Sep 17 00:00:00 2001
From ad7ed5502c54e6979dbc77604e14afc637c34abe Mon Sep 17 00:00:00 2001
From: Colin Watson <cjwatson@ubuntu.com>
Date: Tue, 23 Oct 2012 10:40:49 -0400
Subject: [PATCH 26/85] Don't allow insmod when secure boot is enabled.
Subject: [PATCH 21/88] Don't allow insmod when secure boot is enabled.
Hi,
@ -113,5 +113,5 @@ index 9a2da0e..2245632 100644
EXPORT_FUNC (grub_efi_compare_device_paths) (const grub_efi_device_path_t *dp1,
const grub_efi_device_path_t *dp2);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From ed9658a2d5f703e68e098b19726ef162e6c755b7 Mon Sep 17 00:00:00 2001
From 5645686a740bfa3689a139bf1131e0330054d09f Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 1 Oct 2012 13:24:37 -0400
Subject: [PATCH 27/85] Pass "\x[[:hex:]][[:hex:]]" straight through
Subject: [PATCH 22/88] Pass "\x[[:hex:]][[:hex:]]" straight through
unmolested.
---
@ -179,5 +179,5 @@ index ab78ca8..cf6cd66 100644
case '$':
if (escaped)
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 356b0c4cb947c5f7983cfe8a4cc1e89e8118f4c2 Mon Sep 17 00:00:00 2001
From 4cf5e2dd84a0842bf20d5371ec8b9f6b38562458 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Tue, 27 Nov 2012 16:58:39 -0200
Subject: [PATCH 21/85] Add %X option to printf functions.
Subject: [PATCH 23/88] Add %X option to printf functions.
---
grub-core/kern/misc.c | 7 +++++--
@ -54,5 +54,5 @@ index 6bb0351..81be344 100644
case 'd':
{
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a4b155fe619747aeb5eac12ca02d3cec83532756 Mon Sep 17 00:00:00 2001
From 48251724559eba74c10106007edb373a9a9261e5 Mon Sep 17 00:00:00 2001
From: Paulo Flabiano Smorigo <pfsmorigo@br.ibm.com>
Date: Tue, 27 Nov 2012 17:22:07 -0200
Subject: [PATCH 28/85] Search for specific config file for netboot
Subject: [PATCH 24/88] Search for specific config file for netboot
This patch implements a search for a specific configuration when the config
file is on a remoteserver. It uses the following order:
@ -199,5 +199,5 @@ index 96aa9fa..e13ae1e 100644
+
#endif /* ! GRUB_NET_HEADER */
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 14812d576121fdc90b05ede5d1f30075b4ab2396 Mon Sep 17 00:00:00 2001
From fbc0fcdfd649c1c053be735311ca15deea7a40ff Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Tue, 22 Jan 2013 06:31:38 +0100
Subject: [PATCH 29/85] blscfg: add blscfg module to parse Boot Loader
Subject: [PATCH 25/88] blscfg: add blscfg module to parse Boot Loader
Specification snippets
http://www.freedesktop.org/wiki/Specifications/BootLoaderSpec
@ -247,5 +247,5 @@ index 0000000..4274aca
+ grub_unregister_extcmd (cmd);
+}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 83a711aa32c98578a9a38c71eef6659fe4cc90a7 Mon Sep 17 00:00:00 2001
From 0b4548eb7f9c6f9d5b2ca5650f404a55bc3c0e9b Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Wed, 15 May 2013 13:30:20 -0400
Subject: [PATCH 30/85] Don't write messages to the screen
Subject: [PATCH 26/88] Don't write messages to the screen
Writing messages to the screen before the menus or boot splash
happens so quickly it looks like something is wrong and isn't
@ -9,10 +9,10 @@ very appealing.
---
grub-core/boot/i386/pc/boot.S | 3 ---
grub-core/boot/i386/pc/diskboot.S | 5 -----
grub-core/gettext/gettext.c | 15 ---------------
grub-core/gettext/gettext.c | 25 +++++--------------------
grub-core/kern/main.c | 5 -----
util/grub.d/10_linux.in | 7 -------
5 files changed, 35 deletions(-)
5 files changed, 5 insertions(+), 40 deletions(-)
diff --git a/grub-core/boot/i386/pc/boot.S b/grub-core/boot/i386/pc/boot.S
index 2bd0b2d..ea167fe 100644
@ -45,11 +45,15 @@ index 1ee4cf5..c8b87ed 100644
movw $LOCAL(firstlist), %di
diff --git a/grub-core/gettext/gettext.c b/grub-core/gettext/gettext.c
index 1b1986f..b22e1bc 100644
index 4880cef..b22e1bc 100644
--- a/grub-core/gettext/gettext.c
+++ b/grub-core/gettext/gettext.c
@@ -437,13 +437,9 @@ grub_gettext_env_write_lang (struct grub_env_var *var
grub_err_t __attribute__((__unused__)) err;
@@ -434,16 +434,12 @@ static char *
grub_gettext_env_write_lang (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, val, grub_env_get ("locale_dir"),
grub_env_get ("prefix"));
- if (err)
@ -62,7 +66,12 @@ index 1b1986f..b22e1bc 100644
return grub_strdup (val);
}
@@ -455,8 +451,6 @@ grub_gettext_reread_prefix (const char *val)
@@ -451,23 +447,19 @@ grub_gettext_env_write_lang (struct grub_env_var *var
void
grub_gettext_reread_prefix (const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, grub_env_get ("lang"),
grub_env_get ("locale_dir"),
val);
@ -71,8 +80,11 @@ index 1b1986f..b22e1bc 100644
}
static char *
@@ -466,8 +460,6 @@ read_main (struct grub_env_var *var
grub_err_t __attribute__((__unused__)) err;
read_main (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&main_context, grub_env_get ("lang"), val,
grub_env_get ("prefix"));
- if (err)
@ -80,8 +92,12 @@ index 1b1986f..b22e1bc 100644
return grub_strdup (val);
}
@@ -478,9 +470,6 @@ read_secondary (struct grub_env_var *var
grub_err_t __attribute__((__unused__)) err;
@@ -475,12 +467,9 @@ static char *
read_secondary (struct grub_env_var *var
__attribute__ ((unused)), const char *val)
{
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
err = grub_gettext_init_ext (&secondary_context, grub_env_get ("lang"), val,
0);
- if (err)
@ -90,7 +106,14 @@ index 1b1986f..b22e1bc 100644
return grub_strdup (val);
}
@@ -506,12 +495,8 @@ GRUB_MOD_INIT (gettext)
@@ -500,18 +489,14 @@ grub_cmd_translate (grub_command_t cmd __attribute__ ((unused)),
GRUB_MOD_INIT (gettext)
{
const char *lang;
- grub_err_t err;
+ grub_err_t __attribute__((__unused__)) err;
lang = grub_env_get ("lang");
err = grub_gettext_init_ext (&main_context, lang, grub_env_get ("locale_dir"),
grub_env_get ("prefix"));
@ -120,7 +143,7 @@ index 8ab7794..da47b18 100644
grub_boot_time ("Before loading embedded modules.");
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index c41a9ca..74f5f29 100644
index 8ccf012..a3d9711 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -128,29 +128,22 @@ linux_entry ()
@ -154,5 +177,5 @@ index c41a9ca..74f5f29 100644
EOF
fi
--
2.5.0
2.5.5

View File

@ -0,0 +1,45 @@
From 2f50942631fb6cc004ee527831eaab37803e379e Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Wed, 15 May 2013 13:53:48 -0400
Subject: [PATCH 27/88] Don't print GNU GRUB header
No one cares.
---
grub-core/normal/main.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index b2654ef..f57b750 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -202,15 +202,16 @@ read_config_file (const char *config)
/* Initialize the screen. */
void
grub_normal_init_page (struct grub_term_output *term,
- int y)
+ int y __attribute__((__unused__)))
{
+ grub_term_cls (term);
+
+#if 0
grub_ssize_t msg_len;
int posx;
char *msg_formatted;
grub_uint32_t *unicode_msg;
grub_uint32_t *last_position;
-
- grub_term_cls (term);
msg_formatted = grub_xasprintf (_("GNU GRUB version %s"), PACKAGE_VERSION);
if (!msg_formatted)
@@ -235,6 +236,7 @@ grub_normal_init_page (struct grub_term_output *term,
grub_putcode ('\n', term);
grub_putcode ('\n', term);
grub_free (unicode_msg);
+#endif
}
static void
--
2.5.5

View File

@ -1,7 +1,7 @@
From b8293967f7455f70a3f586f5583d7a9e5cc6772c Mon Sep 17 00:00:00 2001
From fc2611a52df05b340939f26787a2a2357b9e233f Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Wed, 15 May 2013 17:49:45 -0400
Subject: [PATCH 32/85] Don't add '*' to highlighted row
Subject: [PATCH 28/88] Don't add '*' to highlighted row
It is already highlighted.
---
@ -22,5 +22,5 @@ index e22bb91..a3d1f23 100644
grub_print_ucs4_menu (unicode_title,
unicode_title + len,
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 6b0f11d8c752b5a7b5030e2cd19ba3b78b7dd901 Mon Sep 17 00:00:00 2001
From 960e7ed921ae6ce005d621fa251a77c2d1fc799d Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 11:09:04 -0400
Subject: [PATCH 33/85] Message string cleanups
Subject: [PATCH 29/88] Message string cleanups
Make use of terminology consistent. Remove jargon.
---
@ -67,5 +67,5 @@ index a3d1f23..64a8386 100644
{
grub_print_error ();
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a31995777db4d7603e0cd901a4a643812e023f51 Mon Sep 17 00:00:00 2001
From 469c9b26660bf04751c0d53c302fb43693399447 Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 14:08:23 -0400
Subject: [PATCH 34/85] Fix border spacing now that we aren't displaying it
Subject: [PATCH 30/88] Fix border spacing now that we aren't displaying it
---
grub-core/normal/menu_text.c | 6 +++---
@ -28,5 +28,5 @@ index 64a8386..1062d64 100644
geo->timeout_lines = 2;
--
2.5.0
2.5.5

View File

@ -1,33 +0,0 @@
From 4a5b10c4083c9b99aed2e98577e7634b74c250d9 Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Wed, 15 May 2013 13:53:48 -0400
Subject: [PATCH 31/85] Don't print GNU GRUB header
No one cares.
---
grub-core/normal/main.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index b2654ef..3af349d 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -212,6 +212,7 @@ grub_normal_init_page (struct grub_term_output *term,
grub_term_cls (term);
+#if 0
msg_formatted = grub_xasprintf (_("GNU GRUB version %s"), PACKAGE_VERSION);
if (!msg_formatted)
return;
@@ -235,6 +236,7 @@ grub_normal_init_page (struct grub_term_output *term,
grub_putcode ('\n', term);
grub_putcode ('\n', term);
grub_free (unicode_msg);
+#endif
}
static void
--
2.5.0

View File

@ -1,7 +1,7 @@
From 2a01b399c5c73096ae372eb1f342b8a0f8f47030 Mon Sep 17 00:00:00 2001
From bc50b0f8f8e15860ba13c71d373f7456993832fe Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 14:08:49 -0400
Subject: [PATCH 35/85] Use the correct indentation for the term help text
Subject: [PATCH 31/88] Use the correct indentation for the term help text
That is consistent with the menu help text
---
@ -9,7 +9,7 @@ That is consistent with the menu help text
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index 3af349d..d98e868 100644
index f57b750..0ce59fd 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -426,8 +426,8 @@ grub_normal_reader_init (int nested)
@ -24,5 +24,5 @@ index 3af349d..d98e868 100644
grub_print_message_indented (msg_formatted, 0, 0, term);
grub_putcode ('\n', term);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From f670c1c2e4a55188b3654aaac307e20a6c896796 Mon Sep 17 00:00:00 2001
From e7da891c287928fec2e88db06073485ce84b39ef Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 14:30:55 -0400
Subject: [PATCH 36/85] Indent menu entries
Subject: [PATCH 32/88] Indent menu entries
---
grub-core/normal/menu_text.c | 3 ++-
@ -22,5 +22,5 @@ index 1062d64..ecc60f9 100644
grub_print_ucs4_menu (unicode_title,
unicode_title + len,
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 397d978c51b6ac1db63e05de786334ceb6a40636 Mon Sep 17 00:00:00 2001
From 40b049c635b0ebd9d98010facbbeb668e8cb90a7 Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 14:59:36 -0400
Subject: [PATCH 37/85] Fix margins
Subject: [PATCH 33/88] Fix margins
---
grub-core/normal/menu_text.c | 8 +++-----
@ -33,5 +33,5 @@ index ecc60f9..0e43f2c 100644
- geo->timeout_lines /* timeout */
- 1 /* empty final line */;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From b5566d5a3ee9ada0c397102bd51887c7e0d7305f Mon Sep 17 00:00:00 2001
From a7358954fc6bbcadadc3c6421bed25eb10c53815 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 21 Jun 2013 14:44:08 -0400
Subject: [PATCH 38/85] Use -2 instead of -1 for our right-hand margin, so
Subject: [PATCH 34/88] Use -2 instead of -1 for our right-hand margin, so
linewrapping works (#976643).
Signed-off-by: Peter Jones <grub2-owner@fedoraproject.org>
@ -23,5 +23,5 @@ index 0e43f2c..537d4bf 100644
geo->first_entry_y = 3; /* three empty lines*/
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 2366e7d0b5915ca44930a682258a0a913269befc Mon Sep 17 00:00:00 2001
From 6de3939ead9a9d895f708bf445b36ddf4eef67f4 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 28 Oct 2013 10:05:07 -0400
Subject: [PATCH 39/85] Use linux16 when appropriate (#880840)
Subject: [PATCH 35/88] Use linux16 when appropriate (#880840)
The kernel group really would prefer that we use the 16 bit entry point
on x86 bios machines.
@ -14,7 +14,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 74f5f29..5b49dcb 100644
index a3d9711..f3bf6ac 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -76,6 +76,11 @@ linux_entry ()
@ -48,5 +48,5 @@ index 74f5f29..5b49dcb 100644
fi
fi
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 0c2e9a7c6f7f781542d3a94a5fc9b0b8ce435cd2 Mon Sep 17 00:00:00 2001
From c821c54717446a38213d4c440207728877e06758 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 28 Oct 2013 10:09:27 -0400
Subject: [PATCH 40/85] Enable pager by default. (#985860)
Subject: [PATCH 36/88] Enable pager by default. (#985860)
Signed-off-by: Peter Jones <pjones@redhat.com>
---
@ -22,5 +22,5 @@ index 93a9023..858b526 100644
load_env
fi
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 9cbaea1b39567552e4e103cb35a7c18fdc36395a Mon Sep 17 00:00:00 2001
From 0108e8e1d09affa11f7b365be1499bfb25ff50c1 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 28 Oct 2013 10:13:27 -0400
Subject: [PATCH 41/85] F10 doesn't work on serial, so don't tell the user to
Subject: [PATCH 37/88] F10 doesn't work on serial, so don't tell the user to
hit it (#987443)
Signed-off-by: Peter Jones <pjones@redhat.com>
@ -23,5 +23,5 @@ index 537d4bf..452d55b 100644
STANDARD_MARGIN, STANDARD_MARGIN,
term, dry_run);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From af21e1092f7b99e1815b5a4653a15586580fd398 Mon Sep 17 00:00:00 2001
From 801b0d582436988fd2806b919a095f2987fc3ef5 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 14 Mar 2011 14:27:42 -0400
Subject: [PATCH 42/85] Don't say "GNU/Linux" in generated menus.
Subject: [PATCH 38/88] Don't say "GNU/Linux" in generated menus.
---
util/grub.d/10_linux.in | 4 ++--
@ -9,7 +9,7 @@ Subject: [PATCH 42/85] Don't say "GNU/Linux" in generated menus.
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 5b49dcb..d54b982 100644
index f3bf6ac..ef52cf3 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -29,9 +29,9 @@ export TEXTDOMAINDIR="@localedir@"
@ -25,7 +25,7 @@ index 5b49dcb..d54b982 100644
fi
diff --git a/util/grub.d/20_linux_xen.in b/util/grub.d/20_linux_xen.in
index 46045db..002e11d 100644
index c48af94..25e3c41 100644
--- a/util/grub.d/20_linux_xen.in
+++ b/util/grub.d/20_linux_xen.in
@@ -29,9 +29,9 @@ export TEXTDOMAINDIR="@localedir@"
@ -41,5 +41,5 @@ index 46045db..002e11d 100644
fi
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 7874cc5b2a72249ec7bdea308cc7f689428a8714 Mon Sep 17 00:00:00 2001
From 3cb9a57c4bd888c7513700deb4026c86080778ff Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Wed, 15 May 2013 16:47:33 -0400
Subject: [PATCH 43/85] Don't draw a border around the menu
Subject: [PATCH 39/88] Don't draw a border around the menu
It looks cleaner without it.
---
@ -70,5 +70,5 @@ index 452d55b..1ed2bd9 100644
grub_term_highlight_color = old_color_highlight;
geo->timeout_y = geo->first_entry_y + geo->num_entries
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From c18188e88655d8404dc1687b5a5c4e3ae1a01c7c Mon Sep 17 00:00:00 2001
From 06c049445cc4fd428072e849c3098796dc9becd7 Mon Sep 17 00:00:00 2001
From: William Jon McCann <william.jon.mccann@gmail.com>
Date: Fri, 7 Jun 2013 10:52:32 -0400
Subject: [PATCH 44/85] Use the standard margin for the timeout string
Subject: [PATCH 40/88] Use the standard margin for the timeout string
So that it aligns with the other messages
---
@ -39,5 +39,5 @@ index 1ed2bd9..7681f7d 100644
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 5baee32f7f9771fe64fa0cdf6e49cd4f6158487a Mon Sep 17 00:00:00 2001
From 0b6d27b7407be21d753a66c09444ed8c19815854 Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Mon, 13 Jan 2014 21:50:59 -0500
Subject: [PATCH 45/85] Add .eh_frame to list of relocations stripped
Subject: [PATCH 41/88] Add .eh_frame to list of relocations stripped
---
conf/Makefile.common | 2 +-
@ -21,5 +21,5 @@ index 11296b5..a476ab5 100644
CFLAGS_MODULE = $(CFLAGS_PLATFORM) -ffreestanding
LDFLAGS_MODULE = $(LDFLAGS_PLATFORM) -nostdlib $(TARGET_LDFLAGS_OLDMAGIC) -Wl,-r,-d
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From ba2e29130c54c0082f2b9a6719e891c1a7397a03 Mon Sep 17 00:00:00 2001
From 48e48d6b9b6f75bf01a080272f260df7132ab9c7 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 14 Jan 2014 13:12:23 -0500
Subject: [PATCH 46/85] Make 10_linux work with our changes for linux16 and
Subject: [PATCH 42/88] Make 10_linux work with our changes for linux16 and
linuxefi on aarch64
Signed-off-by: Peter Jones <pjones@redhat.com>
@ -10,7 +10,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 28 insertions(+), 3 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index d54b982..ab9d32d 100644
index ef52cf3..191aebe 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -77,8 +77,18 @@ linux_entry ()
@ -81,5 +81,5 @@ index d54b982..ab9d32d 100644
for i in "${dirname}/config-${version}" "${dirname}/config-${alt_version}" "/etc/kernels/kernel-config-${version}" ; do
if test -e "${i}" ; then
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 7c437680ba85ea5b1a7c98fd2b2e9ff8ddb00a1e Mon Sep 17 00:00:00 2001
From 6b35fd42bdd803b1b38fd3b04eb642ff822b700f Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 14 Jan 2014 16:15:46 -0500
Subject: [PATCH 47/85] Don't print during fdt loading method.
Subject: [PATCH 43/88] Don't print during fdt loading method.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
@ -9,7 +9,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 2 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index ab9d32d..04179d9 100644
index 191aebe..452a9f6 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -164,9 +164,7 @@ EOF
@ -23,5 +23,5 @@ index ab9d32d..04179d9 100644
EOF
fi
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 633be1409c09df43142eb1310234ff9ebfe0dc62 Mon Sep 17 00:00:00 2001
From dd7c64ce04e1e95265b85163427bb8ff570c12f0 Mon Sep 17 00:00:00 2001
From: Hans de Goede <hdegoede@redhat.com>
Date: Mon, 30 Jun 2014 14:16:46 -0400
Subject: [PATCH 48/85] Don't munge raw spaces when we're doing our cmdline
Subject: [PATCH 44/88] Don't munge raw spaces when we're doing our cmdline
escaping (#923374)
Signed-off-by: Peter Jones <pjones@redhat.com>
@ -32,5 +32,5 @@ index 0a5b2af..970ea86 100644
{
*buf++ = *c++;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 030328c1b5d1266d5f664dafd6af52d765dbe3b0 Mon Sep 17 00:00:00 2001
From 84d97657cf6af3929cf8ff3c9faea002ac6d77c3 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 11 Feb 2014 11:14:50 -0500
Subject: [PATCH 49/85] Don't require a password to boot entries generated by
Subject: [PATCH 45/88] Don't require a password to boot entries generated by
grub-mkconfig.
When we set a password, we just want that to mean you can't /edit/ an entry.
@ -14,7 +14,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 04179d9..a0e71fa 100644
index 452a9f6..79a747e 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -26,7 +26,7 @@ datarootdir="@datarootdir@"
@ -27,5 +27,5 @@ index 04179d9..a0e71fa 100644
if [ "x${GRUB_DISTRIBUTOR}" = "x" ] ; then
OS="$(sed 's, release .*$,,g' /etc/system-release)"
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 62ce77c55bb224f3c318d94cf45bf170d2fc806f Mon Sep 17 00:00:00 2001
From 72d44b7bd5aa2bff64d8a6e40d086dc51aab5684 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 18 Feb 2014 09:37:49 -0500
Subject: [PATCH 50/85] Don't emit "Booting ..." message.
Subject: [PATCH 46/88] Don't emit "Booting ..." message.
UI team still hates this stuff, so we're disabling it for RHEL 7.
@ -9,16 +9,20 @@ Resolves: rhbz#1023142
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/normal/menu.c | 2 ++
grub-core/normal/menu.c | 4 +++-
grub-core/normal/menu_entry.c | 3 ---
2 files changed, 2 insertions(+), 3 deletions(-)
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/grub-core/normal/menu.c b/grub-core/normal/menu.c
index 73a94aa..e74cb56 100644
index 2e8a7bd..004711d 100644
--- a/grub-core/normal/menu.c
+++ b/grub-core/normal/menu.c
@@ -832,9 +832,11 @@ static void
notify_booting (grub_menu_entry_t __attribute__((unused)) entry,
@@ -838,12 +838,14 @@ run_menu (grub_menu_t menu, int nested, int *auto_boot)
/* Callback invoked immediately before a menu entry is executed. */
static void
-notify_booting (grub_menu_entry_t entry,
+notify_booting (grub_menu_entry_t __attribute__((unused)) entry,
void *userdata __attribute__((unused)))
{
+#if 0
@ -44,5 +48,5 @@ index eeeee55..8349049 100644
errs_before = grub_err_printed_errors;
--
2.5.0
2.5.5

View File

@ -1,9 +1,8 @@
From 07232bee88b91155ed2315db10d83e03e466efc6 Mon Sep 17 00:00:00 2001
From 1f68f3b40b8b476e95f29eac40c76dbba892cd17 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 4 Mar 2014 11:00:23 -0500
Subject: [PATCH 51/85] Replace a lot of man pages with slightly nicer ones.
Subject: [PATCH 47/88] May as well try it.
Replace a bunch of machine generated ones with ones that look nicer.
---
conf/Makefile.extra-dist | 1 -
configure.ac | 23 ++++++
@ -134,7 +133,7 @@ index b16bd92..39eb94b 100644
EXTRA_DIST += docs/grub.cfg
EXTRA_DIST += docs/osdetect.cfg
diff --git a/configure.ac b/configure.ac
index a85b134..4369bda 100644
index 21023ae..e976e85 100644
--- a/configure.ac
+++ b/configure.ac
@@ -70,6 +70,29 @@ grub_TRANSFORM([grub-set-default])
@ -1959,5 +1958,5 @@ index 0000000..37ea2dd
+.SH SEE ALSO
+.BR "info grub"
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a937e5533ae47be79d374fb99709282e16df4f0d Mon Sep 17 00:00:00 2001
From 4fd04da5eded81f854dd058f6435c4aef4f31f2d Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Wed, 19 Feb 2014 15:58:43 -0500
Subject: [PATCH 52/85] use fw_path prefix when fallback searching for grub
Subject: [PATCH 48/88] use fw_path prefix when fallback searching for grub
config
When PXE booting via UEFI firmware, grub was searching for grub.cfg
@ -18,7 +18,7 @@ Signed-off-by: Mark Salter <msalter@redhat.com>
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index d98e868..660238a 100644
index 0ce59fd..a3713ef 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -343,7 +343,7 @@ grub_cmd_normal (struct grub_command *cmd __attribute__ ((unused)),
@ -41,5 +41,5 @@ index d98e868..660238a 100644
{
grub_size_t config_len;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 780862554b3ee8a44c9d0b7e77ba219377a6b39b Mon Sep 17 00:00:00 2001
From f0925300caaea3344007689452e24a543fd6cf8a Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 6 Mar 2014 11:51:33 -0500
Subject: [PATCH 53/85] Try mac/guid/etc before grub.cfg on tftp config files.
Subject: [PATCH 49/88] Try mac/guid/etc before grub.cfg on tftp config files.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
@ -9,7 +9,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 43 insertions(+), 37 deletions(-)
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index 660238a..3ba1cdb 100644
index a3713ef..7d9c4f0 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -341,53 +341,59 @@ grub_cmd_normal (struct grub_command *cmd __attribute__ ((unused)),
@ -110,5 +110,5 @@ index 660238a..3ba1cdb 100644
else
grub_enter_normal_mode (argv[0]);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From f35eaf656ac008e23937d5a31ece0e41df9e69cf Mon Sep 17 00:00:00 2001
From 31bfe8719af1e91099d8b56793ad175e3f4bd335 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 18 Feb 2014 11:34:00 -0500
Subject: [PATCH 54/85] Fix convert function to support NVMe devices
Subject: [PATCH 50/88] Fix convert function to support NVMe devices
This is adapted from the patch at
https://bugzilla.redhat.com/show_bug.cgi?id=1019660 , which is against
@ -55,5 +55,5 @@ index 92c0d70..bf317a2 100644
return grub_util_devmapper_part_to_disk (&st, is_part, os_dev);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 507dd275029deb504e0a7ffae3a7cd76f5701412 Mon Sep 17 00:00:00 2001
From b6f8f9ef2dcde4ad9db1a270740ed60705c31e7b Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Mon, 10 Feb 2014 16:13:10 -0500
Subject: [PATCH 55/85] Switch to use APM Mustang device tree, for hardware
Subject: [PATCH 51/88] Switch to use APM Mustang device tree, for hardware
testing.
Signed-off-by: David A. Marlin <d.marlin@redhat.com>
@ -10,7 +10,7 @@ Signed-off-by: David A. Marlin <d.marlin@redhat.com>
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index a0e71fa..dc3d081 100644
index 79a747e..462b461 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -232,8 +232,8 @@ while [ "x$list" != "x" ] ; do
@ -25,5 +25,5 @@ index a0e71fa..dc3d081 100644
fi
done
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 30fa988875e7b218240ac2100f4bab768c80a7f6 Mon Sep 17 00:00:00 2001
From 8b7bd5624770ad0aeef2c2f21d4e667bcef77e74 Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Wed, 12 Feb 2014 14:54:04 -0500
Subject: [PATCH 56/85] Use the default device tree from the grub default file
Subject: [PATCH 52/88] Use the default device tree from the grub default file
instead of hardcoding a value.
@ -26,7 +26,7 @@ index c088b70..9d595ac 100644
if test "x${grub_cfg}" != "x"; then
rm -f "${grub_cfg}.new"
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index dc3d081..30e0e85 100644
index 462b461..a9692a0 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -232,8 +232,8 @@ while [ "x$list" != "x" ] ; do
@ -41,5 +41,5 @@ index dc3d081..30e0e85 100644
fi
done
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a3f2c756ce34c9666bddef35e3b3b85ccecdcffc Mon Sep 17 00:00:00 2001
From 27e661936f8f001100c143036749a0e620d63cbf Mon Sep 17 00:00:00 2001
From: Fedora Ninjas <grub2-owner@fedoraproject.org>
Date: Sat, 15 Feb 2014 15:10:22 -0500
Subject: [PATCH 57/85] reopen SNP protocol for exclusive use by grub
Subject: [PATCH 53/88] reopen SNP protocol for exclusive use by grub
---
grub-core/net/drivers/efi/efinet.c | 16 ++++++++++++++++
@ -42,5 +42,5 @@ index 5388f95..ea0e0ca 100644
}
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From deb910d72a3a8745ca207e75f5caa09b0264606c Mon Sep 17 00:00:00 2001
From bb7d6c1820634b4da2d36b83aa621a8a79ea0701 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 3 Sep 2014 10:01:03 -0400
Subject: [PATCH 59/85] Add grub_util_readlink()
Subject: [PATCH 54/88] Add grub_util_readlink()
Add grub_util_readlink(). This requires pulling in stat and readlink from
gnulib, which pulls in stat and related headers, but after that the
@ -3730,5 +3730,5 @@ index 0000000..9852778
+ REPLACE_LOCALTIME=0; AC_SUBST([REPLACE_LOCALTIME])
+])
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 4c54fc0998ac13e7d38ba44cefcda9384d794475 Mon Sep 17 00:00:00 2001
From f3a6739b6848501f01c4b5a1218d80f8354c5d75 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 3 Sep 2014 10:38:00 -0400
Subject: [PATCH 60/85] Make editenv chase symlinks including those across
Subject: [PATCH 55/88] Make editenv chase symlinks including those across
devices.
This lets us make /boot/grub2/grubenv a symlink to
@ -17,7 +17,7 @@ Reviewed-by: Adam Jackson <ajax@redhat.com>
2 files changed, 53 insertions(+), 2 deletions(-)
diff --git a/Makefile.util.def b/Makefile.util.def
index dfd48fc..c123038 100644
index 6d452da..2061104 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -230,8 +230,17 @@ program = {
@ -102,5 +102,5 @@ index c6f8d22..d8d1dad 100644
+ free (rename_target);
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 5006f4ecf73a3742f1441177072dd814cd63e9b5 Mon Sep 17 00:00:00 2001
From 1143239b299a86c18b4a474260f677653dbeb49a Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 4 Sep 2014 14:23:23 -0400
Subject: [PATCH 61/85] Generate OS and CLASS in 10_linux from /etc/os-release
Subject: [PATCH 56/88] Generate OS and CLASS in 10_linux from /etc/os-release
This makes us use pretty names in the titles we generate in
grub2-mkconfig when GRUB_DISTRIBUTOR isn't set.
@ -14,7 +14,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 30e0e85..1881c73 100644
index a9692a0..c662726 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -29,7 +29,8 @@ export TEXTDOMAINDIR="@localedir@"
@ -28,5 +28,5 @@ index 30e0e85..1881c73 100644
OS="${GRUB_DISTRIBUTOR}"
CLASS="--class $(echo ${GRUB_DISTRIBUTOR} | tr 'A-Z' 'a-z' | cut -d' ' -f1|LC_ALL=C sed 's,[^[:alnum:]_],_,g') ${CLASS}"
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From e6c8b26dece544383403a13019ad6d4991c72e4e Mon Sep 17 00:00:00 2001
From dee9d5669ff3cedf0013fb53af7cfbca5bfd31c1 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 4 Sep 2014 15:52:08 -0400
Subject: [PATCH 62/85] Minimize the sort ordering for .debug and -rescue-
Subject: [PATCH 57/88] Minimize the sort ordering for .debug and -rescue-
kernels.
Resolves: rhbz#1065360
@ -11,24 +11,24 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 8 insertions(+)
diff --git a/util/grub-mkconfig_lib.in b/util/grub-mkconfig_lib.in
index cf35e41..10fabee 100644
index cf35e41..38dbcee 100644
--- a/util/grub-mkconfig_lib.in
+++ b/util/grub-mkconfig_lib.in
@@ -248,6 +248,14 @@ version_test_gt ()
*.old:*.old) ;;
*.old:*) version_test_gt_a="`echo "$version_test_gt_a" | sed -e 's/\.old$//'`" ; version_test_gt_cmp=gt ;;
*:*.old) version_test_gt_b="`echo "$version_test_gt_b" | sed -e 's/\.old$//'`" ; version_test_gt_cmp=ge ;;
+ *-rescue*:*-rescue*) ;;
+ *?debug:*?debug) ;;
+ *-rescue*:*?debug) return 1 ;;
+ *?debug:*-rescue*) return 0 ;;
+ *-rescue*:*) return 1 ;;
+ *:*-rescue*) return 0 ;;
+ *?debug:*) return 1 ;;
+ *:*?debug) return 0 ;;
+ *-rescue-*:*-rescue-*) ;;
+ *.debug:*.debug) ;;
+ *-rescue-*:*.debug) return 1 ;;
+ *.debug:*-rescue-*) return 0 ;;
+ *-rescue-*:*) return 1 ;;
+ *:*-rescue-*) return 0 ;;
+ *.debug:*) return 1 ;;
+ *:*.debug) return 0 ;;
esac
version_test_numeric "$version_test_gt_a" "$version_test_gt_cmp" "$version_test_gt_b"
return "$?"
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From d0ea23d1dd262db1d131f1fb8bf3d1e6c67ec252 Mon Sep 17 00:00:00 2001
From 3205f86c5dd01523bd233e247c1f463f8f892f42 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Thu, 18 Sep 2014 11:26:14 -0400
Subject: [PATCH 63/85] Load arm with SB enabled.
Subject: [PATCH 58/88] Load arm with SB enabled.
Make sure we actually try to validate secure boot on this platform (even
though we're not shipping it enabled by default.)
@ -12,11 +12,11 @@ is enabled.
---
grub-core/Makefile.core.def | 3 +
grub-core/loader/arm64/linux.c | 117 ++++++++++++++++++++------------------
grub-core/loader/efi/linux.c | 65 +++++++++++++++++++++
grub-core/loader/efi/linux.c | 66 +++++++++++++++++++++
grub-core/loader/i386/efi/linux.c | 39 +------------
include/grub/arm64/linux.h | 7 +++
include/grub/efi/linux.h | 31 ++++++++++
6 files changed, 171 insertions(+), 91 deletions(-)
6 files changed, 172 insertions(+), 91 deletions(-)
create mode 100644 grub-core/loader/efi/linux.c
create mode 100644 include/grub/efi/linux.h
@ -42,7 +42,7 @@ index e79bb0c..7fba196 100644
enable = x86_64_efi;
};
diff --git a/grub-core/loader/arm64/linux.c b/grub-core/loader/arm64/linux.c
index 9519d2e..9f425df 100644
index 9519d2e..4756ef7 100644
--- a/grub-core/loader/arm64/linux.c
+++ b/grub-core/loader/arm64/linux.c
@@ -28,6 +28,7 @@
@ -87,7 +87,7 @@ index 9519d2e..9f425df 100644
+ (grub_strlen (linux_args) + 1) * sizeof (grub_efi_char16_t);
+ loaded_image->load_options =
+ grub_efi_allocate_pages (0,
+ BYTES_TO_PAGES (loaded_image->load_options_size));
+ GRUB_EFI_BYTES_TO_PAGES (loaded_image->load_options_size));
+ if (!loaded_image->load_options)
+ return grub_error(GRUB_ERR_BAD_OS, "failed to create kernel parameters");
+
@ -142,7 +142,7 @@ index 9519d2e..9f425df 100644
+ if (loaded_image->load_options)
+ grub_efi_free_pages ((grub_efi_physical_address_t)
+ loaded_image->load_options,
+ BYTES_TO_PAGES (loaded_image->load_options_size));
+ GRUB_EFI_BYTES_TO_PAGES (loaded_image->load_options_size));
+ loaded_image->load_options = NULL;
+ loaded_image->load_options_size = 0;
+ }
@ -226,10 +226,10 @@ index 9519d2e..9f425df 100644
if (!linux_args)
diff --git a/grub-core/loader/efi/linux.c b/grub-core/loader/efi/linux.c
new file mode 100644
index 0000000..aea378a
index 0000000..8634578
--- /dev/null
+++ b/grub-core/loader/efi/linux.c
@@ -0,0 +1,65 @@
@@ -0,0 +1,66 @@
+/*
+ * GRUB -- GRand Unified Bootloader
+ * Copyright (C) 2014 Free Software Foundation, Inc.
@ -295,6 +295,7 @@ index 0000000..aea378a
+
+ return GRUB_ERR_BUG;
+}
+
diff --git a/grub-core/loader/i386/efi/linux.c b/grub-core/loader/i386/efi/linux.c
index b79e632..e5b7785 100644
--- a/grub-core/loader/i386/efi/linux.c
@ -424,5 +425,5 @@ index 0000000..d9ede36
+
+#endif /* ! GRUB_EFI_LINUX_HEADER */
--
2.5.0
2.5.5

View File

@ -1,54 +0,0 @@
From 5a6729292b36c493c81b4bfeef70434318a604f2 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 4 Mar 2016 15:13:59 -0500
Subject: [PATCH 58/85] Revert "reopen SNP protocol for exclusive use by grub"
This reverts commit a3f2c756ce34c9666bddef35e3b3b85ccecdcffc , which is
obsoleted by these:
49426e9 efinet: open Simple Network Protocol exclusively
f348aee efinet: enable hardware filters when opening interface
c52ae40 efinet: skip virtual IPv4 and IPv6 devices when enumerating cards
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/net/drivers/efi/efinet.c | 16 ----------------
1 file changed, 16 deletions(-)
diff --git a/grub-core/net/drivers/efi/efinet.c b/grub-core/net/drivers/efi/efinet.c
index ea0e0ca..5388f95 100644
--- a/grub-core/net/drivers/efi/efinet.c
+++ b/grub-core/net/drivers/efi/efinet.c
@@ -330,7 +330,6 @@ grub_efi_net_config_real (grub_efi_handle_t hnd, char **device,
{
struct grub_net_card *card;
grub_efi_device_path_t *dp;
- grub_efi_simple_network_t *net;
dp = grub_efi_get_device_path (hnd);
if (! dp)
@@ -384,21 +383,6 @@ grub_efi_net_config_real (grub_efi_handle_t hnd, char **device,
&pxe_mode->dhcp_ack,
sizeof (pxe_mode->dhcp_ack),
1, device, path);
- net = grub_efi_open_protocol (card->efi_handle, &net_io_guid,
- GRUB_EFI_OPEN_PROTOCOL_BY_EXCLUSIVE);
- if (net) {
- if (net->mode->state == GRUB_EFI_NETWORK_STOPPED
- && efi_call_1 (net->start, net) != GRUB_EFI_SUCCESS)
- continue;
-
- if (net->mode->state == GRUB_EFI_NETWORK_STOPPED)
- continue;
-
- if (net->mode->state == GRUB_EFI_NETWORK_STARTED
- && efi_call_3 (net->initialize, net, 0, 0) != GRUB_EFI_SUCCESS)
- continue;
- card->efi_net = net;
- }
return;
}
}
--
2.5.0

View File

@ -1,7 +1,7 @@
From 240f6e49d239635f7ca8cd2ca6103df534c92507 Mon Sep 17 00:00:00 2001
From 5623928606eedef63ca57e7679fadb2dbca6e667 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 3 Oct 2014 11:08:03 -0400
Subject: [PATCH 64/85] Try $prefix if $fw_path doesn't work.
Subject: [PATCH 59/88] Try $prefix if $fw_path doesn't work.
Related: rhbz#1148652
@ -70,7 +70,7 @@ index e53d9a0..9af9a1f 100644
static struct grub_preboot *fini_hnd;
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
index 3ba1cdb..13d9eab 100644
index 7d9c4f0..b69f9e7 100644
--- a/grub-core/normal/main.c
+++ b/grub-core/normal/main.c
@@ -331,74 +331,72 @@ grub_enter_normal_mode (const char *config)
@ -207,5 +207,5 @@ index 3ba1cdb..13d9eab 100644
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From ce8210df5c25af8ce319f6cd5b7578beaf3e9a22 Mon Sep 17 00:00:00 2001
From 44bbf278339fa37f99b6c825f746ae4b661cf5ab Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Mon, 27 Oct 2014 09:22:55 -0400
Subject: [PATCH 65/85] Try to emit linux16/initrd16 and linuxefi/initrdefi in
Subject: [PATCH 60/88] Try to emit linux16/initrd16 and linuxefi/initrdefi in
30-os_prober.
Resolves: rhbz#1108296
@ -12,7 +12,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 26 insertions(+), 4 deletions(-)
diff --git a/util/grub.d/30_os-prober.in b/util/grub.d/30_os-prober.in
index 9b8f596..dc98eac 100644
index 515a68c..9d9b9de 100644
--- a/util/grub.d/30_os-prober.in
+++ b/util/grub.d/30_os-prober.in
@@ -141,6 +141,28 @@ for OS in ${OSPROBED} ; do
@ -73,5 +73,5 @@ index 9b8f596..dc98eac 100644
fi
cat << EOF
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 91f9701082fe351aa221323fb684e08c6b466b87 Mon Sep 17 00:00:00 2001
From 6926564fb4e43fe2b30189df1afd4a68cb70cf96 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 28 Apr 2015 11:15:03 -0400
Subject: [PATCH 66/85] Make grub2-mkconfig construct titles that look like the
Subject: [PATCH 61/88] Make grub2-mkconfig construct titles that look like the
ones we want elsewhere.
Resolves: rhbz#1215839
@ -12,7 +12,7 @@ Signed-off-by: Peter Jones <pjones@redhat.com>
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 1881c73..539ac65 100644
index c662726..1215241 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -68,6 +68,15 @@ case x"$GRUB_FS" in
@ -50,5 +50,5 @@ index 1881c73..539ac65 100644
echo "menuentry '$(echo "$title" | grub_quote)' ${CLASS} \$menuentry_id_option 'gnulinux-$version-$type-$boot_device_id' {" | sed "s/^/$submenu_indentation/"
else
--
2.5.0
2.5.5

View File

@ -0,0 +1,43 @@
From 9e58670eba056f4a502d0c52f0e9663a99a31651 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 28 Apr 2015 11:17:02 -0400
Subject: [PATCH 62/88] Make rescue and debug entries sort right /again/ in
grub2-mkconfig.
Related: rhbz#12145839
Signed-off-by: Peter Jones <pjones@redhat.com>
---
util/grub-mkconfig_lib.in | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/util/grub-mkconfig_lib.in b/util/grub-mkconfig_lib.in
index 38dbcee..10fabee 100644
--- a/util/grub-mkconfig_lib.in
+++ b/util/grub-mkconfig_lib.in
@@ -248,14 +248,14 @@ version_test_gt ()
*.old:*.old) ;;
*.old:*) version_test_gt_a="`echo "$version_test_gt_a" | sed -e 's/\.old$//'`" ; version_test_gt_cmp=gt ;;
*:*.old) version_test_gt_b="`echo "$version_test_gt_b" | sed -e 's/\.old$//'`" ; version_test_gt_cmp=ge ;;
- *-rescue-*:*-rescue-*) ;;
- *.debug:*.debug) ;;
- *-rescue-*:*.debug) return 1 ;;
- *.debug:*-rescue-*) return 0 ;;
- *-rescue-*:*) return 1 ;;
- *:*-rescue-*) return 0 ;;
- *.debug:*) return 1 ;;
- *:*.debug) return 0 ;;
+ *-rescue*:*-rescue*) ;;
+ *?debug:*?debug) ;;
+ *-rescue*:*?debug) return 1 ;;
+ *?debug:*-rescue*) return 0 ;;
+ *-rescue*:*) return 1 ;;
+ *:*-rescue*) return 0 ;;
+ *?debug:*) return 1 ;;
+ *:*?debug) return 0 ;;
esac
version_test_numeric "$version_test_gt_a" "$version_test_gt_cmp" "$version_test_gt_b"
return "$?"
--
2.5.5

View File

@ -1,7 +1,7 @@
From 0fd74ec2eb69ee6147fbf2062a9eecceff24896b Mon Sep 17 00:00:00 2001
From 12f88d5f1d4a685efa0839e5026d027f29af9a48 Mon Sep 17 00:00:00 2001
From: Robert Marshall <rmarshall@redhat.com>
Date: Mon, 16 Mar 2015 16:34:51 -0400
Subject: [PATCH 67/85] Update info with grub.cfg netboot selection order
Subject: [PATCH 63/88] Update info with grub.cfg netboot selection order
(#1148650)
Added documentation to the grub info page that specifies the order
@ -66,5 +66,5 @@ index 98d4d0d..4c6323b 100644
@samp{(tftp)} device.
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 368462b4c02b93431943242d069a13aaa3f7f410 Mon Sep 17 00:00:00 2001
From 45361b630a6f3e751ad1d6b90eaabb33356ff96e Mon Sep 17 00:00:00 2001
From: Robert Marshall <rmarshall@redhat.com>
Date: Mon, 16 Mar 2015 14:14:19 -0400
Subject: [PATCH 68/85] Use Distribution Package Sort for grub2-mkconfig
Subject: [PATCH 64/88] Use Distribution Package Sort for grub2-mkconfig
(#1124074)
Users reported that newly installed kernels on their systems installed
@ -34,7 +34,7 @@ index 06c9f3a..7697877 100644
grub-set-default
grub-shell
diff --git a/Makefile.util.def b/Makefile.util.def
index c123038..1b0dc15 100644
index 2061104..d846b81 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -684,6 +684,22 @@ program = {
@ -61,7 +61,7 @@ index c123038..1b0dc15 100644
name = grub-mkconfig;
common = util/grub-mkconfig.in;
diff --git a/configure.ac b/configure.ac
index 4369bda..127d91d 100644
index e976e85..ad2cff3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,6 +65,7 @@ grub_TRANSFORM([grub-mkrelpath])
@ -80,7 +80,7 @@ index 4369bda..127d91d 100644
grub_TRANSFORM([grub-reboot.3])
grub_TRANSFORM([grub-render-label.3])
grub_TRANSFORM([grub-script-check.3])
@@ -1731,6 +1733,33 @@ fi
@@ -1742,6 +1744,33 @@ fi
AC_SUBST([LIBDEVMAPPER])
@ -456,5 +456,5 @@ index 0000000..f33bd1e
+ return 0;
+}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From bcca98247da836509464b14549c34debb5b17bd3 Mon Sep 17 00:00:00 2001
From c1613d899c70d7e138fac7c55a82af71cdda5a78 Mon Sep 17 00:00:00 2001
From: Robert Marshall <rmarshall@redhat.com>
Date: Thu, 25 Jun 2015 11:13:11 -0400
Subject: [PATCH 69/85] Add friendly grub2 password config tool (#985962)
Subject: [PATCH 65/88] Add friendly grub2 password config tool (#985962)
Provided a tool for users to reset the grub2 root user password
without having to alter the grub.cfg. The hashed password now
@ -34,7 +34,7 @@ index 7697877..53a391e 100644
grub-shell-tester
grub-sparc64-setup
diff --git a/Makefile.util.def b/Makefile.util.def
index 1b0dc15..5598b03 100644
index d846b81..226c46b 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -440,6 +440,12 @@ script = {
@ -65,7 +65,7 @@ index 1b0dc15..5598b03 100644
common = util/grub-mkconfig_lib.in;
installdir = noinst;
diff --git a/configure.ac b/configure.ac
index 127d91d..d6ef6c3 100644
index ad2cff3..627c146 100644
--- a/configure.ac
+++ b/configure.ac
@@ -65,6 +65,7 @@ grub_TRANSFORM([grub-mkrelpath])
@ -91,7 +91,7 @@ index 9d595ac..fb87247 100644
echo
diff --git a/util/grub-setpassword.8 b/util/grub-setpassword.8
new file mode 100644
index 0000000..49200a8
index 0000000..5973abe
--- /dev/null
+++ b/util/grub-setpassword.8
@@ -0,0 +1,28 @@
@ -106,7 +106,7 @@ index 0000000..49200a8
+\fBgrub-setpassword\fR outputs the user.cfg file which contains the hashed GRUB bootloader password. This utility only supports configurations where there is a single root user.
+
+The file has the format:
+GRUB2_PASSWORD=<\fIhashed password\fR>.
+GRUB_2PASSWORD=<\fIhashed password\fR>.
+
+.SH OPTIONS
+.TP
@ -254,7 +254,7 @@ index 0000000..dd76f00
+echo "GRUB2_PASSWORD=${MYPASS}" > "${grubdir}/user.cfg"
diff --git a/util/grub.d/01_users.in b/util/grub.d/01_users.in
new file mode 100644
index 0000000..db2f44b
index 0000000..facd409
--- /dev/null
+++ b/util/grub.d/01_users.in
@@ -0,0 +1,11 @@
@ -262,7 +262,7 @@ index 0000000..db2f44b
+cat << EOF
+if [ -f \${prefix}/user.cfg ]; then
+ source \${prefix}/user.cfg
+ if [ -n "\${GRUB2_PASSWORD}" ]; then
+ if [ -n \${GRUB2_PASSWORD} ]; then
+ set superusers="root"
+ export superusers
+ password_pbkdf2 root \${GRUB2_PASSWORD}
@ -270,5 +270,5 @@ index 0000000..db2f44b
+fi
+EOF
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 4cee6969015be92d0a4371f4ccae7f36c6b80dc6 Mon Sep 17 00:00:00 2001
From a3f3818f3d8b18ea7e19b5ff92380ce0e41683ba Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Tue, 14 Jul 2015 16:58:51 -0700
Subject: [PATCH 70/85] Fix race in EFI validation
Subject: [PATCH 66/88] Fix race in EFI validation
---
grub-core/loader/i386/efi/linux.c | 44 ++++++++++-----------------------------
@ -93,5 +93,5 @@ index e5b7785..7ccf32d 100644
{
grub_dl_unref (my_mod);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 6ea648a482015d3379acbe4f6f78991e3e923c47 Mon Sep 17 00:00:00 2001
From 5eb595b341b207d36bb6342b54104c6cb122b7bc Mon Sep 17 00:00:00 2001
From: Don Zickus <dzickus@redhat.com>
Date: Wed, 22 Jul 2015 13:59:55 -0400
Subject: [PATCH 71/85] ppc64le sync mkconfig to disk (#1212114)
Subject: [PATCH 67/88] ppc64le sync mkconfig to disk (#1212114)
If creating a new grub2 entry using grub2-mkconfig, the entry is not
immediately sync'd to disk. If a crash happens before the writeback,
@ -38,5 +38,5 @@ index fb87247..73a18f7 100644
+ sync && mountpoint -q /boot &&fsfreeze -f /boot && fsfreeze -u /boot
+fi
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From bdc3eb0098b4b7d85423bb5674e50d78b01f3f49 Mon Sep 17 00:00:00 2001
From e30cb265bcb8597e0bcb21b21ffb9014599ece51 Mon Sep 17 00:00:00 2001
From: Raymund Will <rw@suse.com>
Date: Fri, 10 Apr 2015 01:45:02 -0400
Subject: [PATCH 72/85] Use device part of chainloader target, if present.
Subject: [PATCH 68/88] Use device part of chainloader target, if present.
Otherwise chainloading is restricted to '$root', which might not even
be readable by EFI!
@ -33,5 +33,5 @@ index 522a716..6b47497 100644
goto fail;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 5a211adebc2362cb5d7767bd95fe204f0d5cb852 Mon Sep 17 00:00:00 2001
From af00ac0c54f0d893a4afb44713ebd2e87f3195f5 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 6 Oct 2015 13:04:37 -0400
Subject: [PATCH 73/85] Add secureboot support on efi chainloader
Subject: [PATCH 69/88] Add secureboot support on efi chainloader
Expand the chainloader to be able to verify the image by means of shim
lock protocol. The PE/COFF image is loaded and relocated by the
@ -796,5 +796,5 @@ index f79c36c..f79782e 100644
{
grub_uint32_t page_rva;
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From f1896dc881b276559079773ba666266979df2f74 Mon Sep 17 00:00:00 2001
From 93653ab62a8c139654fc798fc4c7d74db267b2ee Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 6 Oct 2015 16:09:25 -0400
Subject: [PATCH 74/85] Make any of the loaders that link in efi mode honor
Subject: [PATCH 70/88] Make any of the loaders that link in efi mode honor
secure boot.
And in this case "honor" means "even if somebody does link this in, they
@ -470,5 +470,5 @@ index 0000000..9629fbb
+
+#endif /* ! GRUB_EFI_SB_HEADER */
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From a33e256429267872f469a2d3d1e36ac3721369b3 Mon Sep 17 00:00:00 2001
From 115128428dfd5552605152180ebe227d4b1e7b4e Mon Sep 17 00:00:00 2001
From: Hector Marco-Gisbert <hecmargi@upv.es>
Date: Fri, 13 Nov 2015 16:21:09 +0100
Subject: [PATCH 75/85] Fix security issue when reading username and password
Subject: [PATCH 71/88] Fix security issue when reading username and password
This patch fixes two integer underflows at:
* grub-core/lib/crypto.c
@ -43,5 +43,5 @@ index 7338f82..6d6dc7d 100644
if (cur_len)
{
--
2.5.0
2.5.5

View File

@ -0,0 +1,44 @@
From 2a3ab6ddcff1015e9c6df6a1f61779d581e9a26d Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 4 Dec 2015 09:28:38 -0500
Subject: [PATCH 72/88] 01_users: Handle GRUB_PASSWORD better.
Only handle GRUB2_PASSWORD not GRUB_PASSWORD.
Related: rhbz#1284370
Signed-off-by: Peter Jones <pjones@redhat.com>
---
util/grub-setpassword.8 | 2 +-
util/grub.d/01_users.in | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/util/grub-setpassword.8 b/util/grub-setpassword.8
index 5973abe..49200a8 100644
--- a/util/grub-setpassword.8
+++ b/util/grub-setpassword.8
@@ -9,7 +9,7 @@
\fBgrub-setpassword\fR outputs the user.cfg file which contains the hashed GRUB bootloader password. This utility only supports configurations where there is a single root user.
The file has the format:
-GRUB_2PASSWORD=<\fIhashed password\fR>.
+GRUB2_PASSWORD=<\fIhashed password\fR>.
.SH OPTIONS
.TP
diff --git a/util/grub.d/01_users.in b/util/grub.d/01_users.in
index facd409..db2f44b 100644
--- a/util/grub.d/01_users.in
+++ b/util/grub.d/01_users.in
@@ -2,7 +2,7 @@
cat << EOF
if [ -f \${prefix}/user.cfg ]; then
source \${prefix}/user.cfg
- if [ -n \${GRUB2_PASSWORD} ]; then
+ if [ -n "\${GRUB2_PASSWORD}" ]; then
set superusers="root"
export superusers
password_pbkdf2 root \${GRUB2_PASSWORD}
--
2.5.5

View File

@ -1,7 +1,7 @@
From 59e54f473afa4e4f67dde8f11a33cb8490496086 Mon Sep 17 00:00:00 2001
From 4fa25a258abddce2c1c8a27decc4b9f554f731b8 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Tue, 14 Jul 2015 17:06:35 -0700
Subject: [PATCH 77/85] Core TPM support
Subject: [PATCH 73/88] Core TPM support
Add support for performing basic TPM measurements. Right now this only
supports extending PCRs statically and only on UEFI and BIOS systems, but
@ -35,7 +35,7 @@ index fd715a8..d082933 100644
if COND_i386_pc
diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def
index 990e41b..9fa9790 100644
index ac195d1..9af5479 100644
--- a/grub-core/Makefile.core.def
+++ b/grub-core/Makefile.core.def
@@ -126,6 +126,7 @@ kernel = {
@ -46,7 +46,7 @@ index 990e41b..9fa9790 100644
noemu = kern/compiler-rt.c;
noemu = kern/mm.c;
@@ -177,6 +178,7 @@ kernel = {
@@ -174,6 +175,7 @@ kernel = {
efi = kern/acpi.c;
efi = kern/efi/acpi.c;
efi = lib/envblk.c;
@ -54,7 +54,7 @@ index 990e41b..9fa9790 100644
i386_coreboot = kern/i386/pc/acpi.c;
i386_multiboot = kern/i386/pc/acpi.c;
i386_coreboot = kern/acpi.c;
@@ -222,6 +224,7 @@ kernel = {
@@ -219,6 +221,7 @@ kernel = {
i386_pc = kern/i386/pc/init.c;
i386_pc = kern/i386/pc/mmap.c;
@ -785,5 +785,5 @@ index 0000000..40d3cf6
+
+#endif
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 878a4bed6479ccfbde4ba8dc3c2c029f12fba708 Mon Sep 17 00:00:00 2001
From d24a5cf53175a3498b9c67a97ca6ad5604d0a678 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Thu, 16 Jul 2015 15:22:34 -0700
Subject: [PATCH 78/85] Measure kernel + initrd
Subject: [PATCH 74/88] Measure kernel + initrd
Measure the kernel and initrd when loaded on UEFI systems
---
@ -38,5 +38,5 @@ index 7ccf32d..4ee45e9 100644
{
grub_error (GRUB_ERR_INVALID_COMMAND, N_("%s has invalid signature"), argv[0]);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From b727ffaee53c9f3ee9ab1497441e378d77a5af6d Mon Sep 17 00:00:00 2001
From 69b26d3068903f543e0a7ba949c76d63467b10d5 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Sun, 9 Aug 2015 15:48:51 -0700
Subject: [PATCH 79/85] Add BIOS boot measurement
Subject: [PATCH 75/88] Add BIOS boot measurement
Measure the on-disk grub core on BIOS systems - unlike UEFI, the firmware
can't do this stage for us.
@ -175,5 +175,5 @@ index c8b87ed..05dd7fa 100644
* message: write the string pointed to by %si
*
--
2.5.0
2.5.5

View File

@ -1,175 +0,0 @@
From 9e51bd34baf8c705380abb4dc4b3847c11c93829 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Wed, 27 Jan 2016 09:22:42 -0500
Subject: [PATCH 76/85] Make grub_fatal() also backtrace.
---
grub-core/Makefile.core.def | 3 ++
grub-core/kern/misc.c | 8 +++++-
grub-core/lib/arm64/backtrace.c | 62 +++++++++++++++++++++++++++++++++++++++++
grub-core/lib/backtrace.c | 2 ++
grub-core/lib/i386/backtrace.c | 14 +++++++++-
5 files changed, 87 insertions(+), 2 deletions(-)
create mode 100644 grub-core/lib/arm64/backtrace.c
diff --git a/grub-core/Makefile.core.def b/grub-core/Makefile.core.def
index ac195d1..990e41b 100644
--- a/grub-core/Makefile.core.def
+++ b/grub-core/Makefile.core.def
@@ -157,6 +157,9 @@ kernel = {
softdiv = lib/division.c;
+ x86 = lib/i386/backtrace.c;
+ x86 = lib/backtrace.c;
+
i386 = kern/i386/dl.c;
i386_xen = kern/i386/dl.c;
diff --git a/grub-core/kern/misc.c b/grub-core/kern/misc.c
index 81be344..d7dcd97 100644
--- a/grub-core/kern/misc.c
+++ b/grub-core/kern/misc.c
@@ -24,6 +24,7 @@
#include <grub/term.h>
#include <grub/env.h>
#include <grub/i18n.h>
+#include <grub/backtrace.h>
union printf_arg
{
@@ -1087,8 +1088,13 @@ grub_xasprintf (const char *fmt, ...)
static void __attribute__ ((noreturn))
grub_abort (void)
{
+#ifndef GRUB_UTIL
+#if defined(__i386__) || defined(__x86_64__)
+ grub_backtrace();
+#endif
+#endif
grub_printf ("\nAborted.");
-
+
#ifndef GRUB_UTIL
if (grub_term_inputs)
#endif
diff --git a/grub-core/lib/arm64/backtrace.c b/grub-core/lib/arm64/backtrace.c
new file mode 100644
index 0000000..1079b53
--- /dev/null
+++ b/grub-core/lib/arm64/backtrace.c
@@ -0,0 +1,62 @@
+/*
+ * GRUB -- GRand Unified Bootloader
+ * Copyright (C) 2009 Free Software Foundation, Inc.
+ *
+ * GRUB is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GRUB is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GRUB. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include <grub/misc.h>
+#include <grub/command.h>
+#include <grub/err.h>
+#include <grub/dl.h>
+#include <grub/mm.h>
+#include <grub/term.h>
+#include <grub/backtrace.h>
+
+#define MAX_STACK_FRAME 102400
+
+void
+grub_backtrace_pointer (int frame)
+{
+ while (1)
+ {
+ void *lp = __builtin_return_address (frame);
+ if (!lp)
+ break;
+
+ lp = __builtin_extract_return_addr (lp);
+
+ grub_printf ("%p: ", lp);
+ grub_backtrace_print_address (lp);
+ grub_printf (" (");
+ for (i = 0; i < 2; i++)
+ grub_printf ("%p,", ((void **)ptr) [i + 2]);
+ grub_printf ("%p)\n", ((void **)ptr) [i + 2]);
+ nptr = *(void **)ptr;
+ if (nptr < ptr || (void **) nptr - (void **) ptr > MAX_STACK_FRAME
+ || nptr == ptr)
+ {
+ grub_printf ("Invalid stack frame at %p (%p)\n", ptr, nptr);
+ break;
+ }
+ ptr = nptr;
+ }
+}
+
+void
+grub_backtrace (void)
+{
+ grub_backtrace_pointer (1);
+}
+
diff --git a/grub-core/lib/backtrace.c b/grub-core/lib/backtrace.c
index 825a880..c0ad6ab 100644
--- a/grub-core/lib/backtrace.c
+++ b/grub-core/lib/backtrace.c
@@ -29,6 +29,7 @@ GRUB_MOD_LICENSE ("GPLv3+");
void
grub_backtrace_print_address (void *addr)
{
+#ifndef GRUB_UTIL
grub_dl_t mod;
FOR_DL_MODULES (mod)
@@ -44,6 +45,7 @@ grub_backtrace_print_address (void *addr)
}
}
+#endif
grub_printf ("%p", addr);
}
diff --git a/grub-core/lib/i386/backtrace.c b/grub-core/lib/i386/backtrace.c
index c3e03c7..c67273d 100644
--- a/grub-core/lib/i386/backtrace.c
+++ b/grub-core/lib/i386/backtrace.c
@@ -15,11 +15,23 @@
* You should have received a copy of the GNU General Public License
* along with GRUB. If not, see <http://www.gnu.org/licenses/>.
*/
+#include <config.h>
+#ifdef GRUB_UTIL
+#define REALLY_GRUB_UTIL GRUB_UTIL
+#undef GRUB_UTIL
+#endif
+
+#include <grub/symbol.h>
+#include <grub/dl.h>
+
+#ifdef REALLY_GRUB_UTIL
+#define GRUB_UTIL REALLY_GRUB_UTIL
+#undef REALLY_GRUB_UTIL
+#endif
#include <grub/misc.h>
#include <grub/command.h>
#include <grub/err.h>
-#include <grub/dl.h>
#include <grub/mm.h>
#include <grub/term.h>
#include <grub/backtrace.h>
--
2.5.0

View File

@ -1,7 +1,7 @@
From 6ef376d234cf06ef3e92d77b03fa4060516a218c Mon Sep 17 00:00:00 2001
From 47beae47e49806881000c479a5912d3bf2990da4 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Sun, 9 Aug 2015 16:12:39 -0700
Subject: [PATCH 80/85] Rework linux command
Subject: [PATCH 76/88] Rework linux command
We want a single buffer that contains the entire kernel image in order to
perform a TPM measurement. Allocate one and copy the entire kernel into it
@ -103,5 +103,5 @@ index b0afcca..5eb7d17 100644
grub_file_close (file);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 9992eed98ad0d7d66444185a9cd2c81df5b4e1b2 Mon Sep 17 00:00:00 2001
From 4cd88ca039d62e64ee4ccbe46a4ea3500a70a6be Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Sun, 9 Aug 2015 16:20:58 -0700
Subject: [PATCH 81/85] Rework linux16 command
Subject: [PATCH 77/88] Rework linux16 command
We want a single buffer that contains the entire kernel image in order to
perform a TPM measurement. Allocate one and copy the entire kernel int it
@ -97,5 +97,5 @@ index 9128315..b864e54 100644
grub_file_close (file);
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From f4d862215e8d693018f419be33a0a3a7c3e79d29 Mon Sep 17 00:00:00 2001
From 05f686df4b9a012035854b082bb4c3b7c745da28 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Sun, 9 Aug 2015 16:28:29 -0700
Subject: [PATCH 82/85] Measure kernel and initrd on BIOS systems
Subject: [PATCH 78/88] Measure kernel and initrd on BIOS systems
Measure the kernel and initrd when loaded on BIOS systems
---
@ -83,5 +83,5 @@ index be6fa0f..3005c0d 100644
}
if (newc)
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 6bcfc6f286d099a26cc0c7a00a6458d1d7993485 Mon Sep 17 00:00:00 2001
From 2ab937cba72f43241667db08b5e36cd31a77f331 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Sun, 9 Aug 2015 16:32:29 -0700
Subject: [PATCH 83/85] Measure the kernel commandline
Subject: [PATCH 79/88] Measure the kernel commandline
Measure the kernel commandline to ensure that it hasn't been modified
---
@ -39,5 +39,5 @@ index 970ea86..6b56304 100644
return i;
}
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 4f316cbb70563a26a8cb42ce5122c198cfd3636d Mon Sep 17 00:00:00 2001
From e3aae28751e0f0128d877ed25b28d4d2f875b71a Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@srcf.ucam.org>
Date: Mon, 10 Aug 2015 15:27:12 -0700
Subject: [PATCH 84/85] Measure commands
Subject: [PATCH 80/88] Measure commands
Measure each command executed by grub, which includes script execution.
---
@ -72,5 +72,5 @@ index 40d3cf6..7fc9d77 100644
#define TPM_TAG_RQU_COMMAND 0x00C1
#define TPM_ORD_Extend 0x14
--
2.5.0
2.5.5

View File

@ -1,7 +1,7 @@
From 85e100453d04e56088e4b9782d2f06dc0122587f Mon Sep 17 00:00:00 2001
From ee0acf80b073cf652a949673bd750e7a9a302d37 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Tue, 1 Sep 2015 16:02:55 -0700
Subject: [PATCH 85/85] Measure multiboot images and modules
Subject: [PATCH 81/88] Measure multiboot images and modules
---
grub-core/loader/i386/multiboot_mbi.c | 3 +++
@ -72,5 +72,5 @@ index f147d67..8f163ea 100644
if (header == 0)
--
2.5.0
2.5.5

View File

@ -0,0 +1,30 @@
From 1c4338a7d3921e18364c696c679e77e23e7193b3 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Fri, 4 Mar 2016 16:29:13 -0500
Subject: [PATCH 82/88] Make grub-editenv build again.
36212460d3565b18439a3a8130b28e6c97702c6a split how some of the mkimage
utility functions are defined, and they wind up being linked into
grub-editenv. Most utilities got fixed, but this one was missed.
Signed-off-by: Peter Jones <pjones@redhat.com>
---
Makefile.util.def | 2 ++
1 file changed, 2 insertions(+)
diff --git a/Makefile.util.def b/Makefile.util.def
index 226c46b..8007de9 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -236,6 +236,8 @@ program = {
extra_dist = grub-core/osdep/unix/compress.c;
extra_dist = grub-core/osdep/basic/compress.c;
common = util/mkimage.c;
+ common = util/grub-mkimage32.c;
+ common = util/grub-mkimage64.c;
common = grub-core/osdep/config.c;
common = util/config.c;
common = util/resolve.c;
--
2.5.5

View File

@ -0,0 +1,30 @@
From d477086463fd9ea61a3df4b55a4adde56c386215 Mon Sep 17 00:00:00 2001
From: Robert Marshall <rmarshall@redhat.com>
Date: Fri, 29 Jan 2016 17:34:02 -0500
Subject: [PATCH 83/88] Fix locale issue in grub-setpassword (#1294243)
A shell substitution was expecting non-translated output to grab the
hashed password and put it in the user.cfg file. Modified code to force
the generic C locale when this particular piece of code is run.
Resolves: rhbz#1294243
---
util/grub-setpassword.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/grub-setpassword.in b/util/grub-setpassword.in
index dd76f00..2923f43 100644
--- a/util/grub-setpassword.in
+++ b/util/grub-setpassword.in
@@ -105,7 +105,7 @@ getpass() {
P1="$1" && shift
( echo ${P0} ; echo ${P1} ) | \
- ${grub_mkpasswd} | \
+ LC_ALL=C ${grub_mkpasswd} | \
grep -v '[eE]nter password:' | \
sed -e "s/PBKDF2 hash of your password is //"
}
--
2.5.5

View File

@ -0,0 +1,153 @@
From b4e66576c9fd1602aeb924b13cdc39d8c59a4255 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 23 Sep 2014 09:58:49 -0400
Subject: [PATCH 84/88] Fix up some man pages rpmdiff noticed.
---
configure.ac | 2 ++
util/grub-macbless.8 | 26 +++++++++++++++++++
util/grub-mkimage.1 | 2 +-
util/grub-syslinux2cfg.1 | 65 ++++++++++++++++++++++++++++++++++++++++++++++++
4 files changed, 94 insertions(+), 1 deletion(-)
create mode 100644 util/grub-macbless.8
create mode 100644 util/grub-syslinux2cfg.1
diff --git a/configure.ac b/configure.ac
index 627c146..ec3ae9c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -78,6 +78,7 @@ grub_TRANSFORM([grub-fstest.3])
grub_TRANSFORM([grub-glue-efi.3])
grub_TRANSFORM([grub-install.1])
grub_TRANSFORM([grub-kbdcomp.3])
+grub_TRANSFORM([grub-macbless.8])
grub_TRANSFORM([grub-menulst2cfg.1])
grub_TRANSFORM([grub-mkconfig.1])
grub_TRANSFORM([grub-mkfont.3])
@@ -96,6 +97,7 @@ grub_TRANSFORM([grub-render-label.3])
grub_TRANSFORM([grub-script-check.3])
grub_TRANSFORM([grub-set-default.1])
grub_TRANSFORM([grub-sparc64-setup.3])
+grub_TRANSFORM([grub-syslinux2cfg.1])
# Optimization flag. Allow user to override.
if test "x$TARGET_CFLAGS" = x; then
diff --git a/util/grub-macbless.8 b/util/grub-macbless.8
new file mode 100644
index 0000000..ae842f3
--- /dev/null
+++ b/util/grub-macbless.8
@@ -0,0 +1,26 @@
+.TH GRUB-MACBLESS 1 "Wed Feb 26 2014"
+.SH NAME
+\fBgrub-macbless\fR \(em Mac-style bless utility for HFS or HFS+
+
+.SH SYNOPSIS
+\fBgrub-macbless\fR [-p | --ppc] [-v | --verbose] [-x | --x86] \fIFILE\fR
+
+.SH DESCRIPTION
+\fBgrub-mkimage\fR blesses a file on an HFS or HFS+ file system, so that it
+can be used to boot a Mac.
+
+.SH OPTIONS
+.TP
+--ppc
+Bless the file for use on PPC-based Macs.
+
+.TP
+--verbose
+Print verbose messages.
+
+.TP
+--x86
+Bless the file for use on x86-based Macs.
+
+.SH SEE ALSO
+.BR "info grub"
diff --git a/util/grub-mkimage.1 b/util/grub-mkimage.1
index 4dea4f5..0eaaafe 100644
--- a/util/grub-mkimage.1
+++ b/util/grub-mkimage.1
@@ -17,7 +17,7 @@
[-v | --verbose] \fIMODULES\fR
.SH DESCRIPTION
-\fBgrub-mkimage\fI builds a bootable image of GRUB.
+\fBgrub-mkimage\fR builds a bootable image of GRUB.
.SH OPTIONS
.TP
diff --git a/util/grub-syslinux2cfg.1 b/util/grub-syslinux2cfg.1
new file mode 100644
index 0000000..8530948
--- /dev/null
+++ b/util/grub-syslinux2cfg.1
@@ -0,0 +1,65 @@
+.TH GRUB-SYSLINUX2CFG 1 "Wed Feb 26 2014"
+.SH NAME
+\fBgrub-syslinux2cfg\fR \(em Transform a syslinux config file into a GRUB config.
+
+.SH SYNOPSIS
+\fBgrub-syslinux2cfg\fR [-c | --cwd=\fRDIR\fI] [-r | --root=\fIDIR\fR] [-v | --verbose]
+.RE
+.RS 25
+[-t | --target-root=\fIDIR\fR] [-T | --target-cwd=\fIDIR\fR]
+.RE
+.RS 25
+[-o | --output=\fIFILE\fR] [[-i | --isolinux] |
+.RE
+.RS 46
+ [-s | --syslinux] |
+.RE
+.RS 46
+ [-p | --pxelinux]] \fIFILE\fR
+
+.SH DESCRIPTION
+\fBgrub-syslinux2cfg\fR builds a GRUB configuration file out of an existing
+syslinux configuration file.
+
+.SH OPTIONS
+.TP
+--cwd=\fIDIR\fR
+Set \fIDIR\fR as syslinux's working directory. The default is to use the
+parent directory of the input file.
+
+.TP
+--root=\fIDIR\fR
+Set \fIDIR\fR as the root directory of the syslinux disk. The default value
+is "/".
+
+.TP
+--verbose
+Print verbose messages.
+
+.TP
+--target-root=\fIDIR\fR
+Root directory as it will be seen at runtime. The default value is "/".
+
+.TP
+--target-cwd=\fIDIR\fR
+Working directory of syslinux as it will be seen at runtime. The default
+value is the parent directory of the input file.
+
+.TP
+--output=\fIFILE\fR
+Write the new config file to \fIFILE\fR. The default value is standard output.
+
+.TP
+--isolinux
+Assume that the input file is an isolinux configuration file.
+
+.TP
+--pxelinux
+Assume that the input file is a pxelinux configuration file.
+
+.TP
+--syslinux
+Assume that the input file is a syslinux configuration file.
+
+.SH SEE ALSO
+.BR "info grub"
--
2.5.5

View File

@ -0,0 +1,39 @@
From 54d0f8d24fc634b71e8525703a6eea8c23f4c9e5 Mon Sep 17 00:00:00 2001
From: Peter Jones <pjones@redhat.com>
Date: Tue, 30 Jun 2015 15:50:41 -0400
Subject: [PATCH 85/88] Handle rssd storage devices.
Resolves: rhbz#1087962
Signed-off-by: Peter Jones <pjones@redhat.com>
---
grub-core/osdep/linux/getroot.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/grub-core/osdep/linux/getroot.c b/grub-core/osdep/linux/getroot.c
index 10480b6..469923b 100644
--- a/grub-core/osdep/linux/getroot.c
+++ b/grub-core/osdep/linux/getroot.c
@@ -892,6 +892,19 @@ grub_util_part_to_disk (const char *os_dev, struct stat *st,
return path;
}
+ /* If this is an rssd device. */
+ if ((strncmp ("rssd", p, 4) == 0) && p[4] >= 'a' && p[4] <= 'z')
+ {
+ char *pp = p + 4;
+ while (*pp >= 'a' && *pp <= 'z')
+ pp++;
+ if (*pp)
+ *is_part = 1;
+ /* /dev/rssd[a-z]+[0-9]* */
+ *pp = '\0';
+ return path;
+ }
+
/* If this is a loop device */
if ((strncmp ("loop", p, 4) == 0) && p[4] >= '0' && p[4] <= '9')
{
--
2.5.5

View File

@ -0,0 +1,31 @@
From a9c95bf3bb50ee171c80e9fe643da618afa8fdf9 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Wed, 23 Mar 2016 16:49:42 -0700
Subject: [PATCH 86/88] Fix boot when there's no TPM
If the firmware has TPM support but has no TPM, we're jumping to core.img
without popping the registers back onto the stack. Fix that.
(cherry picked from commit c2eee36ec08f8ed0cd25b8030276347680be4843)
---
grub-core/boot/i386/pc/boot.S | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/boot/i386/pc/boot.S b/grub-core/boot/i386/pc/boot.S
index c1df86d..acab373 100644
--- a/grub-core/boot/i386/pc/boot.S
+++ b/grub-core/boot/i386/pc/boot.S
@@ -473,9 +473,9 @@ LOCAL(copy_buffer):
movl $0x8, %edx /* PCR 8 */
int $0x1A
+boot:
popa
#endif
-boot:
/* boot kernel */
jmp *(LOCAL(kernel_address))
--
2.5.5

View File

@ -0,0 +1,219 @@
From 1388967d903a07c92a39fa4e8573f7ba12f45357 Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Wed, 23 Mar 2016 17:03:43 -0700
Subject: [PATCH 87/88] Rework TPM measurements
Rework TPM measurements to use fewer PCRs. After discussion with upstream,
it's preferable to avoid using so many PCRs. Instead, measure into PCRs 8
and 9 but use a prefix in the event log to indicate which subsystem carried
out the measurements.
(cherry picked from commit bb3473d7c8741ad5ef7cf8aafbbcf094df08bfc9)
---
grub-core/kern/dl.c | 2 +-
grub-core/kern/tpm.c | 10 ++++++++--
grub-core/lib/cmdline.c | 4 ++--
grub-core/loader/i386/efi/linux.c | 4 ++--
grub-core/loader/i386/linux.c | 2 +-
grub-core/loader/i386/multiboot_mbi.c | 2 +-
grub-core/loader/i386/pc/linux.c | 2 +-
grub-core/loader/linux.c | 2 +-
grub-core/loader/multiboot.c | 2 +-
grub-core/loader/multiboot_mbi2.c | 2 +-
grub-core/script/execute.c | 4 ++--
include/grub/tpm.h | 9 +++------
12 files changed, 24 insertions(+), 21 deletions(-)
diff --git a/grub-core/kern/dl.c b/grub-core/kern/dl.c
index 247cd0a..a023d3b 100644
--- a/grub-core/kern/dl.c
+++ b/grub-core/kern/dl.c
@@ -734,7 +734,7 @@ grub_dl_load_file (const char *filename)
opens of the same device. */
grub_file_close (file);
- grub_tpm_measure(core, size, GRUB_TPM_PCR, filename);
+ grub_tpm_measure(core, size, GRUB_BINARY_PCR, "grub_module", filename);
mod = grub_dl_load_core (core, size);
grub_free (core);
diff --git a/grub-core/kern/tpm.c b/grub-core/kern/tpm.c
index 1a99187..cb5a812 100644
--- a/grub-core/kern/tpm.c
+++ b/grub-core/kern/tpm.c
@@ -7,7 +7,13 @@
grub_err_t
grub_tpm_measure (unsigned char *buf, grub_size_t size, grub_uint8_t pcr,
- const char *description)
+ const char *kind, const char *description)
{
- return grub_tpm_log_event(buf, size, pcr, description);
+ grub_err_t ret;
+ char *desc = grub_xasprintf("%s %s", kind, description);
+ if (!desc)
+ return GRUB_ERR_OUT_OF_MEMORY;
+ ret = grub_tpm_log_event(buf, size, pcr, description);
+ grub_free(desc);
+ return ret;
}
diff --git a/grub-core/lib/cmdline.c b/grub-core/lib/cmdline.c
index 6b56304..178f738 100644
--- a/grub-core/lib/cmdline.c
+++ b/grub-core/lib/cmdline.c
@@ -126,8 +126,8 @@ int grub_create_loader_cmdline (int argc, char *argv[], char *buf,
*buf = 0;
- grub_tpm_measure ((void *)orig, grub_strlen (orig), GRUB_CMDLINE_PCR,
- "Kernel Commandline");
+ grub_tpm_measure ((void *)orig, grub_strlen (orig), GRUB_ASCII_PCR,
+ "grub_kernel_cmdline", orig);
return i;
}
diff --git a/grub-core/loader/i386/efi/linux.c b/grub-core/loader/i386/efi/linux.c
index 4ee45e9..bd80be4 100644
--- a/grub-core/loader/i386/efi/linux.c
+++ b/grub-core/loader/i386/efi/linux.c
@@ -130,7 +130,7 @@ grub_cmd_initrd (grub_command_t cmd __attribute__ ((unused)),
argv[i]);
goto fail;
}
- grub_tpm_measure (ptr, cursize, GRUB_INITRD_PCR, "UEFI Linux initrd");
+ grub_tpm_measure (ptr, cursize, GRUB_BINARY_PCR, "grub_linuxefi", "Initrd");
ptr += cursize;
grub_memset (ptr, 0, ALIGN_UP_OVERHEAD (cursize, 4));
ptr += ALIGN_UP_OVERHEAD (cursize, 4);
@@ -186,7 +186,7 @@ grub_cmd_linux (grub_command_t cmd __attribute__ ((unused)),
goto fail;
}
- grub_tpm_measure (kernel, filelen, GRUB_KERNEL_PCR, "UEFI Linux kernel");
+ grub_tpm_measure (kernel, filelen, GRUB_BINARY_PCR, "grub_linuxefi", "Kernel");
if (! grub_linuxefi_secure_validate (kernel, filelen))
{
diff --git a/grub-core/loader/i386/linux.c b/grub-core/loader/i386/linux.c
index 342c9fe..90d3392 100644
--- a/grub-core/loader/i386/linux.c
+++ b/grub-core/loader/i386/linux.c
@@ -718,7 +718,7 @@ grub_cmd_linux (grub_command_t cmd __attribute__ ((unused)),
goto fail;
}
- grub_tpm_measure (kernel, len, GRUB_KERNEL_PCR, "Linux Kernel");
+ grub_tpm_measure (kernel, len, GRUB_BINARY_PCR, "grub_linux", "Kernel");
grub_memcpy (&lh, kernel, sizeof (lh));
diff --git a/grub-core/loader/i386/multiboot_mbi.c b/grub-core/loader/i386/multiboot_mbi.c
index 43a08e4..efaa66c 100644
--- a/grub-core/loader/i386/multiboot_mbi.c
+++ b/grub-core/loader/i386/multiboot_mbi.c
@@ -165,7 +165,7 @@ grub_multiboot_load (grub_file_t file, const char *filename)
return grub_errno;
}
- grub_tpm_measure((unsigned char*)buffer, len, GRUB_KERNEL_PCR, filename);
+ grub_tpm_measure((unsigned char*)buffer, len, GRUB_BINARY_PCR, "grub_multiboot", filename);
header = find_header (buffer, len);
diff --git a/grub-core/loader/i386/pc/linux.c b/grub-core/loader/i386/pc/linux.c
index 6b8f365..7edbc5e 100644
--- a/grub-core/loader/i386/pc/linux.c
+++ b/grub-core/loader/i386/pc/linux.c
@@ -162,7 +162,7 @@ grub_cmd_linux (grub_command_t cmd __attribute__ ((unused)),
goto fail;
}
- grub_tpm_measure (kernel, len, GRUB_KERNEL_PCR, "BIOS Linux Kernel");
+ grub_tpm_measure (kernel, len, GRUB_BINARY_PCR, "grub_linux16", "Kernel");
grub_memcpy (&lh, kernel, sizeof (lh));
kernel_offset = sizeof (lh);
diff --git a/grub-core/loader/linux.c b/grub-core/loader/linux.c
index 3005c0d..78c41e3 100644
--- a/grub-core/loader/linux.c
+++ b/grub-core/loader/linux.c
@@ -289,7 +289,7 @@ grub_initrd_load (struct grub_linux_initrd_context *initrd_ctx,
grub_initrd_close (initrd_ctx);
return grub_errno;
}
- grub_tpm_measure (ptr, cursize, GRUB_INITRD_PCR, "Linux Initrd");
+ grub_tpm_measure (ptr, cursize, GRUB_BINARY_PCR, "grub_initrd", "Initrd");
ptr += cursize;
}
if (newc)
diff --git a/grub-core/loader/multiboot.c b/grub-core/loader/multiboot.c
index 58e6329..234164b 100644
--- a/grub-core/loader/multiboot.c
+++ b/grub-core/loader/multiboot.c
@@ -386,7 +386,7 @@ grub_cmd_module (grub_command_t cmd __attribute__ ((unused)),
}
grub_file_close (file);
- grub_tpm_measure (module, size, GRUB_KERNEL_PCR, argv[0]);
+ grub_tpm_measure (module, size, GRUB_BINARY_PCR, "grub_multiboot", argv[0]);
return GRUB_ERR_NONE;
}
diff --git a/grub-core/loader/multiboot_mbi2.c b/grub-core/loader/multiboot_mbi2.c
index 8f163ea..3d1117b 100644
--- a/grub-core/loader/multiboot_mbi2.c
+++ b/grub-core/loader/multiboot_mbi2.c
@@ -127,7 +127,7 @@ grub_multiboot_load (grub_file_t file, const char *filename)
COMPILE_TIME_ASSERT (MULTIBOOT_HEADER_ALIGN % 4 == 0);
- grub_tpm_measure ((unsigned char *)buffer, len, GRUB_KERNEL_PCR, filename);
+ grub_tpm_measure ((unsigned char *)buffer, len, GRUB_BINARY_PCR, "grub_multiboot", filename);
header = find_header (buffer, len);
diff --git a/grub-core/script/execute.c b/grub-core/script/execute.c
index 9ae04a0..976643c 100644
--- a/grub-core/script/execute.c
+++ b/grub-core/script/execute.c
@@ -995,8 +995,8 @@ grub_script_execute_cmdline (struct grub_script_cmd *cmd)
argv.args[i]);
}
cmdstring[cmdlen-1]= '\0';
- grub_tpm_measure ((unsigned char *)cmdstring, cmdlen, GRUB_COMMAND_PCR,
- cmdstring);
+ grub_tpm_measure ((unsigned char *)cmdstring, cmdlen, GRUB_ASCII_PCR,
+ "grub_cmd", cmdstring);
grub_free(cmdstring);
invert = 0;
argc = argv.argc - 1;
diff --git a/include/grub/tpm.h b/include/grub/tpm.h
index 7fc9d77..ecb2d09 100644
--- a/include/grub/tpm.h
+++ b/include/grub/tpm.h
@@ -26,11 +26,8 @@
#define TPM_AUTHFAIL (TPM_BASE + 0x1)
#define TPM_BADINDEX (TPM_BASE + 0x2)
-#define GRUB_TPM_PCR 9
-#define GRUB_KERNEL_PCR 10
-#define GRUB_INITRD_PCR 11
-#define GRUB_CMDLINE_PCR 12
-#define GRUB_COMMAND_PCR 13
+#define GRUB_ASCII_PCR 8
+#define GRUB_BINARY_PCR 9
#define TPM_TAG_RQU_COMMAND 0x00C1
#define TPM_ORD_Extend 0x14
@@ -70,7 +67,7 @@ typedef struct {
} GRUB_PACKED ExtendOutgoing;
grub_err_t EXPORT_FUNC(grub_tpm_measure) (unsigned char *buf, grub_size_t size,
- grub_uint8_t pcr,
+ grub_uint8_t pcr, const char *kind,
const char *description);
#if defined (GRUB_MACHINE_EFI) || defined (GRUB_MACHINE_PCBIOS)
grub_err_t grub_tpm_execute(PassThroughToTPM_InputParamBlock *inbuf,
--
2.5.5

View File

@ -0,0 +1,29 @@
From 3fded5274e9d0968fac6d37ee16f2f2d53b8594d Mon Sep 17 00:00:00 2001
From: Matthew Garrett <mjg59@coreos.com>
Date: Tue, 29 Mar 2016 15:36:49 -0700
Subject: [PATCH 88/88] Fix event log prefix
We're not passing the prefixed version of the description to the event log.
Fix that.
(cherry picked from commit aab446306b8a78c741e229861c4988738cfc6426)
---
grub-core/kern/tpm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/grub-core/kern/tpm.c b/grub-core/kern/tpm.c
index cb5a812..e5e8fce 100644
--- a/grub-core/kern/tpm.c
+++ b/grub-core/kern/tpm.c
@@ -13,7 +13,7 @@ grub_tpm_measure (unsigned char *buf, grub_size_t size, grub_uint8_t pcr,
char *desc = grub_xasprintf("%s %s", kind, description);
if (!desc)
return GRUB_ERR_OUT_OF_MEMORY;
- ret = grub_tpm_log_event(buf, size, pcr, description);
+ ret = grub_tpm_log_event(buf, size, pcr, desc);
grub_free(desc);
return ret;
}
--
2.5.5

View File

@ -2,6 +2,19 @@ From: Peter Jones <pjones@redhat.com>
Date: Wed Jul 22 10:18:00 2015 -0400
Subject: Stop trying to "git format-patch" across a merge that confuses it
diff --git a/Makefile.util.def b/Makefile.util.def
index ed9b4c697dae038655ca7740f59285bd9044709b..f9caccb9780ffe8d4b31c8a19399ba7bbd308e56 100644
--- a/Makefile.util.def
+++ b/Makefile.util.def
@@ -416,7 +416,7 @@ program = {
ldadd = libgrubgcry.a;
ldadd = libgrubkern.a;
ldadd = grub-core/gnulib/libgnu.a;
- ldadd = '$(LIBINTL) $(LIBDEVMAPPER) $(LIBZFS) $(LIBNVPAIR) $(LIBGEOM)';
+ ldadd = '$(LIBINTL) $(LIBDEVMAPPER) $(LIBUTIL) $(LIBZFS) $(LIBNVPAIR) $(LIBGEOM)';
};
data = {
diff --git a/NEWS b/NEWS
index c9a975219fcc24162858e461f439886c4cb3841e..572eadb3ef27138481e91643b8bb60d27ce867c8 100644
--- a/NEWS
@ -52,3 +65,168 @@ index c9a975219fcc24162858e461f439886c4cb3841e..572eadb3ef27138481e91643b8bb60d2
* Revision control moved to git.
diff --git a/configure.ac b/configure.ac
index a85b134ec58296e4f128b116918cb1c64ee17ecc..57e17138eb72aa4d4f985c525998d300f7121ccd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1185,9 +1185,9 @@ CFLAGS="$TARGET_CFLAGS"
# Position independent executable.
grub_CHECK_PIE
[# Need that, because some distributions ship compilers that include
-# `-fPIE' in the default specs.
+# `-fPIE' or '-fpie' in the default specs.
if [ x"$pie_possible" = xyes ]; then
- TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIE"
+ TARGET_CFLAGS="$TARGET_CFLAGS -fno-PIE -fno-pie"
fi]
CFLAGS="$TARGET_CFLAGS"
diff --git a/grub-core/fs/iso9660.c b/grub-core/fs/iso9660.c
index 67a67cf40dae4c00355bc4e93d32d449c45ff4c2..c9c8374bf614b4e39b5e57fd813e4e587e256679 100644
--- a/grub-core/fs/iso9660.c
+++ b/grub-core/fs/iso9660.c
@@ -750,19 +750,15 @@ grub_iso9660_iterate_dir (grub_fshelp_node_t dir,
if (dir->data->joliet && !ctx.filename)
{
- char *oldname, *semicolon;
+ char *semicolon;
- oldname = name;
ctx.filename = grub_iso9660_convert_string
- ((grub_uint8_t *) oldname, dirent.namelen >> 1);
+ ((grub_uint8_t *) name, dirent.namelen >> 1);
semicolon = grub_strrchr (ctx.filename, ';');
if (semicolon)
*semicolon = '\0';
- if (ctx.filename_alloc)
- grub_free (oldname);
-
ctx.filename_alloc = 1;
}
diff --git a/grub-core/loader/i386/xen_file.c b/grub-core/loader/i386/xen_file.c
index 5836218909876dc3c1bfd5e8ad0239d4b8edb7c8..37f9ad8ac008cdff4f36a2dc6b2083bd55fdf90f 100644
--- a/grub-core/loader/i386/xen_file.c
+++ b/grub-core/loader/i386/xen_file.c
@@ -55,11 +55,11 @@ grub_xen_file (grub_file_t file)
grub_dprintf ("xen", "found bzimage payload 0x%llx-0x%llx\n",
(unsigned long long) (lh.setup_sects + 1) * 512
+ lh.payload_offset,
- (unsigned long long) lh.payload_length - 4);
+ (unsigned long long) lh.payload_length);
off_file = grub_file_offset_open (file, (lh.setup_sects + 1) * 512
+ lh.payload_offset,
- lh.payload_length - 4);
+ lh.payload_length);
if (!off_file)
goto fail;
diff --git a/grub-core/net/bootp.c b/grub-core/net/bootp.c
index a088244b4cb1ce9f21d02c1f3024a99e681ccb1a..189551a483ab9413cdca27650b20267268fa724a 100644
--- a/grub-core/net/bootp.c
+++ b/grub-core/net/bootp.c
@@ -157,6 +157,9 @@ grub_net_configure_by_dhcp_ack (const char *name,
hwaddr.type = GRUB_NET_LINK_LEVEL_PROTOCOL_ETHERNET;
inter = grub_net_add_addr (name, card, &addr, &hwaddr, flags);
+ if (!inter)
+ return 0;
+
#if 0
/* This is likely based on misunderstanding. gateway_ip refers to
address of BOOTP relay and should not be used after BOOTP transaction
@@ -368,6 +371,7 @@ grub_cmd_dhcpopt (struct grub_command *cmd __attribute__ ((unused)),
if (grub_strcmp (args[3], "string") == 0)
{
+ grub_err_t err = GRUB_ERR_NONE;
char *val = grub_malloc (taglength + 1);
if (!val)
return grub_errno;
@@ -376,8 +380,9 @@ grub_cmd_dhcpopt (struct grub_command *cmd __attribute__ ((unused)),
if (args[0][0] == '-' && args[0][1] == 0)
grub_printf ("%s\n", val);
else
- return grub_env_set (args[0], val);
- return GRUB_ERR_NONE;
+ err = grub_env_set (args[0], val);
+ grub_free (val);
+ return err;
}
if (grub_strcmp (args[3], "number") == 0)
@@ -399,6 +404,7 @@ grub_cmd_dhcpopt (struct grub_command *cmd __attribute__ ((unused)),
if (grub_strcmp (args[3], "hex") == 0)
{
+ grub_err_t err = GRUB_ERR_NONE;
char *val = grub_malloc (2 * taglength + 1);
int i;
if (!val)
@@ -412,8 +418,9 @@ grub_cmd_dhcpopt (struct grub_command *cmd __attribute__ ((unused)),
if (args[0][0] == '-' && args[0][1] == 0)
grub_printf ("%s\n", val);
else
- return grub_env_set (args[0], val);
- return GRUB_ERR_NONE;
+ err = grub_env_set (args[0], val);
+ grub_free (val);
+ return err;
}
return grub_error (GRUB_ERR_BAD_ARGUMENT,
diff --git a/include/multiboot2.h b/include/multiboot2.h
index 9d4862759af38eb5a9d0fecb1807ef50ba791dee..8b8c1568ae32239d73ad80a3ca64010556d57099 100644
--- a/include/multiboot2.h
+++ b/include/multiboot2.h
@@ -176,7 +176,7 @@ struct multiboot_mmap_entry
#define MULTIBOOT_MEMORY_BADRAM 5
multiboot_uint32_t type;
multiboot_uint32_t zero;
-} GRUB_PACKED;
+};
typedef struct multiboot_mmap_entry multiboot_memory_map_t;
struct multiboot_tag
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
index 203b076966c0f5ef80eb93e7aebd01848a7c73b9..f8496d28bdf7f4bcbc2413888330834c1e252a64 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
@@ -273,6 +273,7 @@ Ensure that there are no errors in /etc/default/grub
and /etc/grub.d/* files or please file a bug report with
%s file attached." "${grub_cfg}.new" >&2
echo >&2
+ exit 1
else
# none of the children aborted with error, install the new grub.cfg
mv -f ${grub_cfg}.new ${grub_cfg}
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
index 5a78513aeae0f6ad866c057564862bda7198a00c..de9044c7f28611d56358f581ac52ca2d2b7fc982 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
@@ -47,7 +47,7 @@ esac
# and mounting btrfs requires user space scanning, so force UUID in this case.
if [ "x${GRUB_DEVICE_UUID}" = "x" ] || [ "x${GRUB_DISABLE_LINUX_UUID}" = "xtrue" ] \
|| ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" \
- || test -e "${GRUB_DEVICE}" && uses_abstraction "${GRUB_DEVICE}" lvm; then
+ || ( test -e "${GRUB_DEVICE}" && uses_abstraction "${GRUB_DEVICE}" lvm ); then
LINUX_ROOT_DEVICE=${GRUB_DEVICE}
else
LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}
diff --git a/util/grub.d/20_linux_xen.in b/util/grub.d/20_linux_xen.in
index 46045db1aab7b3a7cea758c120cc731eabe93eb9..c48af948d6ecdf672aa341f713912ba15de8f27d 100644
--- a/util/grub.d/20_linux_xen.in
+++ b/util/grub.d/20_linux_xen.in
@@ -47,7 +47,7 @@ esac
# and mounting btrfs requires user space scanning, so force UUID in this case.
if [ "x${GRUB_DEVICE_UUID}" = "x" ] || [ "x${GRUB_DISABLE_LINUX_UUID}" = "xtrue" ] \
|| ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" \
- || test -e "${GRUB_DEVICE}" && uses_abstraction "${GRUB_DEVICE}" lvm; then
+ || ( test -e "${GRUB_DEVICE}" && uses_abstraction "${GRUB_DEVICE}" lvm ); then
LINUX_ROOT_DEVICE=${GRUB_DEVICE}
else
LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}

View File

@ -1,86 +1,89 @@
Patch0000: grub-2.02-beta3-to-origin-master.patch
Patch0001: 0001-Fix-crash-on-http.patch
Patch0002: 0002-Update-to-minilzo-2.08.patch
Patch0003: 0003-Failed-config-now-returns-exit-code-1252311.patch
Patch0004: 0004-DHCP-client-ID-and-UUID-options-added.patch
Patch0005: 0005-trim-arp-packets-with-abnormal-size.patch
Patch0006: 0006-Add-vlan-tag-support-on-IBM-PPC-machines.patch
Patch0007: 0007-IBM-client-architecture-CAS-reboot-support.patch
Patch0008: 0008-for-ppc-reset-console-display-attr-when-clear-screen.patch
Patch0009: 0009-Disable-GRUB-video-support-for-IBM-power-machines.patch
Patch0010: 0010-Add-support-for-UEFI-operating-systems-returned-by-o.patch
Patch0011: 0011-Make-efi-machines-load-an-env-block-from-a-variable.patch
Patch0012: 0012-Make-exit-take-a-return-code.patch
Patch0013: 0013-Mark-po-exclude.pot-as-binary-so-git-won-t-try-to-di.patch
Patch0014: 0014-Fix-bzr-s-ignore-artificats-in-.gitignore.patch
Patch0015: 0015-Add-some-__unused__-where-gcc-5.x-is-more-picky-abou.patch
Patch0016: 0016-Move-bash-completion-script-922997.patch
Patch0017: 0017-Allow-fallback-to-include-entries-by-title-not-just-.patch
Patch0018: 0018-Honor-a-symlink-when-generating-configuration-by-gru.patch
Patch0019: 0019-Fix-bad-test-on-GRUB_DISABLE_SUBMENU.patch
Patch0020: 0020-Add-GRUB_DISABLE_UUID.patch
Patch0021: 0021-Add-X-option-to-printf-functions.patch
Patch0022: 0022-Migrate-PPC-from-Yaboot-to-Grub2.patch
Patch0023: 0023-Add-fw_path-variable-revised.patch
Patch0024: 0024-Add-support-for-linuxefi.patch
Patch0025: 0025-Use-linuxefi-and-initrdefi-where-appropriate.patch
Patch0026: 0026-Don-t-allow-insmod-when-secure-boot-is-enabled.patch
Patch0027: 0027-Pass-x-hex-hex-straight-through-unmolested.patch
Patch0028: 0028-Search-for-specific-config-file-for-netboot.patch
Patch0029: 0029-blscfg-add-blscfg-module-to-parse-Boot-Loader-Specif.patch
Patch0030: 0030-Don-t-write-messages-to-the-screen.patch
Patch0031: 0031-Don-t-print-GNU-GRUB-header.patch
Patch0032: 0032-Don-t-add-to-highlighted-row.patch
Patch0033: 0033-Message-string-cleanups.patch
Patch0034: 0034-Fix-border-spacing-now-that-we-aren-t-displaying-it.patch
Patch0035: 0035-Use-the-correct-indentation-for-the-term-help-text.patch
Patch0036: 0036-Indent-menu-entries.patch
Patch0037: 0037-Fix-margins.patch
Patch0038: 0038-Use-2-instead-of-1-for-our-right-hand-margin-so-line.patch
Patch0039: 0039-Use-linux16-when-appropriate-880840.patch
Patch0040: 0040-Enable-pager-by-default.-985860.patch
Patch0041: 0041-F10-doesn-t-work-on-serial-so-don-t-tell-the-user-to.patch
Patch0042: 0042-Don-t-say-GNU-Linux-in-generated-menus.patch
Patch0043: 0043-Don-t-draw-a-border-around-the-menu.patch
Patch0044: 0044-Use-the-standard-margin-for-the-timeout-string.patch
Patch0045: 0045-Add-.eh_frame-to-list-of-relocations-stripped.patch
Patch0046: 0046-Make-10_linux-work-with-our-changes-for-linux16-and-.patch
Patch0047: 0047-Don-t-print-during-fdt-loading-method.patch
Patch0048: 0048-Don-t-munge-raw-spaces-when-we-re-doing-our-cmdline-.patch
Patch0049: 0049-Don-t-require-a-password-to-boot-entries-generated-b.patch
Patch0050: 0050-Don-t-emit-Booting-.-message.patch
Patch0051: 0051-Replace-a-lot-of-man-pages-with-slightly-nicer-ones.patch
Patch0052: 0052-use-fw_path-prefix-when-fallback-searching-for-grub-.patch
Patch0053: 0053-Try-mac-guid-etc-before-grub.cfg-on-tftp-config-file.patch
Patch0054: 0054-Fix-convert-function-to-support-NVMe-devices.patch
Patch0055: 0055-Switch-to-use-APM-Mustang-device-tree-for-hardware-t.patch
Patch0056: 0056-Use-the-default-device-tree-from-the-grub-default-fi.patch
Patch0057: 0057-reopen-SNP-protocol-for-exclusive-use-by-grub.patch
Patch0058: 0058-Revert-reopen-SNP-protocol-for-exclusive-use-by-grub.patch
Patch0059: 0059-Add-grub_util_readlink.patch
Patch0060: 0060-Make-editenv-chase-symlinks-including-those-across-d.patch
Patch0061: 0061-Generate-OS-and-CLASS-in-10_linux-from-etc-os-releas.patch
Patch0062: 0062-Minimize-the-sort-ordering-for-.debug-and-rescue-ker.patch
Patch0063: 0063-Load-arm-with-SB-enabled.patch
Patch0064: 0064-Try-prefix-if-fw_path-doesn-t-work.patch
Patch0065: 0065-Try-to-emit-linux16-initrd16-and-linuxefi-initrdefi-.patch
Patch0066: 0066-Make-grub2-mkconfig-construct-titles-that-look-like-.patch
Patch0067: 0067-Update-info-with-grub.cfg-netboot-selection-order-11.patch
Patch0068: 0068-Use-Distribution-Package-Sort-for-grub2-mkconfig-112.patch
Patch0069: 0069-Add-friendly-grub2-password-config-tool-985962.patch
Patch0070: 0070-Fix-race-in-EFI-validation.patch
Patch0071: 0071-ppc64le-sync-mkconfig-to-disk-1212114.patch
Patch0072: 0072-Use-device-part-of-chainloader-target-if-present.patch
Patch0073: 0073-Add-secureboot-support-on-efi-chainloader.patch
Patch0074: 0074-Make-any-of-the-loaders-that-link-in-efi-mode-honor-.patch
Patch0075: 0075-Fix-security-issue-when-reading-username-and-passwor.patch
Patch0076: 0076-Make-grub_fatal-also-backtrace.patch
Patch0077: 0077-Core-TPM-support.patch
Patch0078: 0078-Measure-kernel-initrd.patch
Patch0079: 0079-Add-BIOS-boot-measurement.patch
Patch0080: 0080-Rework-linux-command.patch
Patch0081: 0081-Rework-linux16-command.patch
Patch0082: 0082-Measure-kernel-and-initrd-on-BIOS-systems.patch
Patch0083: 0083-Measure-the-kernel-commandline.patch
Patch0084: 0084-Measure-commands.patch
Patch0085: 0085-Measure-multiboot-images-and-modules.patch
Patch0001: 0001-IBM-client-architecture-CAS-reboot-support.patch
Patch0002: 0002-for-ppc-reset-console-display-attr-when-clear-screen.patch
Patch0003: 0003-Disable-GRUB-video-support-for-IBM-power-machines.patch
Patch0004: 0004-Fix-bzr-s-ignore-artificats-in-.gitignore.patch
Patch0005: 0005-Honor-a-symlink-when-generating-configuration-by-gru.patch
Patch0006: 0006-Move-bash-completion-script-922997.patch
Patch0007: 0007-Update-to-minilzo-2.08.patch
Patch0008: 0008-Add-vlan-tag-support-on-IBM-PPC-machines.patch
Patch0009: 0009-Allow-fallback-to-include-entries-by-title-not-just-.patch
Patch0010: 0010-Add-GRUB_DISABLE_UUID.patch
Patch0011: 0011-Make-exit-take-a-return-code.patch
Patch0012: 0012-Mark-po-exclude.pot-as-binary-so-git-won-t-try-to-di.patch
Patch0013: 0013-Make-efi-machines-load-an-env-block-from-a-variable.patch
Patch0014: 0014-DHCP-client-ID-and-UUID-options-added.patch
Patch0015: 0015-trim-arp-packets-with-abnormal-size.patch
Patch0016: 0016-Fix-bad-test-on-GRUB_DISABLE_SUBMENU.patch
Patch0017: 0017-Migrate-PPC-from-Yaboot-to-Grub2.patch
Patch0018: 0018-Add-fw_path-variable-revised.patch
Patch0019: 0019-Add-support-for-linuxefi.patch
Patch0020: 0020-Use-linuxefi-and-initrdefi-where-appropriate.patch
Patch0021: 0021-Don-t-allow-insmod-when-secure-boot-is-enabled.patch
Patch0022: 0022-Pass-x-hex-hex-straight-through-unmolested.patch
Patch0023: 0023-Add-X-option-to-printf-functions.patch
Patch0024: 0024-Search-for-specific-config-file-for-netboot.patch
Patch0025: 0025-blscfg-add-blscfg-module-to-parse-Boot-Loader-Specif.patch
Patch0026: 0026-Don-t-write-messages-to-the-screen.patch
Patch0027: 0027-Don-t-print-GNU-GRUB-header.patch
Patch0028: 0028-Don-t-add-to-highlighted-row.patch
Patch0029: 0029-Message-string-cleanups.patch
Patch0030: 0030-Fix-border-spacing-now-that-we-aren-t-displaying-it.patch
Patch0031: 0031-Use-the-correct-indentation-for-the-term-help-text.patch
Patch0032: 0032-Indent-menu-entries.patch
Patch0033: 0033-Fix-margins.patch
Patch0034: 0034-Use-2-instead-of-1-for-our-right-hand-margin-so-line.patch
Patch0035: 0035-Use-linux16-when-appropriate-880840.patch
Patch0036: 0036-Enable-pager-by-default.-985860.patch
Patch0037: 0037-F10-doesn-t-work-on-serial-so-don-t-tell-the-user-to.patch
Patch0038: 0038-Don-t-say-GNU-Linux-in-generated-menus.patch
Patch0039: 0039-Don-t-draw-a-border-around-the-menu.patch
Patch0040: 0040-Use-the-standard-margin-for-the-timeout-string.patch
Patch0041: 0041-Add-.eh_frame-to-list-of-relocations-stripped.patch
Patch0042: 0042-Make-10_linux-work-with-our-changes-for-linux16-and-.patch
Patch0043: 0043-Don-t-print-during-fdt-loading-method.patch
Patch0044: 0044-Don-t-munge-raw-spaces-when-we-re-doing-our-cmdline-.patch
Patch0045: 0045-Don-t-require-a-password-to-boot-entries-generated-b.patch
Patch0046: 0046-Don-t-emit-Booting-.-message.patch
Patch0047: 0047-May-as-well-try-it.patch
Patch0048: 0048-use-fw_path-prefix-when-fallback-searching-for-grub-.patch
Patch0049: 0049-Try-mac-guid-etc-before-grub.cfg-on-tftp-config-file.patch
Patch0050: 0050-Fix-convert-function-to-support-NVMe-devices.patch
Patch0051: 0051-Switch-to-use-APM-Mustang-device-tree-for-hardware-t.patch
Patch0052: 0052-Use-the-default-device-tree-from-the-grub-default-fi.patch
Patch0053: 0053-reopen-SNP-protocol-for-exclusive-use-by-grub.patch
Patch0054: 0054-Add-grub_util_readlink.patch
Patch0055: 0055-Make-editenv-chase-symlinks-including-those-across-d.patch
Patch0056: 0056-Generate-OS-and-CLASS-in-10_linux-from-etc-os-releas.patch
Patch0057: 0057-Minimize-the-sort-ordering-for-.debug-and-rescue-ker.patch
Patch0058: 0058-Load-arm-with-SB-enabled.patch
Patch0059: 0059-Try-prefix-if-fw_path-doesn-t-work.patch
Patch0060: 0060-Try-to-emit-linux16-initrd16-and-linuxefi-initrdefi-.patch
Patch0061: 0061-Make-grub2-mkconfig-construct-titles-that-look-like-.patch
Patch0062: 0062-Make-rescue-and-debug-entries-sort-right-again-in-gr.patch
Patch0063: 0063-Update-info-with-grub.cfg-netboot-selection-order-11.patch
Patch0064: 0064-Use-Distribution-Package-Sort-for-grub2-mkconfig-112.patch
Patch0065: 0065-Add-friendly-grub2-password-config-tool-985962.patch
Patch0066: 0066-Fix-race-in-EFI-validation.patch
Patch0067: 0067-ppc64le-sync-mkconfig-to-disk-1212114.patch
Patch0068: 0068-Use-device-part-of-chainloader-target-if-present.patch
Patch0069: 0069-Add-secureboot-support-on-efi-chainloader.patch
Patch0070: 0070-Make-any-of-the-loaders-that-link-in-efi-mode-honor-.patch
Patch0071: 0071-Fix-security-issue-when-reading-username-and-passwor.patch
Patch0072: 0072-01_users-Handle-GRUB_PASSWORD-better.patch
Patch0073: 0073-Core-TPM-support.patch
Patch0074: 0074-Measure-kernel-initrd.patch
Patch0075: 0075-Add-BIOS-boot-measurement.patch
Patch0076: 0076-Rework-linux-command.patch
Patch0077: 0077-Rework-linux16-command.patch
Patch0078: 0078-Measure-kernel-and-initrd-on-BIOS-systems.patch
Patch0079: 0079-Measure-the-kernel-commandline.patch
Patch0080: 0080-Measure-commands.patch
Patch0081: 0081-Measure-multiboot-images-and-modules.patch
Patch0082: 0082-Make-grub-editenv-build-again.patch
Patch0083: 0083-Fix-locale-issue-in-grub-setpassword-1294243.patch
Patch0084: 0084-Fix-up-some-man-pages-rpmdiff-noticed.patch
Patch0085: 0085-Handle-rssd-storage-devices.patch
Patch0086: 0086-Fix-boot-when-there-s-no-TPM.patch
Patch0087: 0087-Rework-TPM-measurements.patch
Patch0088: 0088-Fix-event-log-prefix.patch

View File

@ -45,7 +45,7 @@
Name: grub2
Epoch: 1
Version: 2.02
Release: 0.26%{?dist}
Release: 0.27%{?dist}
Summary: Bootloader with support for Linux, Multiboot and more
Group: System Environment/Base
@ -544,6 +544,10 @@ fi
%{_datarootdir}/grub/themes/starfield
%changelog
* Tue Apr 05 2016 pjones <pjones@redhat.com> - 1:2.02-0.27
- Pull TPM updates from mjg59.
Resolves: rhbz#1318067
* Fri Mar 04 2016 Peter Jones <pjones@redhat.com> - 2.02-0.26
- Rebased to newer upstream (grub-2.02-beta3) for fedora-24