mirror of
https://git.proxmox.com/git/grub2
synced 2025-08-16 05:13:23 +00:00
Add rootflags=subvol=<name> if / is on a btrfs subvolume (LP: #712029).
This commit is contained in:
parent
458bc629c4
commit
266a01be26
1
debian/changelog
vendored
1
debian/changelog
vendored
@ -7,6 +7,7 @@ grub2 (1.99~rc1-2) UNRELEASED; urgency=low
|
|||||||
Uggla).
|
Uggla).
|
||||||
* Handle empty dir passed to grub_find_root_device_from_mountinfo; fixes
|
* Handle empty dir passed to grub_find_root_device_from_mountinfo; fixes
|
||||||
grub-mkrelpath on btrfs subvolumes (LP: #712029).
|
grub-mkrelpath on btrfs subvolumes (LP: #712029).
|
||||||
|
* Add rootflags=subvol=<name> if / is on a btrfs subvolume (LP: #712029).
|
||||||
|
|
||||||
-- Colin Watson <cjwatson@debian.org> Tue, 18 Jan 2011 11:44:48 +0000
|
-- Colin Watson <cjwatson@debian.org> Tue, 18 Jan 2011 11:44:48 +0000
|
||||||
|
|
||||||
|
27
debian/patches/btrfs_rootflags.patch
vendored
Normal file
27
debian/patches/btrfs_rootflags.patch
vendored
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
Description: Add rootflags=subvol=<name> if / is on a btrfs subvolume
|
||||||
|
Not yet forwarded upstream because rootflags= is distribution-specific.
|
||||||
|
It's not clear how to do this portably.
|
||||||
|
Author: Colin Watson <cjwatson@ubuntu.com>
|
||||||
|
Forwarded: no
|
||||||
|
Bug-Ubuntu: https://bugs.launchpad.net/bugs/712029
|
||||||
|
Last-Update: 2011-02-04
|
||||||
|
|
||||||
|
Index: b/util/grub.d/10_linux.in
|
||||||
|
===================================================================
|
||||||
|
--- a/util/grub.d/10_linux.in
|
||||||
|
+++ b/util/grub.d/10_linux.in
|
||||||
|
@@ -51,6 +51,14 @@
|
||||||
|
LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}
|
||||||
|
fi
|
||||||
|
|
||||||
|
+if [ "x`${grub_probe} --device ${GRUB_DEVICE} --target=fs 2>/dev/null || true`" = xbtrfs ]; then
|
||||||
|
+ rootsubvol="`make_system_path_relative_to_its_root /`"
|
||||||
|
+ rootsubvol="${rootsubvol#/}"
|
||||||
|
+ if [ "x${rootsubvol}" != x ]; then
|
||||||
|
+ GRUB_CMDLINE_LINUX="rootflags=subvol=${rootsubvol} ${GRUB_CMDLINE_LINUX}"
|
||||||
|
+ fi
|
||||||
|
+fi
|
||||||
|
+
|
||||||
|
linux_entry ()
|
||||||
|
{
|
||||||
|
os="$1"
|
1
debian/patches/series
vendored
1
debian/patches/series
vendored
@ -16,3 +16,4 @@ branch_squash.patch
|
|||||||
branch_longlinuxcmd.patch
|
branch_longlinuxcmd.patch
|
||||||
branch_parse-color.patch
|
branch_parse-color.patch
|
||||||
branch_embed-sectors.patch
|
branch_embed-sectors.patch
|
||||||
|
btrfs_rootflags.patch
|
||||||
|
Loading…
Reference in New Issue
Block a user