upgrade version to 3.0.4
This commit is contained in:
parent
e3d68891d2
commit
7372b99737
@ -1,25 +0,0 @@
|
||||
From 93b0a8881790097e2b4c3116fe9af38f237fb8cc Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Tue, 2 Jun 2020 16:15:18 +0200
|
||||
Subject: [PATCH 167/193] lvm: Add missing attribute to bd_lvm_pvdata_copy in
|
||||
LVM DBUs plugin
|
||||
|
||||
---
|
||||
src/plugins/lvm-dbus.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/plugins/lvm-dbus.c b/src/plugins/lvm-dbus.c
|
||||
index 222597b..454fc78 100644
|
||||
--- a/src/plugins/lvm-dbus.c
|
||||
+++ b/src/plugins/lvm-dbus.c
|
||||
@@ -100,6 +100,7 @@ BDLVMPVdata* bd_lvm_pvdata_copy (BDLVMPVdata *data) {
|
||||
new_data->pv_name = g_strdup (data->pv_name);
|
||||
new_data->pv_uuid = g_strdup (data->pv_uuid);
|
||||
new_data->pv_free = data->pv_free;
|
||||
+ new_data->pv_size = data->pv_size;
|
||||
new_data->pe_start = data->pe_start;
|
||||
new_data->vg_name = g_strdup (data->vg_name);
|
||||
new_data->vg_uuid = g_strdup (data->vg_uuid);
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,37 +0,0 @@
|
||||
From be58ebe20fd9fdfc2db7bdd99a55eff835cef23a Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Wed, 10 Jun 2020 14:31:15 +0200
|
||||
Subject: [PATCH 184/193] module.c: Fix error message when loading module
|
||||
without options
|
||||
|
||||
Lets avoid error messages like "Failed to load the module 'kvdo'
|
||||
with options '(null)'".
|
||||
---
|
||||
src/utils/module.c | 11 ++++++++---
|
||||
1 file changed, 8 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/utils/module.c b/src/utils/module.c
|
||||
index 988f603..eb3f765 100644
|
||||
--- a/src/utils/module.c
|
||||
+++ b/src/utils/module.c
|
||||
@@ -167,9 +167,14 @@ gboolean bd_utils_load_kernel_module (const gchar *module_name, const gchar *opt
|
||||
ret = kmod_module_probe_insert_module (mod, KMOD_PROBE_FAIL_ON_LOADED,
|
||||
options, NULL, NULL, NULL);
|
||||
if (ret < 0) {
|
||||
- g_set_error (error, BD_UTILS_MODULE_ERROR, BD_UTILS_MODULE_ERROR_FAIL,
|
||||
- "Failed to load the module '%s' with options '%s': %s",
|
||||
- module_name, options, strerror_l (-ret, c_locale));
|
||||
+ if (options)
|
||||
+ g_set_error (error, BD_UTILS_MODULE_ERROR, BD_UTILS_MODULE_ERROR_FAIL,
|
||||
+ "Failed to load the module '%s' with options '%s': %s",
|
||||
+ module_name, options, strerror_l (-ret, c_locale));
|
||||
+ else
|
||||
+ g_set_error (error, BD_UTILS_MODULE_ERROR, BD_UTILS_MODULE_ERROR_FAIL,
|
||||
+ "Failed to load the module '%s': %s",
|
||||
+ module_name, strerror_l (-ret, c_locale));
|
||||
kmod_module_unref (mod);
|
||||
kmod_unref (ctx);
|
||||
freelocale (c_locale);
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,28 +0,0 @@
|
||||
From dff4f13d20e7371cd55df7aab7a1800c41e3d39b Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Mon, 29 Jun 2020 14:40:57 +0200
|
||||
Subject: [PATCH 188/193] lvm: Fix checking for LVM VDO dependencies
|
||||
|
||||
We also need to check for the LVM tools availability when checking
|
||||
for BD_LVM_TECH_VDO availability.
|
||||
---
|
||||
src/plugins/lvm.c | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/plugins/lvm.c b/src/plugins/lvm.c
|
||||
index 32ad55c..2bd7782 100644
|
||||
--- a/src/plugins/lvm.c
|
||||
+++ b/src/plugins/lvm.c
|
||||
@@ -329,7 +329,8 @@ gboolean bd_lvm_is_tech_avail (BDLVMTech tech, guint64 mode, GError **error) {
|
||||
return TRUE;
|
||||
case BD_LVM_TECH_VDO:
|
||||
return check_features (&avail_features, FEATURES_VDO_MASK, features, FEATURES_LAST, &deps_check_lock, error) &&
|
||||
- check_module_deps (&avail_module_deps, MODULE_DEPS_VDO_MASK, module_deps, MODULE_DEPS_LAST, &deps_check_lock, error);
|
||||
+ check_module_deps (&avail_module_deps, MODULE_DEPS_VDO_MASK, module_deps, MODULE_DEPS_LAST, &deps_check_lock, error) &&
|
||||
+ check_deps (&avail_deps, DEPS_LVM_MASK, deps, DEPS_LAST, &deps_check_lock, error);
|
||||
default:
|
||||
/* everything is supported by this implementation of the plugin */
|
||||
return check_deps (&avail_deps, DEPS_LVM_MASK, deps, DEPS_LAST, &deps_check_lock, error);
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,25 +0,0 @@
|
||||
From c9e76261bc52cf2360ee7f43dcdfedfa7149b30e Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Tue, 30 Jun 2020 16:05:47 +0200
|
||||
Subject: [PATCH 189/193] lvm-dbus: Fix memory leak in bd_lvm_cache_attach
|
||||
|
||||
---
|
||||
src/plugins/lvm-dbus.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/src/plugins/lvm-dbus.c b/src/plugins/lvm-dbus.c
|
||||
index fa19d1a..327969d 100644
|
||||
--- a/src/plugins/lvm-dbus.c
|
||||
+++ b/src/plugins/lvm-dbus.c
|
||||
@@ -3274,6 +3274,8 @@ gboolean bd_lvm_cache_attach (const gchar *vg_name, const gchar *data_lv, const
|
||||
lv_id = g_strdup_printf ("%s/%s", vg_name, cache_pool_lv);
|
||||
|
||||
call_lvm_obj_method_sync (lv_id, CACHE_POOL_INTF, "CacheLv", params, NULL, extra, TRUE, error);
|
||||
+ g_free (lv_id);
|
||||
+ g_free (lv_obj_path);
|
||||
return ((*error) == NULL);
|
||||
}
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,24 +0,0 @@
|
||||
From d9e8b2d43c84a664aa6a9b498047a865a1a38225 Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Tue, 30 Jun 2020 16:06:01 +0200
|
||||
Subject: [PATCH 190/193] lvm: Fix memory leak bd_lvm_cache_create_cached_lv
|
||||
|
||||
---
|
||||
src/plugins/lvm.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/plugins/lvm.c b/src/plugins/lvm.c
|
||||
index 0aae9ac..bec7656 100644
|
||||
--- a/src/plugins/lvm.c
|
||||
+++ b/src/plugins/lvm.c
|
||||
@@ -2475,6 +2475,7 @@ gboolean bd_lvm_cache_create_cached_lv (const gchar *vg_name, const gchar *lv_na
|
||||
|
||||
success = bd_lvm_lvcreate (vg_name, lv_name, data_size, NULL, slow_pvs, NULL, error);
|
||||
if (!success) {
|
||||
+ g_free (name);
|
||||
g_prefix_error (error, "Failed to create the data LV: ");
|
||||
bd_utils_report_finished (progress_id, (*error)->message);
|
||||
return FALSE;
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,52 +0,0 @@
|
||||
From 90b119f3026af68e2478450c7a71ed0fe68a9cbc Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Tue, 11 Aug 2020 18:00:57 +0200
|
||||
Subject: [PATCH 07/15] fs: Fix return values in bd_fs_ntfs_get_info
|
||||
|
||||
---
|
||||
src/plugins/fs/ntfs.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/plugins/fs/ntfs.c b/src/plugins/fs/ntfs.c
|
||||
index fdd959a..b406f41 100644
|
||||
--- a/src/plugins/fs/ntfs.c
|
||||
+++ b/src/plugins/fs/ntfs.c
|
||||
@@ -253,7 +253,7 @@ BDFSNtfsInfo* bd_fs_ntfs_get_info (const gchar *device, GError **error) {
|
||||
g_autofree gchar* mountpoint = NULL;
|
||||
|
||||
if (!check_deps (&avail_deps, DEPS_NTFSCLUSTER_MASK, deps, DEPS_LAST, &deps_check_lock, error))
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
|
||||
mountpoint = bd_fs_get_mountpoint (device, error);
|
||||
if (mountpoint != NULL) {
|
||||
@@ -270,7 +270,7 @@ BDFSNtfsInfo* bd_fs_ntfs_get_info (const gchar *device, GError **error) {
|
||||
success = bd_utils_exec_and_capture_output (args, NULL, &output, error);
|
||||
if (!success)
|
||||
/* error is already populated */
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
|
||||
ret = g_new0 (BDFSNtfsInfo, 1);
|
||||
lines = g_strsplit (output, "\n", 0);
|
||||
@@ -283,7 +283,7 @@ BDFSNtfsInfo* bd_fs_ntfs_get_info (const gchar *device, GError **error) {
|
||||
g_set_error (error, BD_FS_ERROR, BD_FS_ERROR_PARSE, "Failed to parse NTFS file system information");
|
||||
g_strfreev (lines);
|
||||
bd_fs_ntfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
|
||||
/* extract data from something like this: "bytes per volume : 998240256" */
|
||||
@@ -297,7 +297,7 @@ BDFSNtfsInfo* bd_fs_ntfs_get_info (const gchar *device, GError **error) {
|
||||
g_set_error (error, BD_FS_ERROR, BD_FS_ERROR_PARSE, "Failed to parse NTFS file system information");
|
||||
g_strfreev (lines);
|
||||
bd_fs_ntfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
|
||||
/* extract data from something like this: "bytes of free space : 992759808" */
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
@ -1,52 +0,0 @@
|
||||
From 63f5df1992b15c1d6a442f2d392fa3b92ecf7b92 Mon Sep 17 00:00:00 2001
|
||||
From: Vojtech Trefny <vtrefny@redhat.com>
|
||||
Date: Tue, 11 Aug 2020 18:04:58 +0200
|
||||
Subject: [PATCH 08/15] fs: Fix return values in bd_fs_xfs_get_info
|
||||
|
||||
---
|
||||
src/plugins/fs/xfs.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/plugins/fs/xfs.c b/src/plugins/fs/xfs.c
|
||||
index b8b4bbe..d28ce72 100644
|
||||
--- a/src/plugins/fs/xfs.c
|
||||
+++ b/src/plugins/fs/xfs.c
|
||||
@@ -274,7 +274,7 @@ BDFSXfsInfo* bd_fs_xfs_get_info (const gchar *device, GError **error) {
|
||||
if (!success) {
|
||||
/* error is already populated */
|
||||
bd_fs_xfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
|
||||
lines = g_strsplit (output, "\n", 0);
|
||||
@@ -288,7 +288,7 @@ BDFSXfsInfo* bd_fs_xfs_get_info (const gchar *device, GError **error) {
|
||||
g_set_error (error, BD_FS_ERROR, BD_FS_ERROR_PARSE, "Failed to parse xfs file system information");
|
||||
g_strfreev (lines);
|
||||
bd_fs_xfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
|
||||
/* extract data from something like this: "data = bsize=4096 blocks=262400, imaxpct=25" */
|
||||
@@ -305,7 +305,7 @@ BDFSXfsInfo* bd_fs_xfs_get_info (const gchar *device, GError **error) {
|
||||
g_set_error (error, BD_FS_ERROR, BD_FS_ERROR_PARSE, "Failed to parse xfs file system information");
|
||||
g_strfreev (lines);
|
||||
bd_fs_xfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
while (isdigit (*val_start) || isspace(*val_start))
|
||||
val_start++;
|
||||
@@ -318,7 +318,7 @@ BDFSXfsInfo* bd_fs_xfs_get_info (const gchar *device, GError **error) {
|
||||
g_set_error (error, BD_FS_ERROR, BD_FS_ERROR_PARSE, "Failed to parse xfs file system information");
|
||||
g_strfreev (lines);
|
||||
bd_fs_xfs_info_free (ret);
|
||||
- return FALSE;
|
||||
+ return NULL;
|
||||
}
|
||||
g_strfreev (lines);
|
||||
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
Binary file not shown.
BIN
libblockdev-3.0.4.tar.gz
Normal file
BIN
libblockdev-3.0.4.tar.gz
Normal file
Binary file not shown.
@ -2,25 +2,17 @@
|
||||
%define configure_opts --without-dmraid
|
||||
|
||||
Name: libblockdev
|
||||
Version: 2.28
|
||||
Release: 3
|
||||
Version: 3.0.4
|
||||
Release: 1
|
||||
Summary: libblockdev is a C library supporting GObject introspection for manipulation of block devices
|
||||
License: LGPLv2+
|
||||
URL: https://github.com/storaged-project/libblockdev
|
||||
Source0: https://github.com/storaged-project/libblockdev/releases/download/%{version}-1/%{name}-%{version}.tar.gz
|
||||
|
||||
Patch1: 0001-lvm-Add-missing-attribute-to-bd_lvm_pvdata_copy-in-L.patch
|
||||
Patch2: 0002-module.c-Fix-error-message-when-loading-module-witho.patch
|
||||
Patch3: 0003-lvm-Fix-checking-for-LVM-VDO-dependencies.patch
|
||||
Patch4: 0004-lvm-dbus-Fix-memory-leak-in-bd_lvm_cache_attach.patch
|
||||
Patch5: 0005-lvm-Fix-memory-leak-bd_lvm_cache_create_cached_lv.patch
|
||||
Patch6: 0006-fs-Fix-return-values-in-bd_fs_ntfs_get_info.patch
|
||||
Patch7: 0007-fs-Fix-return-values-in-bd_fs_xfs_get_info.patch
|
||||
|
||||
BuildRequires: make glib2-devel libyaml-devel libbytesize-devel parted-devel libuuid-devel ndctl-devel device-mapper-devel
|
||||
BuildRequires: device-mapper-devel systemd-devel nss-devel volume_key-devel >= 0.3.9-7 libblkid-devel libmount-devel
|
||||
BuildRequires: cryptsetup-devel kmod-devel libxslt glib2-doc gtk-doc python3-devel gobject-introspection-devel
|
||||
BuildRequires: autoconf-archive
|
||||
BuildRequires: autoconf-archive e2fsprogs-devel libnvme-devel keyutils-libs-devel
|
||||
Requires: btrfs-progs device-mapper device-mapper-multipath lvm2 mdadm
|
||||
Requires: device-mapper-persistent-data lvm2-dbusd >= 2.02.156 ndctl gdisk util-linux
|
||||
|
||||
@ -143,12 +135,11 @@ find %{buildroot} -type f -name "*.la" | xargs %{__rm}
|
||||
%{_libdir}/girepository*/BlockDev*.typelib
|
||||
%{_libdir}/libbd_*.so.*
|
||||
%dir %{_sysconfdir}/libblockdev
|
||||
%dir %{_sysconfdir}/libblockdev/conf.d
|
||||
%config %{_sysconfdir}/libblockdev/conf.d/00-default.cfg
|
||||
%config %{_sysconfdir}/libblockdev/conf.d/10-lvm-dbus.cfg
|
||||
%dir %{_sysconfdir}/libblockdev/3/conf.d
|
||||
%config %{_sysconfdir}/libblockdev/3/conf.d/00-default.cfg
|
||||
%config %{_sysconfdir}/libblockdev/3/conf.d/10-lvm-dbus.cfg
|
||||
|
||||
%files devel
|
||||
%doc features.rst specs.rst
|
||||
%{_libdir}/libbd_*.so
|
||||
%{_libdir}/libblockdev.so
|
||||
%{_libdir}/pkgconfig/*.pc
|
||||
@ -159,12 +150,16 @@ find %{buildroot} -type f -name "*.la" | xargs %{__rm}
|
||||
|
||||
%files tools
|
||||
%{_bindir}/lvm-cache-stats
|
||||
%{_bindir}/vfat-resize
|
||||
|
||||
%files -n python3-blockdev
|
||||
%{python3_sitearch}/gi/overrides/*
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Feb 6 2024 wangzhiqiang <wangzhiqiang95@huawei.com> - 3.0.4-1
|
||||
- upgrade version to 3.0.4
|
||||
|
||||
* Tue Jan 2 2024 liyanan <liyana61@h-partners.com> - 2.28-3
|
||||
- remove require vdo
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user