<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<p style="font-family:Arial;font-size:10pt;color:#0000FF;margin:5pt;" align="Left">
[AMD Official Use Only]<br>
</p>
<br>
<div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Series is:</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Reviewed-by: Alex Deucher <alexander.deucher@amd.com><br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Cui, Flora <Flora.Cui@amd.com><br>
<b>Sent:</b> Tuesday, November 23, 2021 9:43 PM<br>
<b>To:</b> Chen, Guchun <Guchun.Chen@amd.com>; amd-gfx@lists.freedesktop.org <amd-gfx@lists.freedesktop.org>; Deucher, Alexander <Alexander.Deucher@amd.com><br>
<b>Cc:</b> Cui, Flora <Flora.Cui@amd.com>; Alex Deucher <aleander.deucher@amd.com><br>
<b>Subject:</b> [PATCH 3/3] drm/amdgpu: check atomic flag to differeniate with legacy path</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">since vkms support atomic KMS interface<br>
<br>
Signed-off-by: Flora Cui <flora.cui@amd.com><br>
Reviewed-by: Guchun Chen <guchun.chen@amd.com><br>
Acked-by: Alex Deucher <aleander.deucher@amd.com><br>
---<br>
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++--<br>
1 file changed, 2 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
index 7d4115d52523..8e9e50aa4a95 100644<br>
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c<br>
@@ -3830,7 +3830,7 @@ void amdgpu_device_fini_hw(struct amdgpu_device *adev)<br>
/* disable all interrupts */<br>
amdgpu_irq_disable_all(adev);<br>
if (adev->mode_info.mode_config_initialized){<br>
- if (!amdgpu_device_has_dc_support(adev))<br>
+ if (!drm_drv_uses_atomic_modeset(adev_to_drm(adev)))<br>
drm_helper_force_disable_all(adev_to_drm(adev));<br>
else<br>
drm_atomic_helper_shutdown(adev_to_drm(adev));<br>
@@ -5124,7 +5124,7 @@ int amdgpu_device_gpu_recover(struct amdgpu_device *adev,<br>
drm_sched_start(&ring->sched, !tmp_adev->asic_reset_res);<br>
}<br>
<br>
- if (!amdgpu_device_has_dc_support(tmp_adev) && !job_signaled) {<br>
+ if (!drm_drv_uses_atomic_modeset(adev_to_drm(tmp_adev)) && !job_signaled) {<br>
drm_helper_resume_force_mode(adev_to_drm(tmp_adev));<br>
}<br>
<br>
-- <br>
2.25.1<br>
<br>
</div>
</span></font></div>
</div>
</body>
</html>