[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230612141352.29939-7-tzimmermann@suse.de>
Date: Mon, 12 Jun 2023 16:07:44 +0200
From: Thomas Zimmermann <tzimmermann@...e.de>
To: daniel@...ll.ch, javierm@...hat.com, sam@...nborg.org,
deller@....de, geert+renesas@...der.be, lee@...nel.org,
daniel.thompson@...aro.org, jingoohan1@...il.com,
dan.carpenter@...aro.org, michael.j.ruhl@...el.com
Cc: linux-fbdev@...r.kernel.org, dri-devel@...ts.freedesktop.org,
linux-sh@...r.kernel.org, linux-omap@...r.kernel.org,
linux-staging@...ts.linux.dev, linux-kernel@...r.kernel.org,
Thomas Zimmermann <tzimmermann@...e.de>,
Yoshinori Sato <ysato@...rs.sourceforge.jp>,
Rich Felker <dalias@...c.org>,
John Paul Adrian Glaubitz <glaubitz@...sik.fu-berlin.de>
Subject: [PATCH v2 06/38] backlight/lv5207lp: Rename struct lv5207lp_platform_data.fbdev to 'dev'
Rename struct lv5207lp_platform_data.fbdev to 'dev', as it stores a
pointer to the Linux platform device; not the fbdev device. Makes
the code easier to understand.
Signed-off-by: Thomas Zimmermann <tzimmermann@...e.de>
Cc: Yoshinori Sato <ysato@...rs.sourceforge.jp>
Cc: Rich Felker <dalias@...c.org>
Cc: John Paul Adrian Glaubitz <glaubitz@...sik.fu-berlin.de>
Cc: Lee Jones <lee@...nel.org>
Cc: Daniel Thompson <daniel.thompson@...aro.org>
Cc: Jingoo Han <jingoohan1@...il.com>
Cc: linux-sh@...r.kernel.org
Reviewed-by: Javier Martinez Canillas <javierm@...hat.com>
---
arch/sh/boards/mach-kfr2r09/setup.c | 2 +-
drivers/video/backlight/lv5207lp.c | 2 +-
include/linux/platform_data/lv5207lp.h | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/sh/boards/mach-kfr2r09/setup.c b/arch/sh/boards/mach-kfr2r09/setup.c
index 20f4db778ed6a..a18e80394aedc 100644
--- a/arch/sh/boards/mach-kfr2r09/setup.c
+++ b/arch/sh/boards/mach-kfr2r09/setup.c
@@ -202,7 +202,7 @@ static struct platform_device kfr2r09_sh_lcdc_device = {
};
static struct lv5207lp_platform_data kfr2r09_backlight_data = {
- .fbdev = &kfr2r09_sh_lcdc_device.dev,
+ .dev = &kfr2r09_sh_lcdc_device.dev,
.def_value = 13,
.max_value = 13,
};
diff --git a/drivers/video/backlight/lv5207lp.c b/drivers/video/backlight/lv5207lp.c
index 99ba4bc0a500d..739f45cd2d381 100644
--- a/drivers/video/backlight/lv5207lp.c
+++ b/drivers/video/backlight/lv5207lp.c
@@ -67,7 +67,7 @@ static int lv5207lp_backlight_check_fb(struct backlight_device *backlight,
{
struct lv5207lp *lv = bl_get_data(backlight);
- return lv->pdata->fbdev == NULL || lv->pdata->fbdev == info->device;
+ return !lv->pdata->dev || lv->pdata->dev == info->device;
}
static const struct backlight_ops lv5207lp_backlight_ops = {
diff --git a/include/linux/platform_data/lv5207lp.h b/include/linux/platform_data/lv5207lp.h
index c9da8d4027504..95d85c1394bca 100644
--- a/include/linux/platform_data/lv5207lp.h
+++ b/include/linux/platform_data/lv5207lp.h
@@ -8,7 +8,7 @@
struct device;
struct lv5207lp_platform_data {
- struct device *fbdev;
+ struct device *dev;
unsigned int max_value;
unsigned int def_value;
};
--
2.41.0
Powered by blists - more mailing lists