From 61b1e08dc6cbcdf731166498912826d7b0331747 Mon Sep 17 00:00:00 2001 From: Eugene Syromiatnikov Date: Mon, 21 Feb 2022 22:16:20 +0100 Subject: [PATCH] Update bdi->capabilities assignment due to change in the value semantics Commit kernel-4.18.0-361.el8~13^2~6 ("bdi: replace BDI_CAP_NO_{WRITEBACK,ACCT_DIRTY} with a single flag", upstream commit f56753ac2a90) has changed the semantics of bdi->capabilities without any oracleasm-tangible kABI effect (by virtue of being a change of macro values; the accompying function change has not have any effect as oracleasm kmod doesn't utilise any of them). Update the capabilities value to a new one. * 0004-update-bdi-writeback-acct_dirty-flags.patch: New file. * kmod-redhat-oracleasm.spec (kmod_rpm_release): Bump to 13. (kmod_kernel_version): Bump to 4.18.0-369.el8. (kmod_kernel_version_min): Bump to 4.18.0-361.el8. (Patch4): New patch. (%prep): Apply it. (%changelog): Mention it. Resolves: #2228579 Signed-off-by: Eugene Syromiatnikov --- ...pdate-bdi-writeback-acct_dirty-flags.patch | 19 +++++++++++++++++++ kmod-redhat-oracleasm.spec | 12 +++++++++--- 2 files changed, 28 insertions(+), 3 deletions(-) create mode 100644 0004-update-bdi-writeback-acct_dirty-flags.patch diff --git a/0004-update-bdi-writeback-acct_dirty-flags.patch b/0004-update-bdi-writeback-acct_dirty-flags.patch new file mode 100644 index 0000000..ea6e90b --- /dev/null +++ b/0004-update-bdi-writeback-acct_dirty-flags.patch @@ -0,0 +1,19 @@ +Commit kernel-4.18.0-361.el8~13^2~6 ("bdi: replace +BDI_CAP_NO_{WRITEBACK,ACCT_DIRTY} with a single flag", upstream commit +f56753ac2a90) has changed the semantics of bdi->capabilities without +any oracleasm-tangible kABI effect (by virtue of being a change of macro +values; the accompying function change has not have any effect as oracleasm +kmod doesn't utilise any of them). Update the capabilities value to a new one. +Index: oracleasm-redhat-2.0.8/drivers/block/oracleasm/driver.c +=================================================================== +--- oracleasm-redhat-2.0.8.orig/drivers/block/oracleasm/driver.c 2022-02-21 22:04:43.375816985 +0100 ++++ oracleasm-redhat-2.0.8/drivers/block/oracleasm/driver.c 2022-02-21 22:05:36.277381843 +0100 +@@ -726,7 +726,7 @@ + struct backing_dev_info *bdi = inode_to_bdi(inode); + + bdi->ra_pages = 0; /* No readahead */ +- bdi->capabilities = BDI_CAP_NO_ACCT_DIRTY | BDI_CAP_NO_WRITEBACK; ++ bdi->capabilities = 0; + + BUG_ON(atomic_read(&d->d_ios) != 0); + BUG_ON(d->d_live); diff --git a/kmod-redhat-oracleasm.spec b/kmod-redhat-oracleasm.spec index ae304ff..2b4491a 100644 --- a/kmod-redhat-oracleasm.spec +++ b/kmod-redhat-oracleasm.spec @@ -3,9 +3,9 @@ %define kmod_rpm_name kmod-redhat-oracleasm %define kmod_driver_version 2.0.8 %define kmod_driver_epoch 8 -%define kmod_rpm_release 12 -%define kmod_kernel_version 4.18.0-321.el8 -%define kmod_kernel_version_min 4.18.0-321.el8 +%define kmod_rpm_release 13 +%define kmod_kernel_version 4.18.0-369.el8 +%define kmod_kernel_version_min 4.18.0-361.el8 %define kmod_kernel_version_dep 4.18.0 %define kmod_kbuild_dir drivers/block/oracleasm %define kmod_install_path extra/kmod-redhat-oracleasm @@ -27,6 +27,7 @@ Patch0: 0000-Makefile-config-opts.patch #Patch1: 0001-oracleasm-driver-replace-fs_context-with-mount_pseud.patch Patch2: 0002-oracleasm-driver-make-bio_for_each_segment_all-worki.patch Patch3: 0003-oracleasm-copy-rhel8-s-bio_map_user_iov.patch +Patch4: 0004-update-bdi-writeback-acct_dirty-flags.patch %define findpat %( echo "%""P" ) %define __find_requires /usr/lib/rpm/redhat/find-requires.ksyms @@ -151,6 +152,7 @@ exit 0 #%patch1 -p1 %patch2 -p1 %patch3 -p1 +%patch4 -p1 set -- * mkdir source mv "$@" source/ @@ -213,6 +215,10 @@ install -m 644 -D source/greylist.txt $RPM_BUILD_ROOT/usr/share/doc/%{kmod_rpm_n rm -rf $RPM_BUILD_ROOT %changelog +* Mon Feb 21 2022 Eugene Syromiatnikov 2.0.8-13 +- Update bdi->capabilities assignment due to change in the value semantics + (#2060479). + * Tue Jul 13 2021 Eugene Syromiatnikov 2.0.8-12 - Rebuild against kernel-4.18.0-321.el8.