diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2020-01-03 12:11:30 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2020-01-03 12:11:30 -0800 |
commit | b6b4aafc99d7c8dbf7d9429bf054b591daab1ad0 (patch) | |
tree | e385372876aa314701286d3c1e807a534840fc2b /drivers/block | |
parent | bed723519a72c0f68fbfaf68ed5bf55d04e46566 (diff) | |
parent | c7d776f85dfe5159ebf621ee1e50e555237b1a25 (diff) | |
download | linux-b6b4aafc99d7c8dbf7d9429bf054b591daab1ad0.tar.bz2 |
Merge tag 'block-5.5-20200103' of git://git.kernel.dk/linux-block
Pull block fixes from Jens Axboe:
"Three fixes in here:
- Fix for a missing split on default memory boundary mask (4G) (Ming)
- Fix for multi-page read bio truncate (Ming)
- Fix for null_blk zone close request handling (Damien)"
* tag 'block-5.5-20200103' of git://git.kernel.dk/linux-block:
null_blk: Fix REQ_OP_ZONE_CLOSE handling
block: fix splitting segments on boundary masks
block: add bio_truncate to fix guard_bio_eod
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/null_blk_zoned.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/block/null_blk_zoned.c b/drivers/block/null_blk_zoned.c index d4d88b581822..5cf49d9db95e 100644 --- a/drivers/block/null_blk_zoned.c +++ b/drivers/block/null_blk_zoned.c @@ -186,7 +186,10 @@ static blk_status_t null_zone_mgmt(struct nullb_cmd *cmd, enum req_opf op, if (zone->cond == BLK_ZONE_COND_FULL) return BLK_STS_IOERR; - zone->cond = BLK_ZONE_COND_CLOSED; + if (zone->wp == zone->start) + zone->cond = BLK_ZONE_COND_EMPTY; + else + zone->cond = BLK_ZONE_COND_CLOSED; break; case REQ_OP_ZONE_FINISH: if (zone->type == BLK_ZONE_TYPE_CONVENTIONAL) |