summaryrefslogtreecommitdiff
path: root/drivers/video
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2024-09-06 10:52:28 +0300
committerLee Jones <lee@kernel.org>2024-09-30 18:49:42 +0300
commita42a215d4d4d5ab32af4dee860e964764ed89f65 (patch)
tree65c7128eb9b6e9601476408cf726729717e97016 /drivers/video
parent7c323fb26465ed294cd34bff77a68a40499148a7 (diff)
downloadlinux-a42a215d4d4d5ab32af4dee860e964764ed89f65.tar.xz
backlight: ltv350qv: Use lcd power constants
Replace FB_BLANK_ constants with their counterparts from the lcd subsystem. The values are identical, so there's no change in functionality. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org> Link: https://lore.kernel.org/r/20240906075439.98476-15-tzimmermann@suse.de Signed-off-by: Lee Jones <lee@kernel.org>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/backlight/ltv350qv.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/video/backlight/ltv350qv.c b/drivers/video/backlight/ltv350qv.c
index cdc4c087f230..c919b0fe4cd9 100644
--- a/drivers/video/backlight/ltv350qv.c
+++ b/drivers/video/backlight/ltv350qv.c
@@ -6,7 +6,6 @@
*/
#include <linux/delay.h>
#include <linux/err.h>
-#include <linux/fb.h>
#include <linux/init.h>
#include <linux/lcd.h>
#include <linux/module.h>
@@ -15,7 +14,7 @@
#include "ltv350qv.h"
-#define POWER_IS_ON(pwr) ((pwr) <= FB_BLANK_NORMAL)
+#define POWER_IS_ON(pwr) ((pwr) <= LCD_POWER_REDUCED)
struct ltv350qv {
struct spi_device *spi;
@@ -233,7 +232,7 @@ static int ltv350qv_probe(struct spi_device *spi)
return -ENOMEM;
lcd->spi = spi;
- lcd->power = FB_BLANK_POWERDOWN;
+ lcd->power = LCD_POWER_OFF;
lcd->buffer = devm_kzalloc(&spi->dev, 8, GFP_KERNEL);
if (!lcd->buffer)
return -ENOMEM;
@@ -245,7 +244,7 @@ static int ltv350qv_probe(struct spi_device *spi)
lcd->ld = ld;
- ret = ltv350qv_power(lcd, FB_BLANK_UNBLANK);
+ ret = ltv350qv_power(lcd, LCD_POWER_ON);
if (ret)
return ret;
@@ -258,7 +257,7 @@ static void ltv350qv_remove(struct spi_device *spi)
{
struct ltv350qv *lcd = spi_get_drvdata(spi);
- ltv350qv_power(lcd, FB_BLANK_POWERDOWN);
+ ltv350qv_power(lcd, LCD_POWER_OFF);
}
#ifdef CONFIG_PM_SLEEP
@@ -266,14 +265,14 @@ static int ltv350qv_suspend(struct device *dev)
{
struct ltv350qv *lcd = dev_get_drvdata(dev);
- return ltv350qv_power(lcd, FB_BLANK_POWERDOWN);
+ return ltv350qv_power(lcd, LCD_POWER_OFF);
}
static int ltv350qv_resume(struct device *dev)
{
struct ltv350qv *lcd = dev_get_drvdata(dev);
- return ltv350qv_power(lcd, FB_BLANK_UNBLANK);
+ return ltv350qv_power(lcd, LCD_POWER_ON);
}
#endif
@@ -284,7 +283,7 @@ static void ltv350qv_shutdown(struct spi_device *spi)
{
struct ltv350qv *lcd = spi_get_drvdata(spi);
- ltv350qv_power(lcd, FB_BLANK_POWERDOWN);
+ ltv350qv_power(lcd, LCD_POWER_OFF);
}
static struct spi_driver ltv350qv_driver = {