drm/omap: Remove omap_dss_device dst field
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Wed, 12 Sep 2018 16:05:18 +0000 (19:05 +0300)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Mon, 18 Mar 2019 09:42:12 +0000 (11:42 +0200)
The field is only used in a safety check during device
connection/disconnection, where the src field can be easily used
instead. Remove it and use src.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Tested-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
drivers/gpu/drm/omapdrm/dss/base.c
drivers/gpu/drm/omapdrm/dss/omapdss.h

index 916225d62cc2a33131610684a6849bdb091d2361..76470ba456607bb54def3447ba48970d28bac3fc 100644 (file)
@@ -199,9 +199,8 @@ int omapdss_device_connect(struct dss_device *dss,
        }
 
        if (src) {
-               WARN_ON(src->dst);
+               WARN_ON(dst->src);
                dst->src = src;
-               src->dst = dst;
        }
 
        return 0;
@@ -219,11 +218,10 @@ void omapdss_device_disconnect(struct omap_dss_device *src,
        }
 
        if (src) {
-               if (WARN_ON(dst != src->dst))
+               if (WARN_ON(dst->src != src))
                        return;
 
                dst->src = NULL;
-               src->dst = NULL;
        }
 
        WARN_ON(dst->state != OMAP_DSS_DISPLAY_DISABLED);
index 4cd3874228a569c282e28bd250135971a1234ab5..fc82b8f545ae866b8e8063bbecefa27a2bbe1961 100644 (file)
@@ -406,7 +406,6 @@ struct omap_dss_device {
 
        struct dss_device *dss;
        struct omap_dss_device *src;
-       struct omap_dss_device *dst;
        struct omap_dss_device *next;
 
        struct list_head list;