Re: [PATCH 2/4] blk-timeout: add BLK_EH_SCHEDULED return code

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

 



On Thu, 6 June 2013 11:43:53 +0200, Hannes Reinecke wrote:
> 
> Add a 'BLK_EH_SCHEDULED' return code for blk-timeout to indicate
> that a delayed error recovery has been initiated.
> 
> Signed-off-by: Hannes Reinecke <hare@xxxxxxx>

Since the patch I tested diverged from your patches 2-4, this is only
Acked-by: Joern Enge <joern@xxxxxxxxx>

> ---
>  drivers/scsi/scsi_error.c | 3 +++
>  include/linux/blkdev.h    | 1 +
>  2 files changed, 4 insertions(+)
> 
> diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c
> index f43de1e..96b4bb6 100644
> --- a/drivers/scsi/scsi_error.c
> +++ b/drivers/scsi/scsi_error.c
> @@ -146,6 +146,9 @@ enum blk_eh_timer_return scsi_times_out(struct request *req)
>  		rtn = host->hostt->eh_timed_out(scmd);
>  
>  	scmd->result |= DID_TIME_OUT << 16;
> +	/* Check for delayed EH scheduling */
> +	if (rtn == BLK_EH_SCHEDULED)
> +		return BLK_EH_NOT_HANDLED;
>  
>  	if (unlikely(rtn == BLK_EH_NOT_HANDLED &&
>  		     !scsi_eh_scmd_add(scmd, SCSI_EH_CANCEL_CMD)))
> diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
> index 2fdb4a4..d846e2b 100644
> --- a/include/linux/blkdev.h
> +++ b/include/linux/blkdev.h
> @@ -238,6 +238,7 @@ enum blk_eh_timer_return {
>  	BLK_EH_NOT_HANDLED,
>  	BLK_EH_HANDLED,
>  	BLK_EH_RESET_TIMER,
> +	BLK_EH_SCHEDULED,
>  };
>  
>  typedef enum blk_eh_timer_return (rq_timed_out_fn)(struct request *);
> -- 
> 1.7.12.4
> 

Jörn

--
Geld macht nicht glücklich.
Glück macht nicht satt.
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux