diff --git a/kvdo.spec b/kvdo.spec index 90444000..1b6ee07d 100644 --- a/kvdo.spec +++ b/kvdo.spec @@ -1,6 +1,6 @@ %define spec_release 1 %define kmod_name kvdo -%define kmod_driver_version 8.2.4.15 +%define kmod_driver_version 8.2.5.2 %define kmod_rpm_release %{spec_release} %define kmod_kernel_version 3.10.0-693.el7 @@ -94,5 +94,5 @@ rm -rf $RPM_BUILD_ROOT %{_usr}/src/%{kmod_name}-%{version} %changelog -* Mon Jul 29 2024 - Red Hat VDO Team - 8.2.4.15-1 +* Tue Nov 05 2024 - Red Hat VDO Team - 8.2.5.2-1 - See https://github.com/dm-vdo/kvdo.git diff --git a/vdo/Makefile b/vdo/Makefile index b483e560..d7d686c3 100644 --- a/vdo/Makefile +++ b/vdo/Makefile @@ -1,4 +1,4 @@ -VDO_VERSION = 8.2.4.15 +VDO_VERSION = 8.2.5.2 SOURCES = $(notdir $(wildcard $(src)/*.c)) OBJECTS = $(SOURCES:%.c=%.o) diff --git a/vdo/dm-vdo-target.c b/vdo/dm-vdo-target.c index a4fe195b..7404cd2c 100644 --- a/vdo/dm-vdo-target.c +++ b/vdo/dm-vdo-target.c @@ -4,6 +4,9 @@ */ #include +#ifndef VDO_UPSTREAM +#include +#endif /* VDO_UPSTREAM */ #include "bio.h" #include "constants.h" @@ -91,9 +94,20 @@ static void vdo_io_hints(struct dm_target *ti, struct queue_limits *limits) * determine whether to pass down discards. The block layer splits * large discards on this boundary when this is set. */ - limits->max_discard_sectors = (vdo->device_config->max_discard_blocks - * VDO_SECTORS_PER_BLOCK); - +#ifndef VDO_UPSTREAM +#undef VDO_USE_ALTERNATE +#if (RHEL_RELEASE_CODE < RHEL_RELEASE_VERSION(9, 6)) || \ + ((RHEL_RELEASE_CODE == RHEL_RELEASE_VERSION(9, 6)) && (RHEL_RELEASE_EXTRA < 522)) +#define VDO_USE_ALTERNATE +#endif /* RHEL_RELEASE_CODE */ +#endif /* VDO_UPSTREAM */ +#ifdef VDO_USE_ALTERNATE + limits->max_discard_sectors = + (vdo->device_config->max_discard_blocks * VDO_SECTORS_PER_BLOCK); +#else + limits->max_hw_discard_sectors = + (vdo->device_config->max_discard_blocks * VDO_SECTORS_PER_BLOCK); +#endif /* * Force discards to not begin or end with a partial block by stating * the granularity is 4k. diff --git a/vdo/io-submitter.c b/vdo/io-submitter.c index 545169e8..c006a2d3 100644 --- a/vdo/io-submitter.c +++ b/vdo/io-submitter.c @@ -393,8 +393,6 @@ void vdo_submit_metadata_io(struct vio *vio, ASSERT_LOG_ONLY(!code->quiescent, "I/O not allowed in state %s", code->name); - ASSERT_LOG_ONLY(vio->bio->bi_next == NULL, - "metadata bio has no next bio"); vdo_reset_completion(completion); completion->error_handler = error_handler;