Commit c6a657d9 authored by John Garry's avatar John Garry Committed by Mikulas Patocka
Browse files

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: default avatarJohn Garry <john.g.garry@oracle.com>
Reviewed-by: default avatarMike Snitzer <snitzer@kernel.org>
Signed-off-by: default avatarMikulas Patocka <mpatocka@redhat.com>
parent 30b88ed0
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -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);
}