Re: [PATCH 02/47] block: fix blk_abort_request for blk-mq drivers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Christoph Hellwig <hch@xxxxxx> writes:

> We only added the request to the request list for the !blk-mq case,
> so we should only delete it in that case as well.

Sorry, I don't follow.  Do you mean the timeout_list?  It appears to me
that blk_add_timer is called for both the old and mq paths.

-Jeff

> Signed-off-by: Christoph Hellwig <hch@xxxxxx>
> ---
>  block/blk-timeout.c | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/block/blk-timeout.c b/block/blk-timeout.c
> index 246dfb1..aa40aa9 100644
> --- a/block/blk-timeout.c
> +++ b/block/blk-timeout.c
> @@ -158,11 +158,13 @@ void blk_abort_request(struct request *req)
>  {
>  	if (blk_mark_rq_complete(req))
>  		return;
> -	blk_delete_timer(req);
> -	if (req->q->mq_ops)
> +
> +	if (req->q->mq_ops) {
>  		blk_mq_rq_timed_out(req, false);
> -	else
> +	} else {
> +		blk_delete_timer(req);
>  		blk_rq_timed_out(req);
> +	}
>  }
>  EXPORT_SYMBOL_GPL(blk_abort_request);
--
To unsubscribe from this list: send the line "unsubscribe linux-block" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux