All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hoegeun Kwon <hoegeun.kwon@samsung.com>
To: robh@kernel.org, thierry.reding@gmail.com, airlied@linux.ie,
	kgene@kernel.org, krzk@kernel.org, inki.dae@samsung.com
Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org, linux-samsung-soc@vger.kernel.org,
	a.hajda@samsung.com, cw00.choi@samsung.com,
	jh80.chung@samsung.com, Hoegeun Kwon <hoegeun.kwon@samsung.com>
Subject: [PATCH v7 2/4] drm/exynos: mic: Fix parse_dt function
Date: Thu, 05 Jan 2017 19:20:07 +0900	[thread overview]
Message-ID: <1483611609-23522-3-git-send-email-hoegeun.kwon@samsung.com> (raw)
In-Reply-To: <1483611609-23522-1-git-send-email-hoegeun.kwon@samsung.com>

The OF graph is not necessary because the panel is a child of
dsi. therefore, the parse_dt function of dsi does not need to
check the remote_node connected to the panel. and the whole
parse_dt function should be refactored later.

Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
---
 drivers/gpu/drm/exynos/exynos_drm_mic.c | 25 +++----------------------
 1 file changed, 3 insertions(+), 22 deletions(-)

diff --git a/drivers/gpu/drm/exynos/exynos_drm_mic.c b/drivers/gpu/drm/exynos/exynos_drm_mic.c
index fed1a94..cf9361a 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_mic.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_mic.c
@@ -269,28 +269,9 @@ static int parse_dt(struct exynos_mic *mic)
 		}
 		nodes[j++] = remote_node;
 
-		switch (i) {
-		case ENDPOINT_DECON_NODE:
-			/* decon node */
-			if (of_get_child_by_name(remote_node,
-						"i80-if-timings"))
-				mic->i80_mode = 1;
-
-			break;
-		case ENDPOINT_DSI_NODE:
-			/* panel node */
-			remote_node = get_remote_node(remote_node, 1);
-			if (!remote_node) {
-				ret = -EPIPE;
-				goto exit;
-			}
-			nodes[j++] = remote_node;
-
-			break;
-		default:
-			DRM_ERROR("mic: Unknown endpoint from MIC");
-			break;
-		}
+		if (i == ENDPOINT_DECON_NODE &&
+			of_get_child_by_name(remote_node, "i80-if-timings"))
+			mic->i80_mode = 1;
 	}
 
 exit:
-- 
1.9.1

WARNING: multiple messages have this Message-ID (diff)
From: Hoegeun Kwon <hoegeun.kwon-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
To: robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
	airlied-cv59FeDIM0c@public.gmane.org,
	kgene-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	krzk-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	inki.dae-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org
Cc: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	a.hajda-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
	cw00.choi-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
	jh80.chung-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org,
	Hoegeun Kwon
	<hoegeun.kwon-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Subject: [PATCH v7 2/4] drm/exynos: mic: Fix parse_dt function
Date: Thu, 05 Jan 2017 19:20:07 +0900	[thread overview]
Message-ID: <1483611609-23522-3-git-send-email-hoegeun.kwon@samsung.com> (raw)
In-Reply-To: <1483611609-23522-1-git-send-email-hoegeun.kwon-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>

The OF graph is not necessary because the panel is a child of
dsi. therefore, the parse_dt function of dsi does not need to
check the remote_node connected to the panel. and the whole
parse_dt function should be refactored later.

Signed-off-by: Hoegeun Kwon <hoegeun.kwon-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
---
 drivers/gpu/drm/exynos/exynos_drm_mic.c | 25 +++----------------------
 1 file changed, 3 insertions(+), 22 deletions(-)

diff --git a/drivers/gpu/drm/exynos/exynos_drm_mic.c b/drivers/gpu/drm/exynos/exynos_drm_mic.c
index fed1a94..cf9361a 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_mic.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_mic.c
@@ -269,28 +269,9 @@ static int parse_dt(struct exynos_mic *mic)
 		}
 		nodes[j++] = remote_node;
 
