diff --git a/0001-Fix-unknown-SAS-device-sysfs-parsing.patch b/0001-Fix-unknown-SAS-device-sysfs-parsing.patch new file mode 100644 index 0000000..55161b9 --- /dev/null +++ b/0001-Fix-unknown-SAS-device-sysfs-parsing.patch @@ -0,0 +1,34 @@ +From 7a9697eae467fc0ed44022d948f70f30d156d69e Mon Sep 17 00:00:00 2001 +From: Adam Williamson +Date: Fri, 11 Nov 2016 12:36:12 -0500 +Subject: [PATCH] Fix "unknown" SAS device sysfs parsing. + +Since the regexp matches the device type as well as the identifying +numbers, we need to pull the numbers from match groups 2 and 3, not 1 +and 2. + +Resolves: rhbz#1394026 + +Signed-off-by: Peter Jones +--- + blivet/devicelibs/edd.py | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/blivet/devicelibs/edd.py b/blivet/devicelibs/edd.py +index 7a1a1e2..51b7ed8 100644 +--- a/blivet/devicelibs/edd.py ++++ b/blivet/devicelibs/edd.py +@@ -316,8 +316,8 @@ class EddEntry(object): + self.sas_address = int(sas_match.group(1), base=16) + self.sas_lun = int(sas_match.group(2), base=16) + elif unknown_match: +- self.sas_address = int(unknown_match.group(1), base=16) +- self.sas_lun = int(unknown_match.group(2), base=16) ++ self.sas_address = int(unknown_match.group(2), base=16) ++ self.sas_lun = int(unknown_match.group(3), base=16) + else: + log.warning("edd: can not match interface for %s: %s", + self.sysfspath, interface) +-- +2.7.4 + diff --git a/python-blivet.spec b/python-blivet.spec index 1328152..3f6c668 100644 --- a/python-blivet.spec +++ b/python-blivet.spec @@ -5,7 +5,7 @@ Version: 2.1.7 #%%global prerelease .b1 # prerelease, if defined, should be something like .a1, .b1, .b2.dev1, or .c2 -Release: 1%{?prerelease}%{?dist} +Release: 2%{?prerelease}%{?dist} Epoch: 1 License: LGPLv2+ Group: System Environment/Libraries @@ -13,6 +13,8 @@ Group: System Environment/Libraries %global realversion %{version}%{?prerelease} Source0: http://github.com/rhinstaller/blivet/archive/%{realname}-%{realversion}.tar.gz +Patch0: 0001-Fix-unknown-SAS-device-sysfs-parsing.patch + # Versions of required components (done so we make sure the buildrequires # match the requires versions of things). %global pykickstartver 1.99.22 @@ -61,6 +63,7 @@ configuration. %prep %setup -q -n %{realname}-%{realversion} +%patch0 -p1 rm -rf %{py3dir} cp -a . %{py3dir} @@ -80,6 +83,9 @@ make PYTHON=%{__python3} DESTDIR=%{buildroot} install %{python3_sitelib}/* %changelog +* Mon Nov 21 2016 Vratislav Podzimek - 2.1.7-2 +- Fix "unknown" SAS device sysfs parsing. (#1394026) (awilliam) + * Mon Nov 21 2016 Vratislav Podzimek - 2.1.7-1 - Require BlockDev 2.0 in the gi.require_version() call (vpodzime) - Fix detection of 'macefi' partitions (#1393846) (awilliam)