Skip to content

Commit

Permalink
drm/exynos: drm_connector: Fix error check condition
Browse files Browse the repository at this point in the history
drm_add_edid_modes() returns 0 upon failure to find any modes.
Hence check for 0 and not less than 0.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
  • Loading branch information
Sachin Kamat authored and Inki Dae committed Apr 16, 2013
1 parent d8e9ca4 commit 81ed703
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/exynos/exynos_drm_connector.c
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ static int exynos_drm_connector_get_modes(struct drm_connector *connector)
}

count = drm_add_edid_modes(connector, edid);
if (count < 0) {
if (!count) {
DRM_ERROR("Add edid modes failed %d\n", count);
goto out;
}
Expand Down

0 comments on commit 81ed703

Please sign in to comment.