drm/omap: dss: Store dss_device pointer in omap_dss_device
Storing the dss_device pointer in the omap_dss_device structure will allow accessing the dss_device from the dss_mgr API functions. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
This commit is contained in:

committed by
Tomi Valkeinen

parent
c1dfe721e0
commit
f324b2798c
@@ -177,7 +177,8 @@ done:
|
||||
}
|
||||
EXPORT_SYMBOL(omapdss_device_get_next);
|
||||
|
||||
int omapdss_device_connect(struct omap_dss_device *src,
|
||||
int omapdss_device_connect(struct dss_device *dss,
|
||||
struct omap_dss_device *src,
|
||||
struct omap_dss_device *dst)
|
||||
{
|
||||
int ret;
|
||||
@@ -187,13 +188,17 @@ int omapdss_device_connect(struct omap_dss_device *src,
|
||||
if (omapdss_device_is_connected(src))
|
||||
return -EBUSY;
|
||||
|
||||
src->dss = dss;
|
||||
|
||||
if (src->driver)
|
||||
ret = src->driver->connect(src);
|
||||
else
|
||||
ret = src->ops->connect(src, dst);
|
||||
|
||||
if (ret < 0)
|
||||
if (ret < 0) {
|
||||
src->dss = NULL;
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (dst) {
|
||||
dst->src = src;
|
||||
@@ -226,6 +231,8 @@ void omapdss_device_disconnect(struct omap_dss_device *src,
|
||||
src->driver->disconnect(src);
|
||||
else
|
||||
src->ops->disconnect(src, dst);
|
||||
|
||||
src->dss = NULL;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(omapdss_device_disconnect);
|
||||
|
||||
|
Reference in New Issue
Block a user