Subject: Re: [PATCH v4 29/32] cxlflash: Fix to double the delay each time

From: Daniel Axtens <[email-masked]>
Date: Tue, 29 Sep 2015 11:40:32 +1000

=2D----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

"Matthew R. Ochs" <[email-masked]> writes:

> From: Manoj Kumar <[email-masked]>
>
> The operator used to double the delay is incorrect and
> does not result in delay doubling.
>
> To fix, use a left shift instead of the XOR operator.
>
I can see that the patch is correct, but this commit message is a bit
confusing. What delay? In what circumstances are you doubling it? Why?

Regards,
Daniel

> Reported-by: Tomas Henzl <[email-masked]>
> Signed-off-by: Matthew R. Ochs <[email-masked]>
> Signed-off-by: Manoj N. Kumar <[email-masked]>
> Reviewed-by: Brian King <[email-masked]>
> ---
>  drivers/scsi/cxlflash/main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/scsi/cxlflash/main.c b/drivers/scsi/cxlflash/main.c
> index ab11ee6..be78906 100644
> --- a/drivers/scsi/cxlflash/main.c
> +++ b/drivers/scsi/cxlflash/main.c
> @@ -303,7 +303,7 @@ write_rrin:
>  		if (rrin !=3D 0x1)
>  			break;
>  		/* Double delay each time */
> -		udelay(2 ^ nretry);
> +		udelay(2 << nretry);
>  	} while (nretry++ < MC_ROOM_RETRY_CNT);
>  }
>=20=20
> --=20
> 2.1.0
=2D----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: GPGTools - https://gpgtools.org

=3DKm/z
=2D----END PGP SIGNATURE-----