Re: [PATCH V3] block: fix the DISCARD request merge

From: Christoph Hellwig
Date: Wed Oct 24 2018 - 07:22:58 EST


> - /*
> - * not contiguous
> - */
> - if (blk_rq_pos(req) + blk_rq_sectors(req) != blk_rq_pos(next))
> - return NULL;
> -

As suggested previously I think we want something like blk_try_merge
and its return values here. Maybe a blk_try_req_merge that takes
requests instead of bios.