From: Hoegeun Kwon <hoegeun.kwon@samsung.com>
To: inki.dae@samsung.com, jy0922.shim@samsung.com,
sw0312.kim@samsung.com, airlied@linux.ie, kgene@kernel.org,
krzk@kernel.org, robh+dt@kernel.org, mark.rutland@arm.com,
catalin.marinas@arm.com, will.deacon@arm.com
Cc: devicetree@vger.kernel.org, linux-samsung-soc@vger.kernel.org,
linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org,
javier@osg.samsung.com, Hoegeun Kwon <hoegeun.kwon@samsung.com>,
linux-arm-kernel@lists.infradead.org
Subject: [RESEND PATCH v2 1/5] drm/exynos: dsi: Fix the parse_dt function
Date: Tue, 28 Feb 2017 17:17:55 +0900 [thread overview]
Message-ID: <1488269879-28876-2-git-send-email-hoegeun.kwon@samsung.com> (raw)
In-Reply-To: <1488269879-28876-1-git-send-email-hoegeun.kwon@samsung.com>
The dsi + panel is a parental relationship, so OF grpah is not needed.
Therefore, the current dsi_parse_dt function will throw an error,
because there is no linked OF graph for case such as fimd + dsi +
panel. So this patch parse the Pll, burst and esc clock frequency
properties in dsi_parse_dt and modified to create a bridge_node only
if there is an OF graph associated with dsi.
So I think the ABI breakage is needed.
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Reviewed-by: Andrzej Hajda <a.hajda@samsung.com>
---
drivers/gpu/drm/exynos/exynos_drm_dsi.c | 32 ++++++++------------------------
1 file changed, 8 insertions(+), 24 deletions(-)
diff --git a/drivers/gpu/drm/exynos/exynos_drm_dsi.c b/drivers/gpu/drm/exynos/exynos_drm_dsi.c
index f5c04d0..2d4e118 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_dsi.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_dsi.c
@@ -1652,39 +1652,23 @@ static int exynos_dsi_parse_dt(struct exynos_dsi *dsi)
if (ret < 0)
return ret;
- ep = of_graph_get_endpoint_by_regs(node, DSI_PORT_OUT, 0);
- if (!ep) {
- dev_err(dev, "no output port with endpoint specified\n");
- return -EINVAL;
- }
-
- ret = exynos_dsi_of_read_u32(ep, "samsung,burst-clock-frequency",
+ ret = exynos_dsi_of_read_u32(node, "samsung,burst-clock-frequency",
&dsi->burst_clk_rate);
if (ret < 0)
- goto end;
+ return ret;
- ret = exynos_dsi_of_read_u32(ep, "samsung,esc-clock-frequency",
+ ret = exynos_dsi_of_read_u32(node, "samsung,esc-clock-frequency",
&dsi->esc_clk_rate);
if (ret < 0)
- goto end;
-
- of_node_put(ep);
+ return ret;
ep = of_graph_get_next_endpoint(node, NULL);
- if (!ep) {
- ret = -EINVAL;
- goto end;
- }
-
- dsi->bridge_node = of_graph_get_remote_port_parent(ep);
- if (!dsi->bridge_node) {
- ret = -EINVAL;
- goto end;
+ if (ep) {
+ dsi->bridge_node = of_graph_get_remote_port_parent(ep);
+ of_node_put(ep);
}
-end:
- of_node_put(ep);
- return ret;
+ return 0;
}
static int exynos_dsi_bind(struct device *dev, struct device *master,
--
1.9.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2017-02-28 8:18 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20170228081811epcas5p3c0a8151d94511e47a0e0d2b8787b1fb0@epcas5p3.samsung.com>
2017-02-28 8:17 ` [RESEND PATCH v2 0/5] Fix the parse_dt of exynos dsi and remove the OF graph Hoegeun Kwon
[not found] ` <CGME20170228081811epcas5p3931e12839e81f94b58bbd5eaa7a4b63b@epcas5p3.samsung.com>
2017-02-28 8:17 ` Hoegeun Kwon [this message]
[not found] ` <CGME20170228081811epcas5p322c1570e2e29c69592f798916b816a41@epcas5p3.samsung.com>
2017-02-28 8:17 ` [RESEND PATCH v2 2/5] arm64: dts: exynos: Remove the OF graph from DSI node for exynos5433 dts Hoegeun Kwon
[not found] ` <CGME20170228081812epcas5p36a8acfef59709dfef7e03271e32f9fa9@epcas5p3.samsung.com>
2017-02-28 8:17 ` [RESEND PATCH v2 3/5] arm: dts: Remove the OF graph from DSI node for exynos3250 dts Hoegeun Kwon
[not found] ` <CGME20170228081812epcas5p3d20eddc91da42ec4a0d973ddc59d184a@epcas5p3.samsung.com>
2017-02-28 8:17 ` [RESEND PATCH v2 4/5] arm: dts: Remove the OF graph from DSI node for exynos4412 dts Hoegeun Kwon
[not found] ` <CGME20170228081812epcas5p3bf4f6f273099fbb6e6d26ffbab76f4d7@epcas5p3.samsung.com>
2017-02-28 8:17 ` [RESEND PATCH v2 5/5] arm: dts: Remove the OF graph from DSI node for exynos4210 dts Hoegeun Kwon
2017-02-28 9:58 ` [RESEND PATCH v2 0/5] Fix the parse_dt of exynos dsi and remove the OF graph Krzysztof Kozlowski
[not found] ` <CAJKOXPfv8wJ+0L4G_0sB1Qh-svXx4VvNJH_1THSy5SsXuUstzA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-03-02 1:44 ` Hoegeun Kwon
2017-03-02 7:23 ` Krzysztof Kozlowski
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=1488269879-28876-2-git-send-email-hoegeun.kwon@samsung.com \
--to=hoegeun.kwon@samsung.com \
--cc=airlied@linux.ie \
--cc=catalin.marinas@arm.com \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=inki.dae@samsung.com \
--cc=javier@osg.samsung.com \
--cc=jy0922.shim@samsung.com \
--cc=kgene@kernel.org \
--cc=krzk@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=robh+dt@kernel.org \
--cc=sw0312.kim@samsung.com \
--cc=will.deacon@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).