summaryrefslogtreecommitdiff
path: root/drivers/staging/omapdrm/omap_connector.c
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2011-09-01 08:07:10 +0100
committerAndy Green <andy.green@linaro.org>2011-09-01 08:07:10 +0100
commit15d2a95ade13bbac1b86b4a0d0b646cae3d17141 (patch)
tree9f525b24d6d3d8718017cf5add9350eb66acbde5 /drivers/staging/omapdrm/omap_connector.c
parent741b68d61248d1b83cd57b27d3da50b5e57aebd2 (diff)
drm/omap: make module unloading work
Uninitialize properly to make module unloading work. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/staging/omapdrm/omap_connector.c')
-rw-r--r--drivers/staging/omapdrm/omap_connector.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/staging/omapdrm/omap_connector.c b/drivers/staging/omapdrm/omap_connector.c
index f0c30213609..c1071c171bd 100644
--- a/drivers/staging/omapdrm/omap_connector.c
+++ b/drivers/staging/omapdrm/omap_connector.c
@@ -106,11 +106,16 @@ enum drm_connector_status omap_connector_detect(
static void omap_connector_destroy(struct drm_connector *connector)
{
struct omap_connector *omap_connector = to_omap_connector(connector);
+ struct omap_dss_device *dssdev = omap_connector->dssdev;
+
+ dssdev->driver->disable(dssdev);
DBG("%s", omap_connector->dssdev->name);
drm_sysfs_connector_remove(connector);
drm_connector_cleanup(connector);
kfree(omap_connector);
+
+ omap_dss_put_device(dssdev);
}
#define MAX_EDID 256
@@ -341,6 +346,8 @@ struct drm_connector * omap_connector_init(struct drm_device *dev,
DBG("%s", dssdev->name);
+ omap_dss_get_device(dssdev);
+
omap_connector = kzalloc(sizeof(struct omap_connector), GFP_KERNEL);
if (!omap_connector) {
dev_err(dev->dev, "could not allocate connector\n");