Skip to contentSkip to conversation

drm/amd/amdgpu: Remove workaround for suspend/resume in uvd7

PATCH In review Tom St Denis 3 participants 3 messages Oct 24, 2017 1 message not in the archive

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

PATCH 1/1 drm/amd/amdgpu: Remove workaround for suspend/resume in uvd7

The workaround is not required anymor and would result in hangs during suspend/resume cycles if the uvd block were busy.

---
 drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c | 16 +++++-----------
 1 file changed, 5 insertions(+), 11 deletions(-)
drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c +5 -11
index 8dbb409b20be..762ff3901a7a 100644
@@ -592,11 +592,7 @@ static int uvd_v7_0_suspend(void *handle)
 	if (r)
 		return r;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU))
-		r = amdgpu_uvd_suspend(adev);
-
-	return r;
+	return amdgpu_uvd_suspend(adev);
 }
 
 static int uvd_v7_0_resume(void *handle)
@@ -604,12 +600,10 @@ static int uvd_v7_0_resume(void *handle)
 	int r;
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU)) {
-		r = amdgpu_uvd_resume(adev);
-		if (r)
-			return r;
-	}
+	r = amdgpu_uvd_resume(adev);
+	if (r)
+		return r;
+
 	return uvd_v7_0_hw_init(adev);
 }
 
Signature · 6 lines
2.12.0

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Acked-by
#2 lore raw
In reply to a message not in the archive
Quoted 4 lines · Tom St Denis

The workaround is not required anymor and would result in hangs during suspend/resume cycles if the uvd block were busy.

Quoted 28 lines
---
  drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c | 16 +++++-----------
  1 file changed, 5 insertions(+), 11 deletions(-)
drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c +1 -8
index 8dbb409b20be..762ff3901a7a 100644
@@ -592,11 +592,7 @@ static int uvd_v7_0_suspend(void *handle)
  	if (r)
  		return r;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU))
-		r = amdgpu_uvd_suspend(adev);
-
-	return r;
+	return amdgpu_uvd_suspend(adev);
  }
 
  static int uvd_v7_0_resume(void *handle)
@@ -604,12 +600,10 @@ static int uvd_v7_0_resume(void *handle)
  	int r;
  	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU)) {
-		r = amdgpu_uvd_resume(adev);

drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c static int uvd_v7_0_resume(void *handle) · line 609

Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c +4 -3
-		if (r)
-			return r;
-	}
+	r = amdgpu_uvd_resume(adev);
+	if (r)
+		return r;
+
  	return uvd_v7_0_hw_init(adev);
  }
 

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

Acked-by Alex Deucher
#3 lore raw
In reply to a message not in the archive
Quoted 9 lines

-----Original Message-----
From: amd-gfx [mailto:[email protected]] On Behalf Of Tom St Denis
Sent: Tuesday, October 24, 2017 12:08 PM
To: [email protected]
Cc: StDenis, Tom
Subject: [PATCH] drm/amd/amdgpu: Remove workaround for suspend/resume in uvd7

Quoted 4 lines

The workaround is not required anymor and would result in hangs during suspend/resume cycles if the uvd block were busy.

Quoted 42 lines
---
 drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c | 16 +++++-----------
 1 file changed, 5 insertions(+), 11 deletions(-)
drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c +5 -12
index 8dbb409b20be..762ff3901a7a 100644
@@ -592,11 +592,7 @@ static int uvd_v7_0_suspend(void *handle)
 	if (r)
 		return r;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU))
-		r = amdgpu_uvd_suspend(adev);
-
-	return r;
+	return amdgpu_uvd_suspend(adev);
 }
 
 static int uvd_v7_0_resume(void *handle)
@@ -604,12 +600,10 @@ static int uvd_v7_0_resume(void *handle)
 	int r;
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
-	/* Skip this for APU for now */
-	if (!(adev->flags & AMD_IS_APU)) {
-		r = amdgpu_uvd_resume(adev);
-		if (r)
-			return r;
-	}
+	r = amdgpu_uvd_resume(adev);
+	if (r)
+		return r;
+
 	return uvd_v7_0_hw_init(adev);
 }
 
--

2.12.0

Quoted 4 lines

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

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