drm/ast: Zero is missing in detect function
authorAinux.Wang <ainux.wang@gmail.com>
Fri, 16 Jul 2021 01:56:15 +0000 (09:56 +0800)
committerThomas Zimmermann <tzimmermann@suse.de>
Tue, 20 Jul 2021 09:19:57 +0000 (11:19 +0200)
The function ast_get_modes() will also return 0, when it try to get the
edid, but it also do not get the edid.

Signed-off-by: Ainux.Wang <ainux.wang@gmail.com>
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20210716015615.9150-1-ainux.wang@gmail.com
drivers/gpu/drm/ast/ast_mode.c

index f5d58c3..f32da62 100644 (file)
@@ -1298,7 +1298,7 @@ static enum drm_connector_status ast_connector_detect(struct drm_connector
        int r;
 
        r = ast_get_modes(connector);
-       if (r < 0)
+       if (r <= 0)
                return connector_status_disconnected;
 
        return connector_status_connected;