Skip to content

Commit b72b372

Browse files
robnlundman
authored andcommitted
Linux 6.11: IO stats is now a queue feature flag
Apply them with with the rest of the settings. Reviewed-by: Tony Hutter <[email protected]> Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Rob Norris <[email protected]> Sponsored-by: https://despairlabs.com/sponsor/ Closes openzfs#16400
1 parent bdeebfd commit b72b372

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

module/os/linux/zfs/zvol_os.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1204,7 +1204,8 @@ zvol_queue_limits_convert(zvol_queue_limits_t *limits,
12041204
qlimits->max_segment_size = limits->zql_max_segment_size;
12051205
qlimits->io_opt = limits->zql_io_opt;
12061206
#ifdef HAVE_BLKDEV_QUEUE_LIMITS_FEATURES
1207-
qlimits->features = BLK_FEAT_WRITE_CACHE | BLK_FEAT_FUA;
1207+
qlimits->features =
1208+
BLK_FEAT_WRITE_CACHE | BLK_FEAT_FUA | BLK_FEAT_IO_STAT;
12081209
#endif
12091210
}
12101211
#endif
@@ -1220,6 +1221,7 @@ zvol_queue_limits_apply(zvol_queue_limits_t *limits,
12201221
blk_queue_io_opt(queue, limits->zql_io_opt);
12211222
#ifndef HAVE_BLKDEV_QUEUE_LIMITS_FEATURES
12221223
blk_queue_set_write_cache(queue, B_TRUE);
1224+
blk_queue_flag_set(QUEUE_FLAG_IO_STAT, queue);
12231225
#endif
12241226
}
12251227

@@ -1409,9 +1411,6 @@ zvol_alloc(dev_t dev, const char *name)
14091411
blk_queue_flag_set(QUEUE_FLAG_NOMERGES, zso->zvo_queue);
14101412
}
14111413

1412-
/* Enable /proc/diskstats */
1413-
blk_queue_flag_set(QUEUE_FLAG_IO_STAT, zso->zvo_queue);
1414-
14151414
zso->zvo_queue->queuedata = zv;
14161415
zso->zvo_dev = dev;
14171416
zv->zv_open_count = 0;

0 commit comments

Comments
 (0)