diff options
author | Andy Doan <andy.doan@linaro.org> | 2011-06-22 20:40:17 +0100 |
---|---|---|
committer | Andy Green <andy.green@linaro.org> | 2011-06-22 20:40:17 +0100 |
commit | 7210016019b63a36c867551dbf7724e8dcacde00 (patch) | |
tree | 81c2ab11c75ea250c29f05ba6d92b63036690d36 | |
parent | c8bf58b20524c70e5c0568339997d28a3907fb92 (diff) |
Subject: [PATCH 10/19] OMAP: DSS2: handle null pointer for no attached panel
A null pointer error occurs when a board file configures
a panel (LCD in my case) but doesn't have one attached
-rw-r--r-- | drivers/video/omap2/dss/dpi.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/video/omap2/dss/dpi.c b/drivers/video/omap2/dss/dpi.c index ff6bd30132d..c7acf559847 100644 --- a/drivers/video/omap2/dss/dpi.c +++ b/drivers/video/omap2/dss/dpi.c @@ -167,6 +167,9 @@ static int dpi_basic_init(struct omap_dss_device *dssdev) { bool is_tft; + if (!dssdev->manager) + return -ENODEV; + is_tft = (dssdev->panel.config & OMAP_DSS_LCD_TFT) != 0; dispc_set_parallel_interface_mode(dssdev->manager->id, |