drm/exynos: Fix error value in exynos_drm_crtc_get_by_type()
authorMarek Szyprowski <m.szyprowski@samsung.com>
Tue, 12 Dec 2017 12:01:15 +0000 (13:01 +0100)
committerInki Dae <inki.dae@samsung.com>
Thu, 24 May 2018 07:47:39 +0000 (16:47 +0900)
EPERM is not the correct error value when the driver is not able to get
its resources. Change it to ENODEV.

Reported-by: Russell King - ARM Linux <linux@armlinux.org.uk>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
drivers/gpu/drm/exynos/exynos_drm_crtc.c

index dc01342e759a0f4e1a5f7ea32d7ace8609386243..eea90251808fa2e58398fdcb1cac01d160307320 100644 (file)
@@ -228,7 +228,7 @@ struct exynos_drm_crtc *exynos_drm_crtc_get_by_type(struct drm_device *drm_dev,
                if (to_exynos_crtc(crtc)->type == out_type)
                        return to_exynos_crtc(crtc);
 
-       return ERR_PTR(-EPERM);
+       return ERR_PTR(-ENODEV);
 }
 
 int exynos_drm_set_possible_crtcs(struct drm_encoder *encoder,