-		switch (i) {
-		case ENDPOINT_DECON_NODE:
-			/* decon node */
-			if (of_get_child_by_name(remote_node,
-						"i80-if-timings"))
-				mic->i80_mode = 1;
-
-			break;
-		case ENDPOINT_DSI_NODE:
-			/* panel node */
-			remote_node = get_remote_node(remote_node, 1);
-			if (!remote_node) {
-				ret = -EPIPE;
-				goto exit;
-			}
-			nodes[j++] = remote_node;
-
-			break;
-		default:
-			DRM_ERROR("mic: Unknown endpoint from MIC");
-			break;
-		}
+		if (i == ENDPOINT_DECON_NODE &&
+			of_get_child_by_name(remote_node, "i80-if-timings"))
+			mic->i80_mode = 1;
 	}
 
 exit:
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2017-01-05 10:21 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170105102011epcas1p416e0495978dbce7e73e900eb69a4b7ad@epcas1p4.samsung.com>
2017-01-05 10:20 ` [PATCH v7 0/4] Add support for the S6E3HA2 panel on TM2 board Hoegeun Kwon
2017-01-05 10:20   ` Hoegeun Kwon
     [not found]   ` <CGME20170105102012epcas5p3666c67cfc82d2439c993f917f8e2d0ce@epcas5p3.samsung.com>
2017-01-05 10:20     ` [PATCH v7 1/4] drm/exynos: mic: Add mode_set callback function Hoegeun Kwon
2017-01-05 10:20       ` Hoegeun Kwon
2017-01-11  5:33       ` Inki Dae
2017-01-11  5:33         ` Inki Dae
     [not found]   ` <CGME20170105102012epcas5p308c2d3ed269d9bf76f76f1d38422eb54@epcas5p3.samsung.com>
2017-01-05 10:20     ` Hoegeun Kwon [this message]
2017-01-05 10:20       ` [PATCH v7 2/4] drm/exynos: mic: Fix parse_dt function Hoegeun Kwon
2017-01-05 12:16       ` Andrzej Hajda
2017-01-05 12:16         ` Andrzej Hajda
2017-01-11  5:33       ` Inki Dae
2017-01-11  5:33         ` Inki Dae
     [not found]   ` <CGME20170105102012epcas1p4ddeb577ea84b5c2cdf7029666b2091c1@epcas1p4.samsung.com>
2017-01-05 10:20     ` [PATCH v7 3/4] drm/panel: Add support for S6E3HA2 panel driver on TM2 board Hoegeun Kwon
2017-01-05 10:20       ` Hoegeun Kwon
2017-01-05 18:09       ` Krzysztof Kozlowski
2017-01-06  5:22       ` Andi Shyti
2017-01-06  5:22         ` Andi Shyti
2017-01-06  5:32         ` Inki Dae
2017-01-06  5:32           ` Inki Dae
2017-01-06  8:18           ` Andi Shyti
2017-01-06  8:18             ` Andi Shyti
2017-01-06  8:36             ` Inki Dae
2017-01-06  8:36               ` Inki Dae
2017-01-09  7:37               ` Andrzej Hajda
2017-01-09  7:37                 ` Andrzej Hajda
2017-01-09  9:19                 ` Inki Dae
2017-01-09  9:19                   ` Inki Dae
2017-01-09  9:53                   ` Andrzej Hajda
2017-01-09  9:53                     ` Andrzej Hajda
2017-01-10  1:15                     ` Inki Dae
     [not found]   ` <CGME20170105102013epcas5p3098ddb99e516ef138cc41d63c7591a79@epcas5p3.samsung.com>
2017-01-05 10:20     ` [PATCH v7 4/4] arm64: dts: exynos: Add support for S6E3HA2 panel device " Hoegeun Kwon
2017-01-05 10:20       ` Hoegeun Kwon
2017-01-06  4:49       ` Andi Shyti
2017-01-06  4:49         ` Andi Shyti

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1483611609-23522-3-git-send-email-hoegeun.kwon@samsung.com \
    --to=hoegeun.kwon@samsung.com \
    --cc=a.hajda@samsung.com \
    --cc=airlied@linux.ie \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=inki.dae@samsung.com \
    --cc=jh80.chung@samsung.com \
    --cc=kgene@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=thierry.reding@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.