diff options
author | 2025-01-16 17:03:00 +0000 | |
---|---|---|
committer | 2025-01-17 22:24:09 +0100 | |
commit | c6a657d9683def5588aee6ed920cef61415a6a52 (patch) | |
tree | 5f706d64771cdec03fdf6ae17a30f58e4b679d9f | |
parent | dm-stripe: Enable atomic writes (diff) | |
download | wireguard-linux-c6a657d9683def5588aee6ed920cef61415a6a52.tar.xz wireguard-linux-c6a657d9683def5588aee6ed920cef61415a6a52.zip |
dm-io: Warn on creating multiple atomic write bios for a region
A region should just be for a single atomic write, so warn when we are
creating many. This should not occur if request queue limits are properly
configured.
Signed-off-by: John Garry <john.g.garry@oracle.com>
Reviewed-by: Mike Snitzer <snitzer@kernel.org>
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Diffstat (limited to '')
-rw-r--r-- | drivers/md/dm-io.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/md/dm-io.c b/drivers/md/dm-io.c index d7a8e2f40db3..c37668790577 100644 --- a/drivers/md/dm-io.c +++ b/drivers/md/dm-io.c @@ -379,6 +379,7 @@ static void do_region(const blk_opf_t opf, unsigned int region, atomic_inc(&io->count); submit_bio(bio); + WARN_ON_ONCE(opf & REQ_ATOMIC && remaining); } while (remaining); } |