summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7250753)
raw | patch | inline | side by side (parent: 7250753)
author | Archit Taneja <archit@ti.com> | |
Wed, 5 Jun 2013 11:03:54 +0000 (16:33 +0530) | ||
committer | Archit Taneja <archit@ti.com> | |
Wed, 5 Jun 2013 11:04:52 +0000 (16:34 +0530) |
The TFCS panel driver internally uses the TLC brightness controller/gpio chip
to configure the panel. The TLC i2c driver is registered first following the
registration of the omapdss TFCS panel driver.
Currently, the TFCS panel driver can regsiter successfully even if the TLC
driver isn't probed successfully. Add a check in the TFCS driver probe if the
TLC i2c client device has a valid driver attached to it.
This removes the crash seen on Vayu evm when the LCD daughter card isn't
connected to the main Vayu CPU board.
Signed-off-by: Archit Taneja <archit@ti.com>
to configure the panel. The TLC i2c driver is registered first following the
registration of the omapdss TFCS panel driver.
Currently, the TFCS panel driver can regsiter successfully even if the TLC
driver isn't probed successfully. Add a check in the TFCS driver probe if the
TLC i2c client device has a valid driver attached to it.
This removes the crash seen on Vayu evm when the LCD daughter card isn't
connected to the main Vayu CPU board.
Signed-off-by: Archit Taneja <archit@ti.com>
drivers/video/omap2/displays/panel-tfcs9700.c | patch | blob | history |
diff --git a/drivers/video/omap2/displays/panel-tfcs9700.c b/drivers/video/omap2/displays/panel-tfcs9700.c
index 11b9b707aeec6fca365d67a861e9bf9473f78cb1..1bc2c087660669f1da212213dbf76cd98b7f4890 100644 (file)
static int tfc_s9700_probe(struct omap_dss_device *dssdev)
{
struct panel_drv_data *ddata;
+ struct device *i2c_dev;
int r;
ddata = devm_kzalloc(&dssdev->dev, sizeof(*ddata), GFP_KERNEL);
return -EINVAL;
}
+ i2c_dev = &ddata->tlc_client->dev;
+ if (!i2c_dev->driver) {
+ dev_err(&dssdev->dev, "tlc i2c client has no driver\n");
+ return -EINVAL;
+ }
if (dssdev->phy.dpi.data_lines == 24)
ddata->dith = 0;