Suspending failed because there's no mode if the CRTC is being disabled. Early-out in this case. This fixes runtime PM for ast.
v2: * add Tested-by/Reviewed-by tags * add Fixes tags and CC (Sam) * improved comment
Signed-off-by: Thomas Zimmermann tzimmermann@suse.de Reported-by: Cary Garrett cogarre@gmail.com Tested-by: Cary Garrett cogarre@gmail.com Fixes: b48e1b6ffd28 ("drm/ast: Add CRTC helpers for atomic modesetting") Cc: Thomas Zimmermann tzimmermann@suse.de Cc: Gerd Hoffmann kraxel@redhat.com Cc: Dave Airlie airlied@redhat.com Cc: Daniel Vetter daniel.vetter@ffwll.ch Cc: Sam Ravnborg sam@ravnborg.org Cc: stable@vger.kernel.org # v5.6+ --- drivers/gpu/drm/ast/ast_mode.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/ast/ast_mode.c b/drivers/gpu/drm/ast/ast_mode.c index 7a9f20a2fd303..0cbbb21edb4e1 100644 --- a/drivers/gpu/drm/ast/ast_mode.c +++ b/drivers/gpu/drm/ast/ast_mode.c @@ -801,6 +801,9 @@ static int ast_crtc_helper_atomic_check(struct drm_crtc *crtc, return -EINVAL; }
+ if (!state->enable) + return 0; /* no mode checks if CRTC is being disabled */ + ast_state = to_ast_crtc_state(state);
format = ast_state->format;
Am 04.05.20 um 14:12 schrieb Thomas Zimmermann:
Suspending failed because there's no mode if the CRTC is being disabled. Early-out in this case. This fixes runtime PM for ast.
v2:
- add Tested-by/Reviewed-by tags
s/Reviewed-by/Reported-by
Will be fixed in v3.
- add Fixes tags and CC (Sam)
- improved comment
Signed-off-by: Thomas Zimmermann tzimmermann@suse.de Reported-by: Cary Garrett cogarre@gmail.com Tested-by: Cary Garrett cogarre@gmail.com Fixes: b48e1b6ffd28 ("drm/ast: Add CRTC helpers for atomic modesetting") Cc: Thomas Zimmermann tzimmermann@suse.de Cc: Gerd Hoffmann kraxel@redhat.com Cc: Dave Airlie airlied@redhat.com Cc: Daniel Vetter daniel.vetter@ffwll.ch Cc: Sam Ravnborg sam@ravnborg.org Cc: stable@vger.kernel.org # v5.6+
drivers/gpu/drm/ast/ast_mode.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/ast/ast_mode.c b/drivers/gpu/drm/ast/ast_mode.c index 7a9f20a2fd303..0cbbb21edb4e1 100644 --- a/drivers/gpu/drm/ast/ast_mode.c +++ b/drivers/gpu/drm/ast/ast_mode.c @@ -801,6 +801,9 @@ static int ast_crtc_helper_atomic_check(struct drm_crtc *crtc, return -EINVAL; }
- if (!state->enable)
return 0; /* no mode checks if CRTC is being disabled */
- ast_state = to_ast_crtc_state(state);
format = ast_state->format;
linux-stable-mirror@lists.linaro.org