From: Christophe JAILLET Date: Tue, 16 Oct 2018 06:58:25 +0000 (+0200) Subject: drm: rcar-du: Fix the return value in case of error in 'rcar_du_crtc_set_crc_source()' X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=4d486f18d91b1876040bf87e9ad78981a08b15a6;p=openwrt%2Fstaging%2Fblogic.git drm: rcar-du: Fix the return value in case of error in 'rcar_du_crtc_set_crc_source()' We return 0 unconditionally in 'rcar_du_crtc_set_crc_source()'. However, 'ret' is set to some error codes if some function calls fail. Return 'ret' instead to propagate the error code. Fixes: 47a52d024e89 ("media: drm: rcar-du: Add support for CRC computation") Signed-off-by: Christophe JAILLET Reviewed-by: Laurent Pinchart Signed-off-by: Laurent Pinchart --- diff --git a/drivers/gpu/drm/rcar-du/rcar_du_crtc.c b/drivers/gpu/drm/rcar-du/rcar_du_crtc.c index 7406ffd1ab94..d18a342626b5 100644 --- a/drivers/gpu/drm/rcar-du/rcar_du_crtc.c +++ b/drivers/gpu/drm/rcar-du/rcar_du_crtc.c @@ -1002,7 +1002,7 @@ unlock: drm_modeset_drop_locks(&ctx); drm_modeset_acquire_fini(&ctx); - return 0; + return ret; } static const struct drm_crtc_funcs crtc_funcs_gen2 = {