block: support zone append bvecs
authorJohannes Thumshirn <johannes.thumshirn@wdc.com>
Wed, 24 Mar 2021 15:47:26 +0000 (00:47 +0900)
committerJens Axboe <axboe@kernel.dk>
Wed, 24 Mar 2021 17:36:51 +0000 (11:36 -0600)
commit7de55b7d6f09a2865279d3c41c0fbdbfdb87486a
treece0b7e04c15cde537e18cbe6a5e49e7a785485b7
parenta958937ff166fc60d1c3a721036f6ff41bfa2821
block: support zone append bvecs

Christoph reported that we'll likely trigger the WARN_ON_ONCE() checking
that we're not submitting a bvec with REQ_OP_ZONE_APPEND in
bio_iov_iter_get_pages() some time ago using zoned btrfs, but I couldn't
reproduce it back then.

Now Naohiro was able to trigger the bug as well with xfstests generic/095
on a zoned btrfs.

There is nothing that prevents bvec submissions via REQ_OP_ZONE_APPEND if
the hardware's zone append limit is met.

Reported-by: Naohiro Aota <naohiro.aota@wdc.com>
Reported-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/10bd414d9326c90cd69029077db63b363854eee5.1616600835.git.johannes.thumshirn@wdc.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bio.c