import udisks2-2.9.0-7.el8
This commit is contained in:
parent
39cdc22afa
commit
cf0f2bece9
11
SOURCES/tests-disable-zram.patch
Normal file
11
SOURCES/tests-disable-zram.patch
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
diff -up udisks-2.9.0/src/tests/dbus-tests/test_10_basic.py.bak udisks-2.9.0/src/tests/dbus-tests/test_10_basic.py
|
||||||
|
--- udisks-2.9.0/src/tests/dbus-tests/test_10_basic.py.bak 2020-05-26 14:59:20.000000000 +0200
|
||||||
|
+++ udisks-2.9.0/src/tests/dbus-tests/test_10_basic.py 2021-04-23 15:49:07.405824214 +0200
|
||||||
|
@@ -26,6 +26,7 @@ class UdisksBaseTest(udiskstestcase.Udis
|
||||||
|
elif distro in ('enterprise_linux', 'centos') and int(version) > 7:
|
||||||
|
modules.pop('bcache')
|
||||||
|
modules.pop('btrfs')
|
||||||
|
+ modules.pop('zram')
|
||||||
|
# assuming the kvdo module is typically pulled in as a vdo tool dependency
|
||||||
|
if not find_executable("vdo"):
|
||||||
|
modules.pop('vdo')
|
64
SOURCES/udisks-2.10.0-tests-drive_ata-apm.patch
Normal file
64
SOURCES/udisks-2.10.0-tests-drive_ata-apm.patch
Normal file
@ -0,0 +1,64 @@
|
|||||||
|
From c21ad308b1313a35cafa1664e5eb4772925bc005 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Tomas Bzatek <tbzatek@redhat.com>
|
||||||
|
Date: Thu, 22 Apr 2021 18:05:29 +0200
|
||||||
|
Subject: [PATCH 1/2] tests: Mark Drive.ATA tests as unstable
|
||||||
|
|
||||||
|
Some of the tests operate on physical ATA drives, comparing values between
|
||||||
|
smartctl output and udisks. Different libraries used, different approach
|
||||||
|
to retrieve some ATA features and values. Turned out this is not working
|
||||||
|
correctly on some SATA disks with each approach giving slightly different
|
||||||
|
results, presumably for the quirks in place.
|
||||||
|
---
|
||||||
|
src/tests/dbus-tests/test_drive_ata.py | 8 +++++---
|
||||||
|
1 file changed, 5 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/tests/dbus-tests/test_drive_ata.py b/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
index 3187367e..e91bd02f 100644
|
||||||
|
--- a/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
+++ b/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
@@ -4,7 +4,7 @@ import re
|
||||||
|
import unittest
|
||||||
|
import time
|
||||||
|
|
||||||
|
-from udiskstestcase import UdisksTestCase
|
||||||
|
+import udiskstestcase
|
||||||
|
|
||||||
|
SMART_CMDLINE_FAIL = 1 << 0
|
||||||
|
SMART_OPEN_READ_FAIL = 1 << 1
|
||||||
|
@@ -32,7 +32,7 @@ def _get_sata_disks():
|
||||||
|
|
||||||
|
|
||||||
|
for disk in _get_sata_disks():
|
||||||
|
- ret, out = UdisksTestCase.run_command("smartctl -a /dev/%s" % disk)
|
||||||
|
+ ret, out = udiskstestcase.UdisksTestCase.run_command("smartctl -a /dev/%s" % disk)
|
||||||
|
|
||||||
|
# Only the following bits in the exit status mean the device failed to
|
||||||
|
# provide valid SMART data, others may be set for different reasons (see
|
||||||
|
@@ -46,7 +46,7 @@ for disk in _get_sata_disks():
|
||||||
|
else:
|
||||||
|
smart_unsupported.add(disk)
|
||||||
|
|
||||||
|
-class UdisksDriveAtaTest(UdisksTestCase):
|
||||||
|
+class UdisksDriveAtaTest(udiskstestcase.UdisksTestCase):
|
||||||
|
'''Noninvasive tests for the Drive.Ata interface'''
|
||||||
|
|
||||||
|
def get_smart_setting(self, disk, attr, out_prefix):
|
||||||
|
@@ -102,6 +102,7 @@ class UdisksDriveAtaTest(UdisksTestCase)
|
||||||
|
intro_data = drive_intro.Introspect()
|
||||||
|
self.assertNotIn('interface name="org.freedesktop.UDisks2.Drive.Ata"', intro_data)
|
||||||
|
|
||||||
|
+ @udiskstestcase.tag_test(udiskstestcase.TestTags.UNSTABLE)
|
||||||
|
@unittest.skipUnless(smart_supported, "No disks supporting S.M.A.R.T. available")
|
||||||
|
def test_properties(self):
|
||||||
|
for disk in smart_supported:
|
||||||
|
@@ -148,6 +149,7 @@ class UdisksDriveAtaTest(UdisksTestCase)
|
||||||
|
# nineth field is the raw value
|
||||||
|
self.assertEqual(int(pwon_s.value / 3600), int(pwon_attr[8]))
|
||||||
|
|
||||||
|
+ @udiskstestcase.tag_test(udiskstestcase.TestTags.UNSTABLE)
|
||||||
|
@unittest.skipUnless(smart_supported, "No disks supporting S.M.A.R.T. available")
|
||||||
|
def test_smart_get_attributes(self):
|
||||||
|
for disk in smart_supported:
|
||||||
|
--
|
||||||
|
2.30.2
|
||||||
|
|
43
SOURCES/udisks-2.10.0-tests-no-dev_disk-by-path.patch
Normal file
43
SOURCES/udisks-2.10.0-tests-no-dev_disk-by-path.patch
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
From 1358d1e5208d71d5a70f17a242eda00f079a9d0b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Tomas Bzatek <tbzatek@redhat.com>
|
||||||
|
Date: Thu, 22 Apr 2021 18:20:48 +0200
|
||||||
|
Subject: [PATCH 2/2] tests: Handle missing /dev/disk/by-path gracefully
|
||||||
|
|
||||||
|
Limited testing environments may not have this path always available.
|
||||||
|
---
|
||||||
|
src/tests/dbus-tests/test_drive_ata.py | 19 +++++++++++--------
|
||||||
|
1 file changed, 11 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/tests/dbus-tests/test_drive_ata.py b/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
index e91bd02f..37740c60 100644
|
||||||
|
--- a/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
+++ b/src/tests/dbus-tests/test_drive_ata.py
|
||||||
|
@@ -20,14 +20,17 @@ DISK_PATH = "/dev/disk/by-path/"
|
||||||
|
|
||||||
|
def _get_sata_disks():
|
||||||
|
sata_disks = []
|
||||||
|
- by_path = os.listdir(DISK_PATH)
|
||||||
|
- for dev in by_path:
|
||||||
|
- if "ata" in dev and "part" not in dev:
|
||||||
|
- path = os.path.realpath(os.path.join(DISK_PATH, dev))
|
||||||
|
- name = os.path.basename(path)
|
||||||
|
- if name.startswith("sd"):
|
||||||
|
- # ignore devices like CD drives etc.
|
||||||
|
- sata_disks.append(name)
|
||||||
|
+ try:
|
||||||
|
+ by_path = os.listdir(DISK_PATH)
|
||||||
|
+ for dev in by_path:
|
||||||
|
+ if "ata" in dev and "part" not in dev:
|
||||||
|
+ path = os.path.realpath(os.path.join(DISK_PATH, dev))
|
||||||
|
+ name = os.path.basename(path)
|
||||||
|
+ if name.startswith("sd"):
|
||||||
|
+ # ignore devices like CD drives etc.
|
||||||
|
+ sata_disks.append(name)
|
||||||
|
+ except:
|
||||||
|
+ pass
|
||||||
|
return sata_disks
|
||||||
|
|
||||||
|
|
||||||
|
--
|
||||||
|
2.30.2
|
||||||
|
|
@ -20,9 +20,10 @@
|
|||||||
%define is_fedora 0%{?rhel} == 0
|
%define is_fedora 0%{?rhel} == 0
|
||||||
|
|
||||||
|
|
||||||
# bcache is not available on RHEL
|
# bcache and zram are not available on RHEL
|
||||||
%if (0%{?rhel}) || %{with_bcache} == 0
|
%if (0%{?rhel})
|
||||||
%define with_bcache 0
|
%define with_bcache 0
|
||||||
|
%define with_zram 0
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# btrfs is not available on RHEL > 7
|
# btrfs is not available on RHEL > 7
|
||||||
@ -43,7 +44,6 @@
|
|||||||
# feature parity with existing RHEL 7 packages
|
# feature parity with existing RHEL 7 packages
|
||||||
%if (0%{?rhel}) && (0%{?rhel} <= 7)
|
%if (0%{?rhel}) && (0%{?rhel} <= 7)
|
||||||
%define with_lsm 0
|
%define with_lsm 0
|
||||||
%define with_zram 0
|
|
||||||
%define with_lvmcache 0
|
%define with_lvmcache 0
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
@ -56,7 +56,7 @@
|
|||||||
Name: udisks2
|
Name: udisks2
|
||||||
Summary: Disk Manager
|
Summary: Disk Manager
|
||||||
Version: 2.9.0
|
Version: 2.9.0
|
||||||
Release: 6%{?dist}
|
Release: 7%{?dist}
|
||||||
License: GPLv2+
|
License: GPLv2+
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
URL: https://github.com/storaged-project/udisks
|
URL: https://github.com/storaged-project/udisks
|
||||||
@ -73,6 +73,9 @@ Patch13: udisks-2.9.1-iscsi-Always-flush-interface-property-changes.patch
|
|||||||
Patch14: udisks-2.9.1-zram-Always-flush-interface-property-changes.patch
|
Patch14: udisks-2.9.1-zram-Always-flush-interface-property-changes.patch
|
||||||
Patch15: udisks-2.9.2-udisksdaemonutil-Refactor-udisks_daemon_util_trigger.patch
|
Patch15: udisks-2.9.2-udisksdaemonutil-Refactor-udisks_daemon_util_trigger.patch
|
||||||
Patch16: udisks-2.9.2-udiskslinuxmanager-Trigger-uevent-after-loop-device-setup.patch
|
Patch16: udisks-2.9.2-udiskslinuxmanager-Trigger-uevent-after-loop-device-setup.patch
|
||||||
|
Patch20: udisks-2.10.0-tests-drive_ata-apm.patch
|
||||||
|
Patch21: udisks-2.10.0-tests-no-dev_disk-by-path.patch
|
||||||
|
Patch22: tests-disable-zram.patch
|
||||||
|
|
||||||
BuildRequires: glib2-devel >= %{glib2_version}
|
BuildRequires: glib2-devel >= %{glib2_version}
|
||||||
BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version}
|
BuildRequires: gobject-introspection-devel >= %{gobject_introspection_version}
|
||||||
@ -287,6 +290,9 @@ This package contains module for VDO management.
|
|||||||
%patch14 -p1
|
%patch14 -p1
|
||||||
%patch15 -p1
|
%patch15 -p1
|
||||||
%patch16 -p1
|
%patch16 -p1
|
||||||
|
%patch20 -p1
|
||||||
|
%patch21 -p1
|
||||||
|
%patch22 -p1
|
||||||
sed -i udisks/udisks2.conf.in -e "s/encryption=luks1/encryption=%{default_luks_encryption}/"
|
sed -i udisks/udisks2.conf.in -e "s/encryption=luks1/encryption=%{default_luks_encryption}/"
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@ -479,6 +485,10 @@ fi
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 23 2021 Tomas Bzatek <tbzatek@redhat.com> - 2.9.0-7
|
||||||
|
- Do not build udisks2-zram (#1923078)
|
||||||
|
- Fix Drive.ATA test failures (#1926827)
|
||||||
|
|
||||||
* Tue Jan 26 2021 Tomas Bzatek <tbzatek@redhat.com> - 2.9.0-6
|
* Tue Jan 26 2021 Tomas Bzatek <tbzatek@redhat.com> - 2.9.0-6
|
||||||
- Rebuilt for new docbook-style-xsl (#1853153)
|
- Rebuilt for new docbook-style-xsl (#1853153)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user