From ebac83ee9e5bf0ddf9368f85158ab3a7fdf1fadedc84c37e599f315f11e3476d Mon Sep 17 00:00:00 2001 From: Michael Chang Date: Thu, 12 Sep 2019 07:53:39 +0000 Subject: [PATCH] Accepting request 729658 from home:michael-chang:boo:1142229 - Fix fallback embed doesn't work when no post mbr gap at all (boo#1142229) * Refresh grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch OBS-URL: https://build.opensuse.org/request/show/729658 OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=338 --- grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch | 12 ++++++------ grub2.changes | 6 ++++++ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch b/grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch index 5cbe066..7f0febd 100644 --- a/grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch +++ b/grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch @@ -1,8 +1,8 @@ -Index: grub-2.02~beta2/util/setup.c +Index: grub-2.02/util/setup.c =================================================================== ---- grub-2.02~beta2.orig/util/setup.c -+++ grub-2.02~beta2/util/setup.c -@@ -501,8 +501,42 @@ SETUP (const char *dir, +--- grub-2.02.orig/util/setup.c ++++ grub-2.02/util/setup.c +@@ -511,8 +511,42 @@ SETUP (const char *dir, err = grub_util_ldm_embed (dest_dev->disk, &nsec, maxsec, GRUB_EMBED_PCBIOS, §ors); else if (ctx.dest_partmap) @@ -12,7 +12,7 @@ Index: grub-2.02~beta2/util/setup.c + err = ctx.dest_partmap->embed (dest_dev->disk, &nsec, maxsec, + GRUB_EMBED_PCBIOS, §ors); +#ifdef GRUB_SETUP_BIOS -+ if (err == GRUB_ERR_OUT_OF_RANGE ++ if ((err == GRUB_ERR_OUT_OF_RANGE || err == GRUB_ERR_FILE_NOT_FOUND) + && dest_dev->disk->id == root_dev->disk->id + && dest_dev->disk->dev->id == root_dev->disk->dev->id) + { @@ -47,7 +47,7 @@ Index: grub-2.02~beta2/util/setup.c else err = fs->embed (dest_dev, &nsec, maxsec, GRUB_EMBED_PCBIOS, §ors); -@@ -584,7 +618,7 @@ SETUP (const char *dir, +@@ -594,7 +628,7 @@ SETUP (const char *dir, /* Write the core image onto the disk. */ for (i = 0; i < nsec; i++) diff --git a/grub2.changes b/grub2.changes index 344c544..e15ff15 100644 --- a/grub2.changes +++ b/grub2.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Aug 16 04:51:16 UTC 2019 - Michael Chang + +- Fix fallback embed doesn't work when no post mbr gap at all (boo#1142229) + * Refresh grub2-setup-try-fs-embed-if-mbr-gap-too-small.patch + ------------------------------------------------------------------- Thu Jul 18 09:54:14 UTC 2019 - mchang@suse.com