Re: [PATCH 02/15] megaraid_sas: set minimum value of resetwaittime to be 1 secs

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

 



On 06/30/2017 10:29 AM, Shivasharan S wrote:
> Setting resetwaittime to 0 will result in driver not calling the OCR
> during a FW fault state.
> 
> Signed-off-by: Kashyap Desai <kashyap.desai@xxxxxxxxxxxx>
> Signed-off-by: Shivasharan S <shivasharan.srikanteshwara@xxxxxxxxxxxx>
> Cc: stable@xxxxxxxxxxxxxxx
> ---
>  drivers/scsi/megaraid/megaraid_sas_base.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c b/drivers/scsi/megaraid/megaraid_sas_base.c
> index 316c3df..395c3aa 100644
> --- a/drivers/scsi/megaraid/megaraid_sas_base.c
> +++ b/drivers/scsi/megaraid/megaraid_sas_base.c
> @@ -5478,7 +5478,8 @@ static int megasas_init_fw(struct megasas_instance *instance)
>  		instance->throttlequeuedepth =
>  				MEGASAS_THROTTLE_QUEUE_DEPTH;
>  
> -	if (resetwaittime > MEGASAS_RESET_WAIT_TIME)
> +	if ((resetwaittime < 1) ||
> +	    (resetwaittime > MEGASAS_RESET_WAIT_TIME))
>  		resetwaittime = MEGASAS_RESET_WAIT_TIME;
>  
>  	if ((scmd_timeout < 10) || (scmd_timeout > MEGASAS_DEFAULT_CMD_TIMEOUT))
> 
Reviewed-by: Hannes Reinecke <hare@xxxxxxxx>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		   Teamlead Storage & Networking
hare@xxxxxxx			               +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton
HRB 21284 (AG Nürnberg)



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]