mbox series

[0/9] drm: Use backlight power constants

Message ID 20240731122311.1143153-1-tzimmermann@suse.de (mailing list archive)
Headers show
Series drm: Use backlight power constants | expand

Message

Thomas Zimmermann July 31, 2024, 12:17 p.m. UTC
Commit a1cacb8a8e70 ("backlight: Add BACKLIGHT_POWER_ constants for
power states") introduced dedicated constants for backlight power states.
Convert DRM drivers to the new constants.

Some of the DRM panel drivers use BACKLIGHT_POWER_REDUCED, which is
deprecated. The drivers should later be converted to BACKLIGHT_POWER_ON
and BACKLIGHT_POWER_OFF.

The new constants replace the fbdev constants. This is part of a larger
effort to make kernel subsystems more independent from fbdev code and
headers.

Thomas Zimmermann (9):
  drm/amdgpu: Use backlight power constants
  drm/i915: Use backlight power constants
  drm/panel: panel-novatak-nt35510: Use backlight power constants
  drm/panel: panel-orisetech-otm8009a: Use backlight power constants
  drm/panel: panel-samsung-s6e63j0x03: Use backlight power constants
  drm/panel: panel-samsung-s6e3ha2: Use backlight power constants
  drm/panel: panel-sony-acx565akm: Use backlight power constants
  drm/radeon: Use backlight power constants
  drm/tilcdc: Use backlight power constants

 drivers/gpu/drm/amd/amdgpu/atombios_encoders.c   |  2 +-
 drivers/gpu/drm/i915/display/intel_backlight.c   | 12 ++++++------
 drivers/gpu/drm/panel/panel-novatek-nt35510.c    |  2 +-
 drivers/gpu/drm/panel/panel-orisetech-otm8009a.c |  4 ++--
 drivers/gpu/drm/panel/panel-samsung-s6e3ha2.c    | 10 +++++-----
 drivers/gpu/drm/panel/panel-samsung-s6e63j0x03.c | 10 +++++-----
 drivers/gpu/drm/panel/panel-sony-acx565akm.c     |  2 +-
 drivers/gpu/drm/radeon/atombios_encoders.c       |  2 +-
 drivers/gpu/drm/radeon/radeon_legacy_encoders.c  |  2 +-
 drivers/gpu/drm/tilcdc/tilcdc_panel.c            |  2 +-
 10 files changed, 24 insertions(+), 24 deletions(-)

Comments

Jyri Sarha Aug. 2, 2024, 7 a.m. UTC | #1
July 31, 2024 at 3:17 PM, "Thomas Zimmermann" <tzimmermann@suse.de mailto:tzimmermann@suse.de?to=%22Thomas%20Zimmermann%22%20%3Ctzimmermann%40suse.de%3E > 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@suse.de>
> Cc: Jyri Sarha <jyri.sarha@iki.fi>
> Cc: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
> ---

Acked-by: Jyri Sarha <jyri.sarha@iki.fi>

Thank,
Jyri

> drivers/gpu/drm/tilcdc/tilcdc_panel.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_panel.c b/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> index 68093d6b6b16..5f2d1b6f9ee9 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_panel.c
> @@ -49,7 +49,7 @@ static void panel_encoder_dpms(struct drm_encoder *encoder, int mode)
> 
>  if (backlight) {
>  backlight->props.power = mode == DRM_MODE_DPMS_ON ?
> - FB_BLANK_UNBLANK : FB_BLANK_POWERDOWN;
> + BACKLIGHT_POWER_ON : BACKLIGHT_POWER_OFF;
>  backlight_update_status(backlight);
>  }
> 
> -- 
> 2.45.2
>