Skip to contentSkip to conversation

drm/lima: fix wait pp reset timeout

PATCH In review Qiang Yu 2 participants 3 messages Jul 19, 2020 – Jul 20, 2020

Subsystems (3)
lore
Share & tools
lore

Qiang Yu

author maintainer
#0 lore raw

PATCH 1/1 drm/lima: fix wait pp reset timeout

PP bcast is marked as doing async reset after job is done. When resume after suspend, each PP is reset individually, so no need to reset in PP bcast resume. But I forgot to clear the PP bcast async reset mark so call into async wait before job run and gets timeout.

Fixes 3446d7e9883d ("drm/lima: add resume/suspend callback for each ip")
---
 drivers/gpu/drm/lima/lima_pp.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/lima/lima_pp.c +2 -0
index 33f01383409c..a5c95bed08c0 100644
@@ -271,6 +271,8 @@ void lima_pp_fini(struct lima_ip *ip)
 
 int lima_pp_bcast_resume(struct lima_ip *ip)
 {
+	/* PP has been reset by individual PP resume */
+	ip->data.async_reset = false;
 	return 0;
 }
 
Signature · 6 lines
2.25.1

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Reviewed-by on v1 1/1
#1 lore raw
Quoted 18 lines · Qiang Yu

PP bcast is marked as doing async reset after job is done. When resume after suspend, each PP is reset individually, so no need to reset in PP bcast resume. But I forgot to clear the PP bcast async reset mark so call into async wait before job run and gets timeout.

Fixes 3446d7e9883d ("drm/lima: add resume/suspend callback for each ip")
---
 drivers/gpu/drm/lima/lima_pp.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/lima/lima_pp.c +0 -0
index 33f01383409c..a5c95bed08c0 100644

drivers/gpu/drm/lima/lima_pp.c void lima_pp_fini(struct lima_ip *ip)

Quoted 9 lines
drivers/gpu/drm/lima/lima_pp.c +2 -1
@@ -271,6 +271,8 @@ void lima_pp_fini(struct lima_ip *ip)
 
 int lima_pp_bcast_resume(struct lima_ip *ip)
 {
+       /* PP has been reset by individual PP resume */
+       ip->data.async_reset = false;
        return 0;
 }
 
--

This fixes the issue reported at
https://gitlab.freedesktop.org/lima/linux/-/issues/34 .
_______________________________________________
dri-devel mailing list [email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

author maintainer Applied
#2 lore raw

Thanks, applied to drm-misc-fixes.

Regards,
Qiang

Quoted 28 lines · Erico Nunes
Quoted 26 lines · Qiang Yu

PP bcast is marked as doing async reset after job is done. When resume after suspend, each PP is reset individually, so no need to reset in PP bcast resume. But I forgot to clear the PP bcast async reset mark so call into async wait before job run and gets timeout.

Fixes 3446d7e9883d ("drm/lima: add resume/suspend callback for each ip")
---
 drivers/gpu/drm/lima/lima_pp.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/lima/lima_pp.c +2 -0
index 33f01383409c..a5c95bed08c0 100644
@@ -271,6 +271,8 @@ void lima_pp_fini(struct lima_ip *ip)
 
 int lima_pp_bcast_resume(struct lima_ip *ip)
 {
+       /* PP has been reset by individual PP resume */
+       ip->data.async_reset = false;
        return 0;
 }
 
Quoted 6 lines
Quoted 1 line

--

This fixes the issue reported at
https://gitlab.freedesktop.org/lima/linux/-/issues/34 .

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