Blame SOURCES/0018-libparted-Stop-converting-.-in-sys-path-to.patch

003ee8
From 6dc72201ff5b41c171863e6b8eb069b8f8c479cf Mon Sep 17 00:00:00 2001
003ee8
From: "Brian C. Lane" <bcl@redhat.com>
003ee8
Date: Fri, 7 Aug 2015 13:59:58 -0700
003ee8
Subject: [PATCH 18/18] libparted: Stop converting . in sys path to /
003ee8
003ee8
In _probe_sys_block it claimed that ! and . are replaced by / in sys
003ee8
paths, but according to the kernel code only ! is replaced (for cciss
003ee8
devices).
003ee8
003ee8
This is now causing problems with libnvdimm devices, the details are
003ee8
here:
003ee8
003ee8
https://git.kernel.org/cgit/linux/kernel/git/djbw/nvdimm.git/tree/Documentation/nvdimm/nvdimm.txt?h=libnvdimm-for-next
003ee8
(cherry picked from commit 579bd6878b07d8387451d36106ccf86d26818b77)
003ee8
---
003ee8
 libparted/arch/linux.c | 4 ++--
003ee8
 1 file changed, 2 insertions(+), 2 deletions(-)
003ee8
003ee8
diff --git a/libparted/arch/linux.c b/libparted/arch/linux.c
003ee8
index d33c02d..20a7235 100644
003ee8
--- a/libparted/arch/linux.c
003ee8
+++ b/libparted/arch/linux.c
003ee8
@@ -2235,9 +2235,9 @@ _probe_sys_block ()
003ee8
 
003ee8
 		strcpy (dev_name, "/dev/");
003ee8
 		strcat (dev_name, dirent->d_name);
003ee8
-		/* in /sys/block, '/'s are replaced with '!' or '.' */
003ee8
+		/* in /sys/block, '/'s are replaced with '!' */
003ee8
 		for (ptr = dev_name; *ptr != '\0'; ptr++) {
003ee8
-			if (*ptr == '!' || *ptr == '.')
003ee8
+			if (*ptr == '!')
003ee8
 				*ptr = '/';
003ee8
 		}
003ee8
 		_ped_device_probe (dev_name);
003ee8
-- 
003ee8
2.4.3
003ee8