Skip to contentSkip to conversation

drm/amdgpu: report DC not supported if virtual display is enabled (v2)

PATCH In review Alex Deucher 4 participants 4 messages Aug 25, 2020 – Aug 26, 2020

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

PATCH 1/1 drm/amdgpu: report DC not supported if virtual display is enabled (v2)

virtual display is non-atomic so report false to avoid checking atomic state and other atomic things at runtime.

v2: squash into the sr-iov check

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -1
index 5a948edcc93c..8f37f9f99105 100644
@@ -2861,7 +2861,7 @@ bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type)
  */
 bool amdgpu_device_has_dc_support(struct amdgpu_device *adev)
 {
-	if (amdgpu_sriov_vf(adev))
+	if (amdgpu_sriov_vf(adev) || adev->enable_virtual_display)
 		return false;
 
 	return amdgpu_device_asic_has_dc_support(adev->asic_type);
Signature · 6 lines
2.25.4

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

[AMD Public Use]

Regards,
Guchun

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, August 25, 2020 10:18 PM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>
Subject: [PATCH] drm/amdgpu: report DC not supported if virtual display is enabled (v2)

virtual display is non-atomic so report false to avoid checking atomic state and other atomic things at runtime.

v2: squash into the sr-iov check

---
 drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -2
index 5a948edcc93c..8f37f9f99105 100644
@@ -2861,7 +2861,7 @@ bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type)
  */
 bool amdgpu_device_has_dc_support(struct amdgpu_device *adev)  {
-	if (amdgpu_sriov_vf(adev))
+	if (amdgpu_sriov_vf(adev) || adev->enable_virtual_display)
 		return false;
 
 	return amdgpu_device_asic_has_dc_support(adev->asic_type);
--

2.25.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%7Cguchun.chen%40amd.com%7C5dd32cf703464c63e3ba08d84901b99a%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637339619046540701&amp;sdata=vnfKXyNtJVE10V6qFwzHQQ7rmVAV9Le6g31nkmaPnLA%3D&amp;reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

#2 lore raw
In reply to Alex Deucher
Quoted 1 line · Alex Deucher

virtual display is non-atomic so report false to avoid checking

With below nitpick fixed, Acked-by: Nirmoy Das <[email protected]>

virtual --> Virtual

Nirmoy

Quoted 14 lines

atomic state and other atomic things at runtime.

v2: squash into the sr-iov check

---
  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0 -0
index 5a948edcc93c..8f37f9f99105 100644

drivers/gpu/drm/amd/amdgpu/amdgpu_device.c bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type) · line 2867

Quoted 8 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -1
@@ -2861,7 +2861,7 @@ bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type)
   */
  bool amdgpu_device_has_dc_support(struct amdgpu_device *adev)
  {
-	if (amdgpu_sriov_vf(adev))
+	if (amdgpu_sriov_vf(adev) || adev->enable_virtual_display)
  		return false;
 
  	return amdgpu_device_asic_has_dc_support(adev->asic_type);

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

#3 lore raw
Quoted 5 lines · Nirmoy
Quoted 1 line · Alex Deucher

virtual display is non-atomic so report false to avoid checking

With below nitpick fixed, Acked-by: Nirmoy Das <[email protected]>

Another nitpick: "below" is not an adjective. It's a preposition or in this case as an adverb:

"With the nitpick below fixed,"...

Regards,
Luben

Quoted 28 lines

virtual --> Virtual

Nirmoy

Quoted 21 lines

atomic state and other atomic things at runtime.

v2: squash into the sr-iov check

---
  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +1 -1
index 5a948edcc93c..8f37f9f99105 100644
@@ -2861,7 +2861,7 @@ bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type)
   */
  bool amdgpu_device_has_dc_support(struct amdgpu_device *adev)
  {
-	if (amdgpu_sriov_vf(adev))
+	if (amdgpu_sriov_vf(adev) || adev->enable_virtual_display)
  		return false;
 
Quoted 6 lines

drivers/gpu/drm/amd/amdgpu/amdgpu_device.c bool amdgpu_device_asic_has_dc_support(enum amd_asic_type asic_type) · line 2867

Quoted 1 line
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +0 -0
  	return amdgpu_device_asic_has_dc_support(adev->asic_type);

_______________________________________________
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%7Cluben.tuikov%40amd.com%7Ca80cd8a3f9b34b19d07708d849036b25%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637339626337747219&amp;sdata=6xwRnYCESQNachEMmT2jpVjKTsDg4RkwQKpMsOTsSkA%3D&amp;reserved=0

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