aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/raid1.c
diff options
context:
space:
mode:
authorBart Van Assche <[email protected]>2025-02-12 17:11:07 +0000
committerYu Kuai <[email protected]>2025-02-13 17:29:33 +0000
commitfbe8f2fa971c537571994a0df532c511c4fb5537 (patch)
tree8ff4117ec07e047b0cd4fa26116c9a4e748d7f4f /drivers/md/raid1.c
parentMerge tag 'md-6.14-20250206' of https://git.kernel.org/pub/scm/linux/kernel/g... (diff)
downloadkernel-fbe8f2fa971c537571994a0df532c511c4fb5537.tar.gz
kernel-fbe8f2fa971c537571994a0df532c511c4fb5537.zip
md/raid*: Fix the set_queue_limits implementations
queue_limits_cancel_update() must only be called if queue_limits_start_update() is called first. Remove the queue_limits_cancel_update() calls from the raid*_set_limits() functions because there is no corresponding queue_limits_start_update() call. Cc: Christoph Hellwig <[email protected]> Fixes: c6e56cf6b2e7 ("block: move integrity information into queue_limits") Signed-off-by: Bart Van Assche <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/linux-raid/[email protected]/ Signed-off-by: Yu Kuai <[email protected]>
Diffstat (limited to 'drivers/md/raid1.c')
-rw-r--r--drivers/md/raid1.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c
index 9d57a88dbd26..10ea3af40991 100644
--- a/drivers/md/raid1.c
+++ b/drivers/md/raid1.c
@@ -3219,10 +3219,8 @@ static int raid1_set_limits(struct mddev *mddev)
lim.max_write_zeroes_sectors = 0;
lim.features |= BLK_FEAT_ATOMIC_WRITES;
err = mddev_stack_rdev_limits(mddev, &lim, MDDEV_STACK_INTEGRITY);
- if (err) {
- queue_limits_cancel_update(mddev->gendisk->queue);
+ if (err)
return err;
- }
return queue_limits_set(mddev->gendisk->queue, &lim);
}