Skip to contentSkip to conversation

video: ipuv3: fix building with disabled panel driver

PATCH New Anatolij Gustschin 1 participant 2 messages May 25, 2020 – Jun 19, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 video: ipuv3: fix building with disabled panel driver

Panel code might be disabled for some boards, make this driver code optional.

---
 drivers/video/imx/mxc_ipuv3_fb.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
drivers/video/imx/mxc_ipuv3_fb.c +7 -4
index c7a944c1d5..017a8fb22a 100644
@@ -627,7 +627,6 @@ static int ipuv3_video_probe(struct udevice *dev)
 #if defined(CONFIG_DISPLAY)
 	struct udevice *disp_dev;
 #endif
-	struct udevice *panel_dev;
 	u32 fb_start, fb_end;
 	int ret;
 
@@ -654,9 +653,13 @@ static int ipuv3_video_probe(struct udevice *dev)
 			return ret;
 	}
 #endif
-	ret = uclass_get_device(UCLASS_PANEL, 0, &panel_dev);
-	if (panel_dev)
-		panel_enable_backlight(panel_dev);
+	if (CONFIG_IS_ENABLED(PANEL)) {
+		struct udevice *panel_dev;
+
+		ret = uclass_get_device(UCLASS_PANEL, 0, &panel_dev);
+		if (panel_dev)
+			panel_enable_backlight(panel_dev);
+	}
 
 	uc_priv->xsize = gmode->xres;
 	uc_priv->ysize = gmode->yres;
Signature · 1 line
2.17.1
#1 lore raw

PATCH 1/1 video: ipuv3: fix building with disabled panel driver

Quoted 7 lines · On Tue, 26 May 2020 00:09:22 +0200 Anatolij Gustschin agust at denx.de wrote:

Panel code might be disabled for some boards, make this driver code optional.

---
 drivers/video/imx/mxc_ipuv3_fb.c | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

Applied to u-boot-video/next, thanks!

--
Anatolij