* [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend
@ 2014-10-05 14:10 Dolev Raviv
2014-10-05 22:44 ` Subhash Jadavani
0 siblings, 1 reply; 5+ messages in thread
From: Dolev Raviv @ 2014-10-05 14:10 UTC (permalink / raw)
To: James.Bottomley, hch; +Cc: linux-scsi, linux-arm-msm, santoshsy, Dolev Raviv
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>
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 497c38a..836ea72 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -5087,7 +5087,7 @@ int ufshcd_system_suspend(struct ufs_hba *hba)
int ret = 0;
if (!hba || !hba->is_powered)
- goto out;
+ return 0;
if (pm_runtime_suspended(hba->dev)) {
if (hba->rpm_lvl == hba->spm_lvl)
--
1.8.5.2
--
QUALCOMM ISRAEL, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation
^ permalink raw reply related [flat|nested] 5+ messages in thread
* RE: [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend
2014-10-05 14:10 [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend Dolev Raviv
@ 2014-10-05 22:44 ` Subhash Jadavani
2014-10-11 11:06 ` Christoph Hellwig
0 siblings, 1 reply; 5+ messages in thread
From: Subhash Jadavani @ 2014-10-05 22:44 UTC (permalink / raw)
To: 'Dolev Raviv', James.Bottomley, hch
Cc: linux-scsi, linux-arm-msm, santoshsy
Looks good, Reviewed-by: Subhash Jadavani <subhashj@codeaurora.org>
-----Original Message-----
From: linux-scsi-owner@vger.kernel.org
[mailto:linux-scsi-owner@vger.kernel.org] On Behalf Of Dolev Raviv
Sent: Sunday, October 05, 2014 7:10 AM
To: James.Bottomley@HansenPartnership.com; hch@infradead.org
Cc: linux-scsi@vger.kernel.org; linux-arm-msm@vger.kernel.org;
santoshsy@gmail.com; Dolev Raviv
Subject: [PATCH 1/1] ufs: scsi: fix sparse 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>
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c index
497c38a..836ea72 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -5087,7 +5087,7 @@ int ufshcd_system_suspend(struct ufs_hba *hba)
int ret = 0;
if (!hba || !hba->is_powered)
- goto out;
+ return 0;
if (pm_runtime_suspended(hba->dev)) {
if (hba->rpm_lvl == hba->spm_lvl)
--
1.8.5.2
--
QUALCOMM ISRAEL, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the
body of a message to majordomo@vger.kernel.org More majordomo info at
http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend
2014-10-05 22:44 ` Subhash Jadavani
@ 2014-10-11 11:06 ` Christoph Hellwig
2014-10-21 14:05 ` Christoph Hellwig
0 siblings, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2014-10-11 11:06 UTC (permalink / raw)
To: Subhash Jadavani
Cc: 'Dolev Raviv', James.Bottomley, hch, linux-scsi,
linux-arm-msm, santoshsy
On Sun, Oct 05, 2014 at 03:44:16PM -0700, Subhash Jadavani wrote:
> Looks good, Reviewed-by: Subhash Jadavani <subhashj@codeaurora.org>
I'm getting a bit lost with all the UFS fixes, can you prepared a series
with all the fixups required for 3.18 for me please?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend
2014-10-11 11:06 ` Christoph Hellwig
@ 2014-10-21 14:05 ` Christoph Hellwig
2014-10-21 18:50 ` Subhash Jadavani
0 siblings, 1 reply; 5+ messages in thread
From: Christoph Hellwig @ 2014-10-21 14:05 UTC (permalink / raw)
To: Subhash Jadavani
Cc: 'Dolev Raviv', James.Bottomley, linux-scsi, linux-arm-msm,
santoshsy
On Sat, Oct 11, 2014 at 04:06:29AM -0700, Christoph Hellwig wrote:
> On Sun, Oct 05, 2014 at 03:44:16PM -0700, Subhash Jadavani wrote:
> > Looks good, Reviewed-by: Subhash Jadavani <subhashj@codeaurora.org>
>
> I'm getting a bit lost with all the UFS fixes, can you prepared a series
> with all the fixups required for 3.18 for me please?
Are you going to prepare a set of fixups for 3.18, or should I try to
cram them together? I supect you'd do a much better job than I could.
^ permalink raw reply [flat|nested] 5+ messages in thread
* RE: [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend
2014-10-21 14:05 ` Christoph Hellwig
@ 2014-10-21 18:50 ` Subhash Jadavani
0 siblings, 0 replies; 5+ messages in thread
From: Subhash Jadavani @ 2014-10-21 18:50 UTC (permalink / raw)
To: 'Christoph Hellwig'
Cc: 'Dolev Raviv', James.Bottomley, linux-scsi, linux-arm-msm,
santoshsy
> Are you going to prepare a set of fixups for 3.18, or should I try to cram
them together? I supect you'd do a much better job than I could.
Agreed. There are 3 patches already posted for sparse warning fixes but then
there were 5 new reports of sparse warning. So we (Dolev Raviv and myself)
would try to fix them soon and post all 8 patches as single patch series so
that it would be easy trace. In addition, there will be one more fix for the
issue reported by Akinobu Mita, will include it in the same in patch series.
We should be able to send you these fixes by early next week if not earlier.
-----Original Message-----
From: linux-scsi-owner@vger.kernel.org
[mailto:linux-scsi-owner@vger.kernel.org] On Behalf Of Christoph Hellwig
Sent: Tuesday, October 21, 2014 7:06 AM
To: Subhash Jadavani
Cc: 'Dolev Raviv'; James.Bottomley@HansenPartnership.com;
linux-scsi@vger.kernel.org; linux-arm-msm@vger.kernel.org;
santoshsy@gmail.com
Subject: Re: [PATCH 1/1] ufs: scsi: fix sparse errors in
ufshcd_system_suspend
On Sat, Oct 11, 2014 at 04:06:29AM -0700, Christoph Hellwig wrote:
> On Sun, Oct 05, 2014 at 03:44:16PM -0700, Subhash Jadavani wrote:
> > Looks good, Reviewed-by: Subhash Jadavani <subhashj@codeaurora.org>
>
> I'm getting a bit lost with all the UFS fixes, can you prepared a
> series with all the fixups required for 3.18 for me please?
Are you going to prepare a set of fixups for 3.18, or should I try to cram
them together? I supect you'd do a much better job than I could.
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the
body of a message to majordomo@vger.kernel.org More majordomo info at
http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-10-21 18:50 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-05 14:10 [PATCH 1/1] ufs: scsi: fix sparse errors in ufshcd_system_suspend Dolev Raviv
2014-10-05 22:44 ` Subhash Jadavani
2014-10-11 11:06 ` Christoph Hellwig
2014-10-21 14:05 ` Christoph Hellwig
2014-10-21 18:50 ` Subhash Jadavani
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).