Skip to content

Commit 5be7b96

Browse files
committed
use new backing dev info
Signed-off-by: YangKeao <[email protected]>
1 parent fc7d656 commit 5be7b96

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

driver/ioem.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ static int ioem_mq_init_hctx(struct blk_mq_hw_ctx *hctx, unsigned int hctx_idx)
531531
#if LINUX_VERSION_CODE > KERNEL_VERSION(5, 15, 0)
532532
id->device = hctx->queue->disk->bdi->dev->devt;
533533
#elif LINUX_VERSION_CODE > KERNEL_VERSION(4, 0, 0)
534-
id->device = hctx->queue->backing_dev_info->dev->devt;
534+
id->device = hctx->queue->backing_dev_info->owner->devt;
535535
#else
536536
id->device = hctx->queue->backing_dev_info.dev->devt;
537537
#endif
@@ -1097,7 +1097,7 @@ static bool ioem_should_inject(struct ioem_data* id, struct request* rq, struct
10971097
return 0;
10981098
}
10991099

1100-
if (e->arg.device != 0 && e->arg.device == id->device) {
1100+
if (e->arg.device != 0 && e->arg.device != id->device) {
11011101
return 0;
11021102
}
11031103

0 commit comments

Comments
 (0)