]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: ufs: fix static checker errors in ufshcd_system_suspend
authorDolev Raviv <draviv@codeaurora.org>
Thu, 23 Oct 2014 10:25:14 +0000 (13:25 +0300)
committerChristoph Hellwig <hch@lst.de>
Thu, 20 Nov 2014 16:47:41 +0000 (17:47 +0100)
commit5dd05414dda340791ec6f527a1a6c48bb323db9b
treeb81879930e1a5b11820b15c08847ef1fb67ef1c2
parentbb428a4901f19da1627697c7f45454d9e4d12fbf
scsi: ufs: fix static checker errors in ufshcd_system_suspend

This patch fixes newly introduced sparse warning in
ufshcd_system_suspend, introduced by UFS power management series.

Sparse warning:
drivers/scsi/ufs/ufshcd.c:5118 ufshcd_system_suspend()
error: we previously assumed 'hba' could be null (see line 5089)

To fix it, we return 0 in case HBA is not initialized or is
not powered.

Signed-off-by: Dolev Raviv <draviv@codeaurora.org>
Reviewed-by: Maya Erez <merez@codeaurora.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/scsi/ufs/ufshcd.c