[PATCH 5/9] drm/panel: panel-samsung-s6e63j0x03: Use backlight power constants

Jessica Zhang quic_jesszhan at quicinc.com
Thu Aug 1 22:41:57 UTC 2024



On 7/31/2024 5:17 AM, Thomas Zimmermann wrote:
> 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 <tzimmermann at suse.de>
> Cc: Neil Armstrong <neil.armstrong at linaro.org>
> Cc: Jessica Zhang <quic_jesszhan at quicinc.com>

Reviewed-by: Jessica Zhang <quic_jesszhan at quicinc.com>

> ---
>   drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c b/drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c
> index 46d6f4a87bf7..ed53787d1dea 100644
> --- a/drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c
> +++ b/drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c
> @@ -225,7 +225,7 @@ static int s6e63j0x03_disable(struct drm_panel *panel)
>   	if (ret < 0)
>   		return ret;
>   
> -	ctx->bl_dev->props.power = FB_BLANK_NORMAL;
> +	ctx->bl_dev->props.power = BACKLIGHT_POWER_REDUCED;
>   
>   	ret = mipi_dsi_dcs_enter_sleep_mode(dsi);
>   	if (ret < 0)
> @@ -245,7 +245,7 @@ static int s6e63j0x03_unprepare(struct drm_panel *panel)
>   	if (ret < 0)
>   		return ret;
>   
> -	ctx->bl_dev->props.power = FB_BLANK_POWERDOWN;
> +	ctx->bl_dev->props.power = BACKLIGHT_POWER_OFF;
>   
>   	return 0;
>   }
> @@ -332,7 +332,7 @@ static int s6e63j0x03_prepare(struct drm_panel *panel)
>   	if (ret < 0)
>   		goto err;
>   
> -	ctx->bl_dev->props.power = FB_BLANK_NORMAL;
> +	ctx->bl_dev->props.power = BACKLIGHT_POWER_REDUCED;
>   
>   	return 0;
>   
> @@ -393,7 +393,7 @@ static int s6e63j0x03_enable(struct drm_panel *panel)
>   	if (ret < 0)
>   		return ret;
>   
> -	ctx->bl_dev->props.power = FB_BLANK_UNBLANK;
> +	ctx->bl_dev->props.power = BACKLIGHT_POWER_ON;
>   
>   	return 0;
>   }
> @@ -473,7 +473,7 @@ static int s6e63j0x03_probe(struct mipi_dsi_device *dsi)
>   
>   	ctx->bl_dev->props.max_brightness = MAX_BRIGHTNESS;
>   	ctx->bl_dev->props.brightness = DEFAULT_BRIGHTNESS;
> -	ctx->bl_dev->props.power = FB_BLANK_POWERDOWN;
> +	ctx->bl_dev->props.power = BACKLIGHT_POWER_OFF;
>   
>   	drm_panel_add(&ctx->panel);
>   
> -- 
> 2.45.2
> 


More information about the amd-gfx mailing list