Skip to content

Commit 7f75eb2

Browse files
author
Thomas Zimmermann
committed
drm/panel: panel-samsung-s6e3ha2: Use backlight power constants
Replace FB_BLANK_ constants with their counterparts from the backlight subsystem. The values are identical, so there's no change in functionality or semantics. Signed-off-by: Thomas Zimmermann <[email protected]> Cc: Neil Armstrong <[email protected]> Cc: Jessica Zhang <[email protected]> Reviewed-by: Jessica Zhang <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 21d6376 commit 7f75eb2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

drivers/gpu/drm/panel/panel-samsung-s6e3ha2.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ static int s6e3ha2_set_brightness(struct backlight_device *bl_dev)
458458
return -EINVAL;
459459
}
460460

461-
if (bl_dev->props.power > FB_BLANK_NORMAL)
461+
if (bl_dev->props.power > BACKLIGHT_POWER_REDUCED)
462462
return -EPERM;
463463

464464
s6e3ha2_call_write_func(ret, s6e3ha2_test_key_on_f0(ctx));
@@ -508,7 +508,7 @@ static int s6e3ha2_disable(struct drm_panel *panel)
508508
s6e3ha2_call_write_func(ret, mipi_dsi_dcs_set_display_off(dsi));
509509

510510
msleep(40);
511-
ctx->bl_dev->props.power = FB_BLANK_NORMAL;
511+
ctx->bl_dev->props.power = BACKLIGHT_POWER_REDUCED;
512512

513513
return 0;
514514
}
@@ -554,7 +554,7 @@ static int s6e3ha2_prepare(struct drm_panel *panel)
554554
if (ret < 0)
555555
goto err;
556556

557-
ctx->bl_dev->props.power = FB_BLANK_NORMAL;
557+
ctx->bl_dev->props.power = BACKLIGHT_POWER_REDUCED;
558558

559559
return 0;
560560

@@ -601,7 +601,7 @@ static int s6e3ha2_enable(struct drm_panel *panel)
601601
s6e3ha2_call_write_func(ret, s6e3ha2_test_key_off_f0(ctx));
602602

603603
s6e3ha2_call_write_func(ret, mipi_dsi_dcs_set_display_on(dsi));
604-
ctx->bl_dev->props.power = FB_BLANK_UNBLANK;
604+
ctx->bl_dev->props.power = BACKLIGHT_POWER_ON;
605605

606606
return 0;
607607
}
@@ -729,7 +729,7 @@ static int s6e3ha2_probe(struct mipi_dsi_device *dsi)
729729

730730
ctx->bl_dev->props.max_brightness = S6E3HA2_MAX_BRIGHTNESS;
731731
ctx->bl_dev->props.brightness = S6E3HA2_DEFAULT_BRIGHTNESS;
732-
ctx->bl_dev->props.power = FB_BLANK_POWERDOWN;
732+
ctx->bl_dev->props.power = BACKLIGHT_POWER_OFF;
733733

734734
drm_panel_init(&ctx->panel, dev, &s6e3ha2_drm_funcs,
735735
DRM_MODE_CONNECTOR_DSI);

0 commit comments

Comments
 (0)