Skip to contentSkip to conversation

drm/amd/pm: print errorno if get ecc info failed

PATCH In review Stanley.Yang 2 participants 4 messages Dec 6, 2021 – Dec 7, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amd/pm: print errorno if get ecc info failed

---
 drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c +1 -1
index 6e781cee8bb6..e0a8224e466f 100644
@@ -1815,7 +1815,7 @@ static ssize_t aldebaran_get_ecc_info(struct smu_context *smu,
 			       smu_table->ecc_table,
 			       false);
 	if (ret) {
-		dev_info(smu->adev->dev, "Failed to export SMU ecc table!\n");
+		dev_info(smu->adev->dev, "Failed to export SMU ecc table! ret %d.\n", ret);
 		return ret;
 	}
 
Signature · 1 line
2.17.1
#1 lore raw

[AMD Official Use Only]

Hi Stanley,

There is already error prompts in the smu_cmn_send_smc_msg_with_param() used by the API mentioned below. Can that cover your use case?

BR
Evan

Quoted 34 lines

-----Original Message-----
From: Stanley.Yang <[email protected]>
Sent: Sunday, December 5, 2021 6:02 PM
To: [email protected]; Zhang, Hawking <[email protected]>; Clements, John <[email protected]>; Zhou1, Tao <[email protected]>; Li, Candice <[email protected]>; Chai, Thomas <[email protected]>; Quan, Evan <[email protected]>
Cc: Yang, Stanley <[email protected]>
Subject: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed

---
 drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c +1 -1
index 6e781cee8bb6..e0a8224e466f 100644
@@ -1815,7 +1815,7 @@ static ssize_t aldebaran_get_ecc_info(struct
 smu_context *smu,
 			       smu_table->ecc_table,
 			       false);
 	if (ret) {
-		dev_info(smu->adev->dev, "Failed to export SMU ecc
 table!\n");
+		dev_info(smu->adev->dev, "Failed to export SMU ecc table!
 ret %d.\n", ret);
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c +0 -1
 		return ret;
 	}
 
--

2.17.1

#2 lore raw

Hi Evan,

The error prompts in function smu_cmn_send_smc_msg_with_param do not cover all failed cases since it only prints reg stat SMU_RESP_NONE, SMU_RESP_BUSY_OTHER or response -EREMOTEIO. I think it is better update reg error stat judgment conditions to print more error msg.

Regards,
Stanley
发件人: Quan, Evan <[email protected]>
日期: 星期一, 2021年12月6日 上午9:43
收件人: Yang, Stanley <[email protected]>, [email protected] <[email protected]>, Zhang, Hawking <[email protected]>, Clements, John <[email protected]>, Zhou1, Tao <[email protected]>, Li, Candice <[email protected]>, Chai, Thomas <[email protected]> 抄送: Yang, Stanley <[email protected]>
主题: RE: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed
[AMD Official Use Only]

Hi Stanley,

There is already error prompts in the smu_cmn_send_smc_msg_with_param() used by the API mentioned below. Can that cover your use case?

BR
Evan

Quoted 34 lines

-----Original Message-----
From: Stanley.Yang <[email protected]>
Sent: Sunday, December 5, 2021 6:02 PM
To: [email protected]; Zhang, Hawking <[email protected]>; Clements, John <[email protected]>; Zhou1, Tao <[email protected]>; Li, Candice <[email protected]>; Chai, Thomas <[email protected]>; Quan, Evan <[email protected]>
Cc: Yang, Stanley <[email protected]>
Subject: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed

---
 drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c +1 -1
index 6e781cee8bb6..e0a8224e466f 100644
@@ -1815,7 +1815,7 @@ static ssize_t aldebaran_get_ecc_info(struct
 smu_context *smu,
                              smu_table->ecc_table,
                              false);
       if (ret) {
-             dev_info(smu->adev->dev, "Failed to export SMU ecc
 table!\n");
+             dev_info(smu->adev->dev, "Failed to export SMU ecc table!
 ret %d.\n", ret);
               return ret;
       }

--
2.17.1

Reviewed-by
#3 lore raw

[AMD Official Use Only]

OK. If that can help the debugging for RAS development, I’m fine with it.

BR
Evan
From: Yang, Stanley <[email protected]>
Sent: Monday, December 6, 2021 8:37 PM
To: Quan, Evan <[email protected]>; [email protected]; Zhang, Hawking <[email protected]>; Clements, John <[email protected]>; Zhou1, Tao <[email protected]>; Li, Candice <[email protected]>; Chai, Thomas <[email protected]>
Subject: 答复: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed

Hi Evan,

The error prompts in function smu_cmn_send_smc_msg_with_param do not cover all failed cases since it only prints reg stat SMU_RESP_NONE, SMU_RESP_BUSY_OTHER or response -EREMOTEIO. I think it is better update reg error stat judgment conditions to print more error msg.

Regards,
Stanley
发件人: Quan, Evan <[email protected]<mailto:[email protected]>>
日期: 星期一, 2021年12月6日 上午9:43
收件人: Yang, Stanley <[email protected]<mailto:[email protected]>>, [email protected]<mailto:[email protected]> <[email protected]<mailto:[email protected]>>, Zhang, Hawking <[email protected]<mailto:[email protected]>>, Clements, John <[email protected]<mailto:[email protected]>>, Zhou1, Tao <[email protected]<mailto:[email protected]>>, Li, Candice <[email protected]<mailto:[email protected]>>, Chai, Thomas <[email protected]<mailto:[email protected]>> 抄送: Yang, Stanley <[email protected]<mailto:[email protected]>>
主题: RE: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed
[AMD Official Use Only]

Hi Stanley,

There is already error prompts in the smu_cmn_send_smc_msg_with_param() used by the API mentioned below. Can that cover your use case?

BR
Evan

Quoted 34 lines

-----Original Message-----
From: Stanley.Yang <[email protected]<mailto:[email protected]>>
Sent: Sunday, December 5, 2021 6:02 PM
To: [email protected]<mailto:[email protected]>; Zhang, Hawking <[email protected]<mailto:[email protected]>>; Clements, John <[email protected]<mailto:[email protected]>>; Zhou1, Tao <[email protected]<mailto:[email protected]>>; Li, Candice <[email protected]<mailto:[email protected]>>; Chai, Thomas <[email protected]<mailto:[email protected]>>; Quan, Evan <[email protected]<mailto:[email protected]>>
Cc: Yang, Stanley <[email protected]<mailto:[email protected]>>
Subject: [PATCH Review 1/1] drm/amd/pm: print errorno if get ecc info failed

---
 drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/swsmu/smu13/aldebaran_ppt.c +1 -1
index 6e781cee8bb6..e0a8224e466f 100644
@@ -1815,7 +1815,7 @@ static ssize_t aldebaran_get_ecc_info(struct
 smu_context *smu,
                              smu_table->ecc_table,
                              false);
       if (ret) {
-             dev_info(smu->adev->dev, "Failed to export SMU ecc
 table!\n");
+             dev_info(smu->adev->dev, "Failed to export SMU ecc table!
 ret %d.\n", ret);
               return ret;
       }

--
2.17.1