Message ID | 20240827175340.GB1977952@frogsfrogsfrogs |
---|---|
State | New |
Headers | show |
Series | block: fix detection of unsupported WRITE SAME in blkdev_issue_write_zeroes | expand |
diff --git a/block/blk-lib.c b/block/blk-lib.c index 83eb7761c2bfb..4c9f20a689f7b 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c @@ -174,7 +174,7 @@ static int blkdev_issue_write_zeroes(struct block_device *bdev, sector_t sector, * on an I/O error, in which case we'll turn any error into * "not supported" here. */ - if (ret && !limit) + if (ret && !bdev_write_zeroes_sectors(bdev)) return -EOPNOTSUPP; return ret; }