aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomi Valkeinen <[email protected]>2020-12-15 12:46:44 +0200
committerTomi Valkeinen <[email protected]>2020-12-15 16:17:31 +0200
commitd646d1bdb606d9ffc873e5e0a38c86599bdff8e1 (patch)
tree24bdaa37a08cbd9145bd5ae60695511b8302f582
parent4029b16b13b68358f563d1a43097ba4c8b30ff83 (diff)
drm/panel: panel-dsi-cm: remove extra 'if'
We have a useless 'if' in the dsicm_bl_update_status(), a left over from the conversion to DRM model. Drop the if. Signed-off-by: Tomi Valkeinen <[email protected]> Reviewed-by: Sam Ravnborg <[email protected]> Reviewed-by: Laurent Pinchart <[email protected]> Reviewed-by: Sebastian Reichel <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
-rw-r--r--drivers/gpu/drm/panel/panel-dsi-cm.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/gpu/drm/panel/panel-dsi-cm.c b/drivers/gpu/drm/panel/panel-dsi-cm.c
index 067745fb682f..f5240fd82459 100644
--- a/drivers/gpu/drm/panel/panel-dsi-cm.c
+++ b/drivers/gpu/drm/panel/panel-dsi-cm.c
@@ -202,11 +202,9 @@ static int dsicm_bl_update_status(struct backlight_device *dev)
mutex_lock(&ddata->lock);
- if (ddata->enabled) {
- if (!r)
- r = dsicm_dcs_write_1(
- ddata, MIPI_DCS_SET_DISPLAY_BRIGHTNESS, level);
- }
+ if (ddata->enabled)
+ r = dsicm_dcs_write_1(ddata, MIPI_DCS_SET_DISPLAY_BRIGHTNESS,
+ level);
mutex_unlock(&ddata->lock);