mirror of
https://github.com/u-boot/u-boot.git
synced 2024-12-15 07:43:33 +08:00
drivers: video: simple_panel: make simple panel independent of backlight
This patch updates the necessary Kconfigs to make simple panel driver independent of backlight driver and compiling backlight related code in simple-panel driver conditionally to when user has set CONFIG_BACKLIGHT. Signed-off-by: Nikhil M Jain <n-jain1@ti.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
2f3d6a4230
commit
3ebe3c703b
@ -63,12 +63,15 @@ static int simple_panel_of_to_plat(struct udevice *dev)
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
ret = uclass_get_device_by_phandle(UCLASS_PANEL_BACKLIGHT, dev,
|
||||
"backlight", &priv->backlight);
|
||||
"backlight", &priv->backlight);
|
||||
if (ret) {
|
||||
debug("%s: Cannot get backlight: ret=%d\n", __func__, ret);
|
||||
return log_ret(ret);
|
||||
if (ret != -ENOENT)
|
||||
return log_ret(ret);
|
||||
}
|
||||
|
||||
ret = gpio_request_by_name(dev, "enable-gpios", 0, &priv->enable,
|
||||
GPIOD_IS_OUT);
|
||||
if (ret) {
|
||||
|
Loading…
Reference in New Issue
Block a user