diff options
Diffstat (limited to 'kernel/drivers/block/brd.c')
-rw-r--r-- | kernel/drivers/block/brd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/drivers/block/brd.c b/kernel/drivers/block/brd.c index a5880f4ab..1914c63ca 100644 --- a/kernel/drivers/block/brd.c +++ b/kernel/drivers/block/brd.c @@ -338,7 +338,7 @@ static blk_qc_t brd_make_request(struct request_queue *q, struct bio *bio) if (unlikely(bio->bi_rw & REQ_DISCARD)) { if (sector & ((PAGE_SIZE >> SECTOR_SHIFT) - 1) || - bio->bi_iter.bi_size & PAGE_MASK) + bio->bi_iter.bi_size & ~PAGE_MASK) goto io_error; discard_from_brd(brd, sector, bio->bi_iter.bi_size); goto out; |