diff mbox series

[100/117] ufs: Use enum sam_status where appropriate

Message ID 20210420021402.27678-10-bvanassche@acm.org
State New
Headers show
Series Make better use of static type checking | expand

Commit Message

Bart Van Assche April 20, 2021, 2:13 a.m. UTC
Make it explicit that the second ufshcd_scsi_cmd_status() argument is a
SAM status code.

Cc: Can Guo <cang@codeaurora.org>
Cc: Avri Altman <avri.altman@wdc.com>
Cc: Bean Huo <beanhuo@micron.com>
Cc: Alim Akhtar <alim.akhtar@samsung.com>
Cc: Asutosh Das <asutoshd@codeaurora.org>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
 drivers/scsi/ufs/ufshcd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Can Guo May 7, 2021, 12:01 a.m. UTC | #1
On 2021-04-20 10:13, Bart Van Assche wrote:
> Make it explicit that the second ufshcd_scsi_cmd_status() argument is a

> SAM status code.

> 

> Cc: Can Guo <cang@codeaurora.org>

> Cc: Avri Altman <avri.altman@wdc.com>

> Cc: Bean Huo <beanhuo@micron.com>

> Cc: Alim Akhtar <alim.akhtar@samsung.com>

> Cc: Asutosh Das <asutoshd@codeaurora.org>

> Signed-off-by: Bart Van Assche <bvanassche@acm.org>

> ---

>  drivers/scsi/ufs/ufshcd.c | 2 +-

>  1 file changed, 1 insertion(+), 1 deletion(-)

> 

> diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c

> index 0c2c18f2acf3..391947e4db72 100644

> --- a/drivers/scsi/ufs/ufshcd.c

> +++ b/drivers/scsi/ufs/ufshcd.c

> @@ -4898,7 +4898,7 @@ static void ufshcd_slave_destroy(struct 

> scsi_device *sdev)

>   * Returns value base on SCSI command status

>   */

>  static inline int

> -ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, int scsi_status)

> +ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, enum sam_status 

> scsi_status)

>  {

>  	int result = 0;


Reviewed-by: Can Guo <cang@codeaurora.org>
Can Guo May 7, 2021, 12:01 a.m. UTC | #2
On 2021-04-20 10:13, Bart Van Assche wrote:
> Make it explicit that the second ufshcd_scsi_cmd_status() argument is a

> SAM status code.

> 

> Cc: Can Guo <cang@codeaurora.org>

> Cc: Avri Altman <avri.altman@wdc.com>

> Cc: Bean Huo <beanhuo@micron.com>

> Cc: Alim Akhtar <alim.akhtar@samsung.com>

> Cc: Asutosh Das <asutoshd@codeaurora.org>

> Signed-off-by: Bart Van Assche <bvanassche@acm.org>

> ---

>  drivers/scsi/ufs/ufshcd.c | 2 +-

>  1 file changed, 1 insertion(+), 1 deletion(-)

> 

> diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c

> index 0c2c18f2acf3..391947e4db72 100644

> --- a/drivers/scsi/ufs/ufshcd.c

> +++ b/drivers/scsi/ufs/ufshcd.c

> @@ -4898,7 +4898,7 @@ static void ufshcd_slave_destroy(struct 

> scsi_device *sdev)

>   * Returns value base on SCSI command status

>   */

>  static inline int

> -ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, int scsi_status)

> +ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, enum sam_status 

> scsi_status)

>  {

>  	int result = 0;


Reviewed-by: Can Guo <cang@codeaurora.org>
diff mbox series

Patch

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 0c2c18f2acf3..391947e4db72 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -4898,7 +4898,7 @@  static void ufshcd_slave_destroy(struct scsi_device *sdev)
  * Returns value base on SCSI command status
  */
 static inline int
-ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, int scsi_status)
+ufshcd_scsi_cmd_status(struct ufshcd_lrb *lrbp, enum sam_status scsi_status)
 {
 	int result = 0;