Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VNmPg-0004j2-Hu for mharc-grub-devel@gnu.org; Sun, 22 Sep 2013 12:21:36 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56045) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VNmPV-0004hi-SS for grub-devel@gnu.org; Sun, 22 Sep 2013 12:21:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VNmPN-0004TZ-El for grub-devel@gnu.org; Sun, 22 Sep 2013 12:21:25 -0400 Received: from mail-la0-x236.google.com ([2a00:1450:4010:c03::236]:58894) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VNmPN-0004TS-6Z for grub-devel@gnu.org; Sun, 22 Sep 2013 12:21:17 -0400 Received: by mail-la0-f54.google.com with SMTP id ea20so1807257lab.13 for ; Sun, 22 Sep 2013 09:21:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id; bh=rcIAf91zWZtBnKLuxK7ZVEUyZZmINMJ8IqMKQ3Hmp4k=; b=qHT36D4l8BqL3L2O4tV3qhSACu0klS2MqaQ0S+bxRa0L0hPnC7UypnXVgNNPIS5Rzx qJ59FmIrH1/O53j1FwPgK2dB7FCp7BkjXDVz4rQpkHOIvnz8Ikwep1qIUh0wBZYrJuZt M4tRqVifAl8Haf4o+oCHYz9Ne2u+op1oIyahGFBnDlo+wmUw3YEzA8gamskTNL+TdAqV 9rEKV/V+Bp7QE//5RcFlFB1VSIEm/+dugkTVu8I+J+HGA+XLdTnV3IllTWbORYz2/yWY IYZc4b8ZIcVaup99HAR++kd+VMj9GpSckwzcjY/GwEsl1TGZxcLUGUf1A72KvUDqeoEl IdWw== X-Received: by 10.152.228.130 with SMTP id si2mr1360917lac.32.1379866875184; Sun, 22 Sep 2013 09:21:15 -0700 (PDT) Received: from localhost.localdomain (ppp91-76-150-246.pppoe.mtu-net.ru. [91.76.150.246]) by mx.google.com with ESMTPSA id yl7sm10260087lbb.0.1969.12.31.16.00.00 (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 22 Sep 2013 09:21:14 -0700 (PDT) From: Andrey Borzenkov To: grub-devel@gnu.org Subject: [PATCH] LVM UUID grub-probe fix and documentation update Date: Sun, 22 Sep 2013 20:21:08 +0400 Message-Id: <1379866868-15811-1-git-send-email-arvidjaar@gmail.com> X-Mailer: git-send-email 1.8.1.4 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::236 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Sep 2013 16:21:34 -0000 1. Update documentation to mention it. Also fix docs (lv => lvm). 2. Fix grub-probe -t abstraction not returning anything for LVM - as it now prefers LVM UUID based devices, also check for correct name. Signed-off-by: Andrey Borzenkov --- docs/grub.texi | 8 +++++--- util/grub-probe.c | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/grub.texi b/docs/grub.texi index 894b97f..574f602 100644 --- a/docs/grub.texi +++ b/docs/grub.texi @@ -2484,7 +2484,7 @@ by a digit, like @samp{fd0}, or @samp{cd}. AHCI, PATA (ata), crypto, USB use the name of driver followed by a number. Memdisk and host are limited to one disk and so it's refered just by driver name. -RAID (md), ofdisk (ieee1275 and nand), LVM (lv), LDM and arcdisk (arc) use +RAID (md), ofdisk (ieee1275 and nand), LVM (lvm), LDM and arcdisk (arc) use intrinsic name of disk prefixed by driver name. Additionally just ``nand'' refers to the disk aliased as ``nand''. Conflicts are solved by suffixing a number if necessarry. @@ -2493,7 +2493,8 @@ Loopback uses whatever name specified to @command{loopback} command. Hostdisk uses names specified in device.map as long as it's of the form [fhc]d[0-9]* or hostdisk/. For crypto and RAID (md) additionally you can use the syntax -uuid/. +uuid/. For LVM additionally you can use the syntax +lvmid//. @example (fd0) @@ -2505,7 +2506,8 @@ For crypto and RAID (md) additionally you can use the syntax (usb0) (cryptouuid/123456789abcdef0123456789abcdef0) (mduuid/123456789abcdef0123456789abcdef0) -(lv/system-root) +(lvm/system-root) +(lvmid/F1ikgD-2RES-306G-il9M-7iwa-4NKW-EbV1NV/eLGuCQ-L4Ka-XUgR-sjtJ-ffch-bajr-fCNfz5) (md/myraid) (md/0) (ieee1275/disk2) diff --git a/util/grub-probe.c b/util/grub-probe.c index a46f0b1..0978e0a 100644 --- a/util/grub-probe.c +++ b/util/grub-probe.c @@ -292,7 +292,8 @@ probe_abstraction (grub_disk_t disk) } if (disk->dev->id == GRUB_DISK_DEVICE_DISKFILTER_ID - && grub_memcmp (disk->name, "lvm/", sizeof ("lvm/") - 1) == 0) + && (grub_memcmp (disk->name, "lvm/", sizeof ("lvm/") - 1) == 0 || + grub_memcmp (disk->name, "lvmid/", sizeof ("lvmid/") - 1) == 0)) printf ("lvm "); if (disk->dev->id == GRUB_DISK_DEVICE_DISKFILTER_ID -- tg: (4ae2625..) u/lvm-uuid (depends on: master)