scsi: ufs: use existing macro CONTROLLER_ENABLE to test register bit
authorTomohiro Kusumi <tkusumi@tuxera.com>
Tue, 28 Mar 2017 13:49:25 +0000 (16:49 +0300)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 30 Mar 2017 02:42:21 +0000 (22:42 -0400)
Signed-off-by: Tomohiro Kusumi <tkusumi@tuxera.com>
Reviewed-by: Subhash Jadavani <subhashj@codeaurora.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/ufs/ufshcd.c

index b006f1e51aae291d874090d20bad8715b54357cb..dd4625919f2283f86d8a0f6cdf8574935d76678f 100644 (file)
@@ -836,7 +836,8 @@ static inline void ufshcd_hba_start(struct ufs_hba *hba)
  */
 static inline bool ufshcd_is_hba_active(struct ufs_hba *hba)
 {
-       return (ufshcd_readl(hba, REG_CONTROLLER_ENABLE) & 0x1) ? false : true;
+       return (ufshcd_readl(hba, REG_CONTROLLER_ENABLE) & CONTROLLER_ENABLE)
+               ? false : true;
 }
 
 static const char *ufschd_uic_link_state_to_string(