From: "Ben Kohler" <bkohler@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-boot/os-prober/, sys-boot/os-prober/files/
Date: Fri, 8 Oct 2021 11:12:33 +0000 (UTC) [thread overview]
Message-ID: <1633691539.5023585e4f13834627b835125d7c6f9dee62f21a.bkohler@gentoo> (raw)
commit: 5023585e4f13834627b835125d7c6f9dee62f21a
Author: Peter Levine <plevine457 <AT> gmail <DOT> com>
AuthorDate: Fri Oct 8 01:31:47 2021 +0000
Commit: Ben Kohler <bkohler <AT> gentoo <DOT> org>
CommitDate: Fri Oct 8 11:12:19 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5023585e
sys-boot/os-prober: return boot instead of root if both are mounted
Fixes a corner-case in which the root partition is returned instead of
the boot partition, when both are mounted.
Package-Manager: Portage-3.0.26, Repoman-3.0.3
Signed-off-by: Peter Levine <plevine457 <AT> gmail.com>
Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org>
.../os-prober-1.79-mounted-boot-partition-fix.patch | 17 +++++++++++++++++
sys-boot/os-prober/os-prober-9999.ebuild | 1 +
2 files changed, 18 insertions(+)
diff --git a/sys-boot/os-prober/files/os-prober-1.79-mounted-boot-partition-fix.patch b/sys-boot/os-prober/files/os-prober-1.79-mounted-boot-partition-fix.patch
new file mode 100644
index 00000000000..1be8c810ddf
--- /dev/null
+++ b/sys-boot/os-prober/files/os-prober-1.79-mounted-boot-partition-fix.patch
@@ -0,0 +1,17 @@
+Fixes the problem of the root partition being returned instead of the boot
+partition when both are already mounted somewhere.
+
+Bug: https://bugs.debian.org/699840
+ https://bugzilla.redhat.com/906886
+
+--- a/linux-boot-prober
++++ b/linux-boot-prober
+@@ -167,7 +167,7 @@ else
+ bootpart="${mountboot%% *}"
+ bootmounted="${mountboot#* }"
+ else
+- bootpart="$partition"
++ bootpart="$(grep " $mpoint/boot " "$OS_PROBER_TMP/mounted-map" | head -n1 | cut -d " " -f 4)"
+ bootmounted=0
+ fi
+ for test in /usr/lib/linux-boot-probes/mounted/*; do
diff --git a/sys-boot/os-prober/os-prober-9999.ebuild b/sys-boot/os-prober/os-prober-9999.ebuild
index 392bf080566..59539158759 100644
--- a/sys-boot/os-prober/os-prober-9999.ebuild
+++ b/sys-boot/os-prober/os-prober-9999.ebuild
@@ -29,6 +29,7 @@ PATCHES=(
"${FILESDIR}"/${PN}-1.79-mdraid-detection.patch
"${FILESDIR}"/${PN}-1.79-btrfs-subvolume-detection.patch
"${FILESDIR}"/${PN}-1.79-use-fstab-name.patch
+ "${FILESDIR}"/${PN}-1.79-mounted-boot-partition-fix.patch
)
DOC_CONTENTS="
next reply other threads:[~2021-10-08 11:12 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-08 11:12 Ben Kohler [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-06-14 14:18 [gentoo-commits] repo/gentoo:master commit in: sys-boot/os-prober/, sys-boot/os-prober/files/ Ben Kohler
2024-05-21 15:50 Ben Kohler
2024-05-08 16:43 Ben Kohler
2023-02-16 13:55 Ben Kohler
2021-10-08 11:12 Ben Kohler
2021-10-08 11:12 Ben Kohler
2021-10-08 11:12 Ben Kohler
2021-10-08 11:12 Ben Kohler
2017-12-26 12:53 Pacho Ramos
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1633691539.5023585e4f13834627b835125d7c6f9dee62f21a.bkohler@gentoo \
--to=bkohler@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox