[Devel] [PATCH RHEL COMMIT] dm: Introduce dm_requeue_original_rq()
Konstantin Khorenko
khorenko at virtuozzo.com
Wed Sep 22 14:39:55 MSK 2021
The commit is pushed to "branch-rh9-5.14.vz9.1.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after ark-5.14
------>
commit 0b2be627e4d491ca4568b48c7a5209fc3bf257ab
Author: Kirill Tkhai <ktkhai at virtuozzo.com>
Date: Wed Sep 22 14:39:54 2021 +0300
dm: Introduce dm_requeue_original_rq()
Introduce a helper to requeue request by rq.
https://jira.sw.ru/browse/PSBM-127989
Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
drivers/md/dm-rq.c | 8 ++++++++
drivers/md/dm-rq.h | 1 +
2 files changed, 9 insertions(+)
diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c
index 1e7be9e4833d..447df80adac5 100644
--- a/drivers/md/dm-rq.c
+++ b/drivers/md/dm-rq.c
@@ -201,6 +201,14 @@ static void dm_requeue_original_request(struct dm_rq_target_io *tio, bool delay_
rq_completed(md);
}
+void dm_requeue_original_rq(struct request *rq)
+{
+ struct dm_rq_target_io *tio = tio_from_request(rq);
+
+ dm_requeue_original_request(tio, false);
+}
+EXPORT_SYMBOL(dm_requeue_original_rq);
+
static void dm_done(struct request *clone, blk_status_t error, bool mapped)
{
int r = DM_ENDIO_DONE;
diff --git a/drivers/md/dm-rq.h b/drivers/md/dm-rq.h
index 56156738d1b4..bf625cbd789c 100644
--- a/drivers/md/dm-rq.h
+++ b/drivers/md/dm-rq.h
@@ -45,5 +45,6 @@ ssize_t dm_attr_rq_based_seq_io_merge_deadline_store(struct mapped_device *md,
const char *buf, size_t count);
void dm_complete_request(struct request *rq, blk_status_t error);
+void dm_requeue_original_rq(struct request *rq);
#endif
More information about the Devel
mailing list