Skip to contentSkip to conversation

drm/amdgpu/sriov: Disable pm for multiple vf sriov

PATCH In review Emily Deng 3 participants 6 messages Jun 2, 2020 – Jun 11, 2020

Subsystems (2)
lore
Share & tools
lore

Emily Deng

author
#0 lore raw

PATCH 1/1 drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +3 -1
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 	struct smu_context *smu = &adev->smu;
 
-	if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+	if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+		smu->pm_enabled = false;
 		return 0;
+	}
 
 	ret = smu_start_smc_engine(smu);
 	if (ret) {
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
#1 lore raw

[AMD Official Use Only - Internal Distribution Only]

Quoted 30 lines

-----Original Message-----
From: Emily Deng <[email protected]>
Sent: Tuesday, June 2, 2020 8:40 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-

1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +3 -2
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)
 struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 struct smu_context *smu = &adev->smu;
 
-if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+smu->pm_enabled = false;
 return 0;
+}
 
 ret = smu_start_smc_engine(smu);
 if (ret) {
--
Quoted 1 line

2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#2 lore raw

[AMD Official Use Only - Internal Distribution Only]

Hi Monk,
Could you help to review this patch for multiple vf?

Best wishes
Emily Deng

Quoted 36 lines

-----Original Message-----
From: Deng, Emily <[email protected]>
Sent: Wednesday, June 10, 2020 7:01 PM
To: Deng, Emily <[email protected]>; [email protected]
Cc: Min, Frank <[email protected]>
Subject: RE: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

[AMD Official Use Only - Internal Distribution Only]

Quoted 27 lines

-----Original Message-----
From: Emily Deng <[email protected]>
Sent: Tuesday, June 2, 2020 8:40 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-

1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +0 -0
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)  struct

amdgpu_device *adev = (struct amdgpu_device *)handle; struct smu_context *smu = &adev->smu;

drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +2 -1
-if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+smu->pm_enabled = false;

return 0;
+}

Quoted 5 lines
Quoted 4 lines

ret = smu_start_smc_engine(smu);
if (ret) {
--
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#3 lore raw
In reply to Emily Deng

_____________________________________
Monk Liu|GPU Virtualization Team |AMD

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Emily Deng
Sent: Tuesday, June 2, 2020 8:40 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +3 -1
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 	struct smu_context *smu = &adev->smu;
 
-	if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+	if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+		smu->pm_enabled = false;
 		return 0;
+	}
 
 	ret = smu_start_smc_engine(smu);
 	if (ret) {
Signature · 10 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=02%7C01%7Cmonk.liu%40amd.com%7C2641ef6641d145a005c708d806f1e44d%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637266983285813096&amp;sdata=sTB0tRfcRP3bqm9L5qNDTVsbdJxZcfHxPs9WuH1tf1M%3D&amp;reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
#4 lore raw
In reply to Emily Deng

[AMD Official Use Only - Internal Distribution Only]

Can this be moved to smu_early_init()? Or just do not adding the SMU ip for multiple vf sriov?

Evan
-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Emily Deng
Sent: Tuesday, June 2, 2020 8:40 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +3 -1
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)
 struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 struct smu_context *smu = &adev->smu;
 
-if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+smu->pm_enabled = false;
 return 0;
+}
 
 ret = smu_start_smc_engine(smu);
 if (ret) {

--
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=02%7C01%7Cevan.quan%40amd.com%7C1f8e52701d674ecc4ebf08d806f1e44d%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637266983322685089&amp;sdata=RZ1PZlfRuO5b2jjHVwFcPqCDOZOZ2zRMgxZfjbAeYN0%3D&amp;reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#5 lore raw

[AMD Official Use Only - Internal Distribution Only]

Hi Evan,
The multiple vf detect is amdgpu_device_ip_init.

Best wishes
Emily Deng

Quoted 46 lines

-----Original Message-----
From: Quan, Evan <[email protected]>
Sent: Thursday, June 11, 2020 12:41 PM
To: Deng, Emily <[email protected]>; [email protected]
Cc: Deng, Emily <[email protected]>
Subject: RE: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

[AMD Official Use Only - Internal Distribution Only]

Can this be moved to smu_early_init()? Or just do not adding the SMU ip for multiple vf sriov?

Evan
-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Emily Deng
Sent: Tuesday, June 2, 2020 8:40 PM
To: [email protected]
Cc: Deng, Emily <[email protected]>
Subject: [PATCH] drm/amdgpu/sriov: Disable pm for multiple vf sriov

---
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 4 +++-

1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +0 -0
index 5294aa7..8ed6c90 100644
@@ -1311,8 +1311,10 @@ static int smu_hw_init(void *handle)  struct

amdgpu_device *adev = (struct amdgpu_device *)handle; struct smu_context *smu = &adev->smu;

drivers/gpu/drm/amd/powerplay/amdgpu_smu.c +2 -1
-if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev))
+if (amdgpu_sriov_vf(adev) && !amdgpu_sriov_is_pp_one_vf(adev)) {
+smu->pm_enabled = false;

return 0;
+}

ret = smu_start_smc_engine(smu);
if (ret) {
--
2.7.4

Quoted 9 lines

_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.fre
edesktop.org%2Fmailman%2Flistinfo%2Famd- gfx&amp;data=02%7C01%7Cevan.quan%40amd.com%7C1f8e52701d674ecc4eb f08d806f1e44d%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C63726 6983322685089&amp;sdata=RZ1PZlfRuO5b2jjHVwFcPqCDOZOZ2zRMgxZfjbAeY N0%3D&amp;reserved=0

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx