]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
OMAPDSS: rename omap_dss_device's 'device' field to 'dst'
authorTomi Valkeinen <tomi.valkeinen@ti.com>
Wed, 24 Jul 2013 10:06:54 +0000 (13:06 +0300)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Fri, 30 Aug 2013 05:51:11 +0000 (08:51 +0300)
In the old panel device model we had omap_dss_output entities,
representing the encoders in the DSS block. This entity had "device"
field, which pointed to the panel that was using the omap_dss_output.

With the new panel device model, the omap_dss_output is integrated into
omap_dss_device, which now represents a "display entity". Thus the "device"
field, now in omap_dss_device, points to the next entity in the display
entity-chain.

This patch renames the "device" field to "dst", which much better tells
what the field points to.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Archit Taneja <archit@ti.com>
drivers/video/omap2/displays-new/encoder-tfp410.c
drivers/video/omap2/displays-new/encoder-tpd12s015.c
drivers/video/omap2/dss/apply.c
drivers/video/omap2/dss/dpi.c
drivers/video/omap2/dss/dsi.c
drivers/video/omap2/dss/hdmi.c
drivers/video/omap2/dss/output.c
drivers/video/omap2/dss/sdi.c
drivers/video/omap2/dss/venc.c
include/video/omapdss.h

index 454f7714d87ae8fc8a9286fa76796e86b3e6929c..4a291e756be944cfc0dcb647312d520891bca4e0 100644 (file)
@@ -44,7 +44,7 @@ static int tfp410_connect(struct omap_dss_device *dssdev,
                return r;
 
        dst->src = dssdev;
-       dssdev->device = dst;
+       dssdev->dst = dst;
 
        return 0;
 }
@@ -59,12 +59,12 @@ static void tfp410_disconnect(struct omap_dss_device *dssdev,
        if (!omapdss_device_is_connected(dssdev))
                return;
 
-       WARN_ON(dst != dssdev->device);
-       if (dst != dssdev->device)
+       WARN_ON(dst != dssdev->dst);
+       if (dst != dssdev->dst)
                return;
 
        dst->src = NULL;
-       dssdev->device = NULL;
+       dssdev->dst = NULL;
 
        in->ops.dpi->disconnect(in, &ddata->dssdev);
 }
@@ -244,7 +244,7 @@ static int __exit tfp410_remove(struct platform_device *pdev)
 
        WARN_ON(omapdss_device_is_connected(dssdev));
        if (omapdss_device_is_connected(dssdev))
-               tfp410_disconnect(dssdev, dssdev->device);
+               tfp410_disconnect(dssdev, dssdev->dst);
 
        omap_dss_put_device(in);
 
index a3d29914d3b68fe36c9a903c8166735ca951d836..798ef200b055590395ea1e05969b6a7b77c3aa1a 100644 (file)
@@ -67,7 +67,7 @@ static int tpd_connect(struct omap_dss_device *dssdev,
                return r;
 
        dst->src = dssdev;
-       dssdev->device = dst;
+       dssdev->dst = dst;
 
        INIT_COMPLETION(ddata->hpd_completion);
 
@@ -95,15 +95,15 @@ static void tpd_disconnect(struct omap_dss_device *dssdev,
        struct panel_drv_data *ddata = to_panel_data(dssdev);
        struct omap_dss_device *in = ddata->in;
 
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        gpio_set_value_cansleep(ddata->ct_cp_hpd_gpio, 0);
 
        dst->src = NULL;
-       dssdev->device = NULL;
+       dssdev->dst = NULL;
 
        in->ops.hdmi->disconnect(in, &ddata->dssdev);
 }
@@ -372,7 +372,7 @@ static int __exit tpd_remove(struct platform_device *pdev)
 
        WARN_ON(omapdss_device_is_connected(dssdev));
        if (omapdss_device_is_connected(dssdev))
-               tpd_disconnect(dssdev, dssdev->device);
+               tpd_disconnect(dssdev, dssdev->dst);
 
        omap_dss_put_device(in);
 
index d6212d63cfb213a4f09fb95c9e4f03faea03edcf..60758dbefd79fda6d64df8246479b4dd1407f6cd 100644 (file)
@@ -428,8 +428,8 @@ static struct omap_dss_device *dss_mgr_get_device(struct omap_overlay_manager *m
        if (dssdev == NULL)
                return NULL;
 
-       while (dssdev->device)
-               dssdev = dssdev->device;
+       while (dssdev->dst)
+               dssdev = dssdev->dst;
 
        if (dssdev->driver)
                return dssdev;
index b268d046003852cf72caf85b6078e6b22275bd6e..bd48cde5356125e49e7d56b4a9109f4195496303 100644 (file)
@@ -643,9 +643,9 @@ static int dpi_connect(struct omap_dss_device *dssdev,
 static void dpi_disconnect(struct omap_dss_device *dssdev,
                struct omap_dss_device *dst)
 {
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        omapdss_output_unset_device(dssdev);
index 3daaf7ea4281f680363a8b81b92c9d129ee9ceef..a598b5812285fb5aa468d6bac1dedf687029158c 100644 (file)
@@ -5264,9 +5264,9 @@ static int dsi_connect(struct omap_dss_device *dssdev,
 static void dsi_disconnect(struct omap_dss_device *dssdev,
                struct omap_dss_device *dst)
 {
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        omapdss_output_unset_device(dssdev);
index 0b8e4dec2c0e04ed1ea304712dc1899114f0167a..75f3c740ef8cd129b5f2da04fcbc7b286a2f8958 100644 (file)
@@ -900,9 +900,9 @@ static int hdmi_connect(struct omap_dss_device *dssdev,
 static void hdmi_disconnect(struct omap_dss_device *dssdev,
                struct omap_dss_device *dst)
 {
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        omapdss_output_unset_device(dssdev);
index 15f47af8e0480c6206bc416b4b733bb2f0937716..2ab3afa615e8dc4e7316700f94d69eb638381ea5 100644 (file)
@@ -34,9 +34,9 @@ int omapdss_output_set_device(struct omap_dss_device *out,
 
        mutex_lock(&output_lock);
 
-       if (out->device) {
+       if (out->dst) {
                DSSERR("output already has device %s connected to it\n",
-                       out->device->name);
+                       out->dst->name);
                r = -EINVAL;
                goto err;
        }
@@ -47,7 +47,7 @@ int omapdss_output_set_device(struct omap_dss_device *out,
                goto err;
        }
 
-       out->device = dssdev;
+       out->dst = dssdev;
        dssdev->src = out;
 
        mutex_unlock(&output_lock);
@@ -66,21 +66,21 @@ int omapdss_output_unset_device(struct omap_dss_device *out)
 
        mutex_lock(&output_lock);
 
-       if (!out->device) {
+       if (!out->dst) {
                DSSERR("output doesn't have a device connected to it\n");
                r = -EINVAL;
                goto err;
        }
 
-       if (out->device->state != OMAP_DSS_DISPLAY_DISABLED) {
+       if (out->dst->state != OMAP_DSS_DISPLAY_DISABLED) {
                DSSERR("device %s is not disabled, cannot unset device\n",
-                               out->device->name);
+                               out->dst->name);
                r = -EINVAL;
                goto err;
        }
 
-       out->device->src = NULL;
-       out->device = NULL;
+       out->dst->src = NULL;
+       out->dst = NULL;
 
        mutex_unlock(&output_lock);
 
index b3276889b58ad34529a9ffaa62b072499d2ac151..ccc569ae7ccaddf970436ba9f6645978f9b57118 100644 (file)
@@ -306,9 +306,9 @@ static int sdi_connect(struct omap_dss_device *dssdev,
 static void sdi_disconnect(struct omap_dss_device *dssdev,
                struct omap_dss_device *dst)
 {
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        omapdss_output_unset_device(dssdev);
index 0d8ccdeb9639c9b9462407ba7135a4120c2f2135..5f88ac47b7fa73d56e9e87afd171fb28fc6b81ba 100644 (file)
@@ -753,9 +753,9 @@ static int venc_connect(struct omap_dss_device *dssdev,
 static void venc_disconnect(struct omap_dss_device *dssdev,
                struct omap_dss_device *dst)
 {
-       WARN_ON(dst != dssdev->device);
+       WARN_ON(dst != dssdev->dst);
 
-       if (dst != dssdev->device)
+       if (dst != dssdev->dst)
                return;
 
        omapdss_output_unset_device(dssdev);
index 5fa81ddb43adfebe37d19a985a0f0e8fe68a9447..3d7c51a6f9ff27de17f5f748afb00bc190e3d6cf 100644 (file)
@@ -793,7 +793,7 @@ struct omap_dss_device {
        /* dynamic fields */
        struct omap_overlay_manager *manager;
 
-       struct omap_dss_device *device;
+       struct omap_dss_device *dst;
 };
 
 struct omap_dss_hdmi_data