> -----Original Message----- > From: Valkeinen, Tomi > Sent: Monday, November 14, 2011 1:59 PM > To: linux-media@xxxxxxxxxxxxxxx; Hiremath, Vaibhav > Cc: Taneja, Archit; Valkeinen, Tomi > Subject: [PATCH] omap_vout: fix crash if no driver for a display > > omap_vout crashes on start if a corresponding driver is not loaded for a > display device. > > This patch changes omap_vout init sequence to skip devices without a > driver. > > Signed-off-by: Tomi Valkeinen <tomi.valkeinen@xxxxxx> > --- > drivers/media/video/omap/omap_vout.c | 8 ++++++++ > 1 files changed, 8 insertions(+), 0 deletions(-) > > diff --git a/drivers/media/video/omap/omap_vout.c > b/drivers/media/video/omap/omap_vout.c > index 9c5c19f..2d2a136 100644 > --- a/drivers/media/video/omap/omap_vout.c > +++ b/drivers/media/video/omap/omap_vout.c > @@ -2169,6 +2169,14 @@ static int __init omap_vout_probe(struct > platform_device *pdev) > vid_dev->num_displays = 0; > for_each_dss_dev(dssdev) { > omap_dss_get_device(dssdev); > + > + if (!dssdev->driver) { > + dev_warn(&pdev->dev, "no driver for display: %s\n", > + dssdev->name); > + omap_dss_put_device(dssdev); > + continue; > + } > + > vid_dev->displays[vid_dev->num_displays++] = dssdev; > } > Acked-by: Vaibhav Hiremath <hvaibhav@xxxxxx> Thanks, Vaibhav > -- > 1.7.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html