diff mbox series

[08/15] scsi: hisi_sas: Add more prink for runtime suspend/resume

Message ID 1637117108-230103-9-git-send-email-chenxiang66@hisilicon.com (mailing list archive)
State Changes Requested
Headers show
Series Add runtime PM support for libsas | expand

Commit Message

chenxiang Nov. 17, 2021, 2:45 a.m. UTC
From: Xiang Chen <chenxiang66@hisilicon.com>

Add some prink at the beginning and end of suspend/resume.

Signed-off-by: Xiang Chen <chenxiang66@hisilicon.com>
Signed-off-by: John Garry <john.garry@huawei.com>
---
 drivers/scsi/hisi_sas/hisi_sas_v3_hw.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

Comments

John Garry Dec. 13, 2021, 10:34 a.m. UTC | #1
On 17/11/2021 02:45, chenxiang wrote:
> From: Xiang Chen<chenxiang66@hisilicon.com>
> 
> Add some prink at the beginning and end of suspend/resume.
>

Same as subject, it should be /s/prink/logs or prints/. I assume.


> Signed-off-by: Xiang Chen<chenxiang66@hisilicon.com>
> Signed-off-by: John Garry<john.garry@huawei.com>
John Garry Dec. 13, 2021, 10:35 a.m. UTC | #2
On 17/11/2021 02:45, chenxiang wrote:
> Signed-off-by: Xiang Chen<chenxiang66@hisilicon.com>
> Signed-off-by: John Garry<john.garry@huawei.com>

And please change this to Acked-by for my tag

Thanks,
John
chenxiang Dec. 15, 2021, 7:26 a.m. UTC | #3
在 2021/12/13 18:34, John Garry 写道:
> On 17/11/2021 02:45, chenxiang wrote:
>> From: Xiang Chen<chenxiang66@hisilicon.com>
>>
>> Add some prink at the beginning and end of suspend/resume.
>>
>
> Same as subject, it should be /s/prink/logs or prints/. I assume.

ok, i will use logs instead

>
>
>> Signed-off-by: Xiang Chen<chenxiang66@hisilicon.com>
>> Signed-off-by: John Garry<john.garry@huawei.com>
>
>
> .
>
chenxiang Dec. 15, 2021, 7:26 a.m. UTC | #4
在 2021/12/13 18:35, John Garry 写道:
> On 17/11/2021 02:45, chenxiang wrote:
>> Signed-off-by: Xiang Chen<chenxiang66@hisilicon.com>
>> Signed-off-by: John Garry<john.garry@huawei.com>
>
> And please change this to Acked-by for my tag
>

Ok, thanks, i will change it in next version.


> Thanks,
> John
>
> .
>
diff mbox series

Patch

diff --git a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
index 5a83373ac0b1..4e9dfdb69757 100644
--- a/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
+++ b/drivers/scsi/hisi_sas/hisi_sas_v3_hw.c
@@ -4896,6 +4896,8 @@  static int _suspend_v3_hw(struct device *device)
 	if (test_and_set_bit(HISI_SAS_RESETTING_BIT, &hisi_hba->flags))
 		return -1;
 
+	dev_warn(dev, "entering suspend state\n");
+
 	scsi_block_requests(shost);
 	set_bit(HISI_SAS_REJECT_CMD_BIT, &hisi_hba->flags);
 	flush_workqueue(hisi_hba->wq);
@@ -4911,11 +4913,11 @@  static int _suspend_v3_hw(struct device *device)
 
 	hisi_sas_init_mem(hisi_hba);
 
-	dev_warn(dev, "entering suspend state\n");
-
 	hisi_sas_release_tasks(hisi_hba);
 
 	sas_suspend_ha(sha);
+
+	dev_warn(dev, "end of suspending controller\n");
 	return 0;
 }
 
@@ -4953,6 +4955,8 @@  static int _resume_v3_hw(struct device *device)
 	sas_resume_ha_no_sync(sha);
 	clear_bit(HISI_SAS_RESETTING_BIT, &hisi_hba->flags);
 
+	dev_warn(dev, "end of resuming controller\n");
+
 	return 0;
 }