From 47c8cb8c78fbace1e5edb2107fc1c4dcbe7058be Mon Sep 17 00:00:00 2001 From: Manuel Bentele Date: Thu, 27 Aug 2020 11:02:30 +0200 Subject: [KERNEL] convert to blk-mq and ktime This converts the dnbd3 kernel module driver to use the blk-mq infrastructure, which allows the dnbd3 kernel module driver to be compatible with Linux kernels in version 5.x or later. The conversion of the implementation uses one hardware queue to preserve the existing send/receive and load-balancing logic, but can be scaled up in the future. In addition to that, time measurements in the implementation are converted to ktime based accessors to replace the use of deprecated time interfaces. --- src/kernel/dnbd3.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/kernel/dnbd3.h') diff --git a/src/kernel/dnbd3.h b/src/kernel/dnbd3.h index f8af69f..aceb853 100644 --- a/src/kernel/dnbd3.h +++ b/src/kernel/dnbd3.h @@ -25,6 +25,7 @@ #include #include #include +#include #include #define KERNEL_MODULE @@ -46,6 +47,8 @@ typedef struct { // block struct gendisk *disk; + struct blk_mq_tag_set tag_set; + struct request_queue *queue; spinlock_t blk_lock; // sysfs -- cgit v1.2.3-55-g7522