Skip to content

Commit 396a27e

Browse files
damien-lemoalMikulas Patocka
authored andcommitted
dm: Remove max_write_zeroes_granularity
The max_write_zeroes_granularity boolean of struct dm_target is used in __process_abnormal_io() but never set by any target. Remove this field and the dead code using it. Signed-off-by: Damien Le Moal <[email protected]> Signed-off-by: Mikulas Patocka <[email protected]>
1 parent 7017ded commit 396a27e

File tree

2 files changed

+0
-8
lines changed

2 files changed

+0
-8
lines changed

drivers/md/dm.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1664,8 +1664,6 @@ static blk_status_t __process_abnormal_io(struct clone_info *ci,
16641664
case REQ_OP_WRITE_ZEROES:
16651665
num_bios = ti->num_write_zeroes_bios;
16661666
max_sectors = limits->max_write_zeroes_sectors;
1667-
if (ti->max_write_zeroes_granularity)
1668-
max_granularity = max_sectors;
16691667
break;
16701668
default:
16711669
break;

include/linux/device-mapper.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -369,12 +369,6 @@ struct dm_target {
369369
*/
370370
bool max_secure_erase_granularity:1;
371371

372-
/*
373-
* Set if this target requires that write_zeroes be split on
374-
* 'max_write_zeroes_sectors' boundaries.
375-
*/
376-
bool max_write_zeroes_granularity:1;
377-
378372
/*
379373
* Set if we need to limit the number of in-flight bios when swapping.
380374
*/

0 commit comments

Comments
 (0)