All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chen-Yu Tsai <wens@csie.org>
To: Maxime Ripard <maxime.ripard@free-electrons.com>,
	David Airlie <airlied@linux.ie>, Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>
Cc: Chen-Yu Tsai <wens@csie.org>,
	dri-devel@lists.freedesktop.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	linux-sunxi@googlegroups.com
Subject: [PATCH v2 4/8] drm/sun4i: Add compatible string for A31/A31s TCON (timing controller)
Date: Thu, 20 Oct 2016 11:43:40 +0800	[thread overview]
Message-ID: <20161020034344.14154-5-wens@csie.org> (raw)
In-Reply-To: <20161020034344.14154-1-wens@csie.org>

The A31 TCON has mux controls for how TCON outputs are routed to the
HDMI and MIPI DSI blocks.

Since the A31s does not have MIPI DSI, it only has a mux for the HDMI
controller input.

This patch only adds support for the compatible strings. Actual support
for the mux controls should be added with HDMI and MIPI DSI support.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt |  4 +++-
 drivers/gpu/drm/sun4i/sun4i_drv.c                             |  2 ++
 drivers/gpu/drm/sun4i/sun4i_tcon.c                            | 10 ++++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
index 5368961cd727..15fdca8909f2 100644
--- a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
+++ b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
@@ -28,6 +28,8 @@ The TCON acts as a timing controller for RGB, LVDS and TV interfaces.
 Required properties:
  - compatible: value must be either:
    * allwinner,sun5i-a13-tcon
+   * allwinner,sun6i-a31-tcon
+   * allwinner,sun6i-a31s-tcon
    * allwinner,sun8i-a33-tcon
  - reg: base address and size of memory-mapped region
  - interrupts: interrupt associated to this IP
@@ -50,7 +52,7 @@ Required properties:
   second the block connected to the TCON channel 1 (usually the TV
   encoder)
 
-On the A13, there is one more clock required:
+On SoCs other than the A33, there is one more clock required:
    - 'tcon-ch1': The clock driving the TCON channel 1
 
 DRC
diff --git a/drivers/gpu/drm/sun4i/sun4i_drv.c b/drivers/gpu/drm/sun4i/sun4i_drv.c
index 0da9862ad8ed..a15c231fbd59 100644
--- a/drivers/gpu/drm/sun4i/sun4i_drv.c
+++ b/drivers/gpu/drm/sun4i/sun4i_drv.c
@@ -207,6 +207,8 @@ static bool sun4i_drv_node_is_frontend(struct device_node *node)
 static bool sun4i_drv_node_is_tcon(struct device_node *node)
 {
 	return of_device_is_compatible(node, "allwinner,sun5i-a13-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31s-tcon") ||
 		of_device_is_compatible(node, "allwinner,sun8i-a33-tcon");
 }
 
diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c
index 7658f0337e0b..c6afb2448655 100644
--- a/drivers/gpu/drm/sun4i/sun4i_tcon.c
+++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c
@@ -587,12 +587,22 @@ static const struct sun4i_tcon_quirks sun5i_a13_quirks = {
 	.has_channel_1	= true,
 };
 
+static const struct sun4i_tcon_quirks sun6i_a31_quirks = {
+	.has_channel_1	= true,
+};
+
+static const struct sun4i_tcon_quirks sun6i_a31s_quirks = {
+	.has_channel_1	= true,
+};
+
 static const struct sun4i_tcon_quirks sun8i_a33_quirks = {
 	/* nothing is supported */
 };
 
 static const struct of_device_id sun4i_tcon_of_table[] = {
 	{ .compatible = "allwinner,sun5i-a13-tcon", .data = &sun5i_a13_quirks },
+	{ .compatible = "allwinner,sun6i-a31-tcon", .data = &sun6i_a31_quirks },
+	{ .compatible = "allwinner,sun6i-a31s-tcon", .data = &sun6i_a31s_quirks },
 	{ .compatible = "allwinner,sun8i-a33-tcon", .data = &sun8i_a33_quirks },
 	{ }
 };
-- 
2.9.3

WARNING: multiple messages have this Message-ID (diff)
From: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>
To: Maxime Ripard
	<maxime.ripard-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>,
	David Airlie <airlied-cv59FeDIM0c@public.gmane.org>,
	Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>
Cc: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: [PATCH v2 4/8] drm/sun4i: Add compatible string for A31/A31s TCON (timing controller)
Date: Thu, 20 Oct 2016 11:43:40 +0800	[thread overview]
Message-ID: <20161020034344.14154-5-wens@csie.org> (raw)
In-Reply-To: <20161020034344.14154-1-wens-jdAy2FN1RRM@public.gmane.org>

The A31 TCON has mux controls for how TCON outputs are routed to the
HDMI and MIPI DSI blocks.

Since the A31s does not have MIPI DSI, it only has a mux for the HDMI
controller input.

This patch only adds support for the compatible strings. Actual support
for the mux controls should be added with HDMI and MIPI DSI support.

Signed-off-by: Chen-Yu Tsai <wens-jdAy2FN1RRM@public.gmane.org>
---
 Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt |  4 +++-
 drivers/gpu/drm/sun4i/sun4i_drv.c                             |  2 ++
 drivers/gpu/drm/sun4i/sun4i_tcon.c                            | 10 ++++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
index 5368961cd727..15fdca8909f2 100644
--- a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
+++ b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
@@ -28,6 +28,8 @@ The TCON acts as a timing controller for RGB, LVDS and TV interfaces.
 Required properties:
  - compatible: value must be either:
    * allwinner,sun5i-a13-tcon
+   * allwinner,sun6i-a31-tcon
+   * allwinner,sun6i-a31s-tcon
    * allwinner,sun8i-a33-tcon
  - reg: base address and size of memory-mapped region
  - interrupts: interrupt associated to this IP
@@ -50,7 +52,7 @@ Required properties:
   second the block connected to the TCON channel 1 (usually the TV
   encoder)
 
-On the A13, there is one more clock required:
+On SoCs other than the A33, there is one more clock required:
    - 'tcon-ch1': The clock driving the TCON channel 1
 
 DRC
diff --git a/drivers/gpu/drm/sun4i/sun4i_drv.c b/drivers/gpu/drm/sun4i/sun4i_drv.c
index 0da9862ad8ed..a15c231fbd59 100644
--- a/drivers/gpu/drm/sun4i/sun4i_drv.c
+++ b/drivers/gpu/drm/sun4i/sun4i_drv.c
@@ -207,6 +207,8 @@ static bool sun4i_drv_node_is_frontend(struct device_node *node)
 static bool sun4i_drv_node_is_tcon(struct device_node *node)
 {
 	return of_device_is_compatible(node, "allwinner,sun5i-a13-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31s-tcon") ||
 		of_device_is_compatible(node, "allwinner,sun8i-a33-tcon");
 }
 
diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c
index 7658f0337e0b..c6afb2448655 100644
--- a/drivers/gpu/drm/sun4i/sun4i_tcon.c
+++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c
@@ -587,12 +587,22 @@ static const struct sun4i_tcon_quirks sun5i_a13_quirks = {
 	.has_channel_1	= true,
 };
 
+static const struct sun4i_tcon_quirks sun6i_a31_quirks = {
+	.has_channel_1	= true,
+};
+
+static const struct sun4i_tcon_quirks sun6i_a31s_quirks = {
+	.has_channel_1	= true,
+};
+
 static const struct sun4i_tcon_quirks sun8i_a33_quirks = {
 	/* nothing is supported */
 };
 
 static const struct of_device_id sun4i_tcon_of_table[] = {
 	{ .compatible = "allwinner,sun5i-a13-tcon", .data = &sun5i_a13_quirks },
+	{ .compatible = "allwinner,sun6i-a31-tcon", .data = &sun6i_a31_quirks },
+	{ .compatible = "allwinner,sun6i-a31s-tcon", .data = &sun6i_a31s_quirks },
 	{ .compatible = "allwinner,sun8i-a33-tcon", .data = &sun8i_a33_quirks },
 	{ }
 };
-- 
2.9.3

WARNING: multiple messages have this Message-ID (diff)
From: wens@csie.org (Chen-Yu Tsai)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 4/8] drm/sun4i: Add compatible string for A31/A31s TCON (timing controller)
Date: Thu, 20 Oct 2016 11:43:40 +0800	[thread overview]
Message-ID: <20161020034344.14154-5-wens@csie.org> (raw)
In-Reply-To: <20161020034344.14154-1-wens@csie.org>

The A31 TCON has mux controls for how TCON outputs are routed to the
HDMI and MIPI DSI blocks.

Since the A31s does not have MIPI DSI, it only has a mux for the HDMI
controller input.

This patch only adds support for the compatible strings. Actual support
for the mux controls should be added with HDMI and MIPI DSI support.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt |  4 +++-
 drivers/gpu/drm/sun4i/sun4i_drv.c                             |  2 ++
 drivers/gpu/drm/sun4i/sun4i_tcon.c                            | 10 ++++++++++
 3 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
index 5368961cd727..15fdca8909f2 100644
--- a/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
+++ b/Documentation/devicetree/bindings/display/sunxi/sun4i-drm.txt
@@ -28,6 +28,8 @@ The TCON acts as a timing controller for RGB, LVDS and TV interfaces.
 Required properties:
  - compatible: value must be either:
    * allwinner,sun5i-a13-tcon
+   * allwinner,sun6i-a31-tcon
+   * allwinner,sun6i-a31s-tcon
    * allwinner,sun8i-a33-tcon
  - reg: base address and size of memory-mapped region
  - interrupts: interrupt associated to this IP
@@ -50,7 +52,7 @@ Required properties:
   second the block connected to the TCON channel 1 (usually the TV
   encoder)
 
-On the A13, there is one more clock required:
+On SoCs other than the A33, there is one more clock required:
    - 'tcon-ch1': The clock driving the TCON channel 1
 
 DRC
diff --git a/drivers/gpu/drm/sun4i/sun4i_drv.c b/drivers/gpu/drm/sun4i/sun4i_drv.c
index 0da9862ad8ed..a15c231fbd59 100644
--- a/drivers/gpu/drm/sun4i/sun4i_drv.c
+++ b/drivers/gpu/drm/sun4i/sun4i_drv.c
@@ -207,6 +207,8 @@ static bool sun4i_drv_node_is_frontend(struct device_node *node)
 static bool sun4i_drv_node_is_tcon(struct device_node *node)
 {
 	return of_device_is_compatible(node, "allwinner,sun5i-a13-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31-tcon") ||
+		of_device_is_compatible(node, "allwinner,sun6i-a31s-tcon") ||
 		of_device_is_compatible(node, "allwinner,sun8i-a33-tcon");
 }
 
diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c
index 7658f0337e0b..c6afb2448655 100644
--- a/drivers/gpu/drm/sun4i/sun4i_tcon.c
+++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c
@@ -587,12 +587,22 @@ static const struct sun4i_tcon_quirks sun5i_a13_quirks = {
 	.has_channel_1	= true,
 };
 
+static const struct sun4i_tcon_quirks sun6i_a31_quirks = {
+	.has_channel_1	= true,
+};
+
+static const struct sun4i_tcon_quirks sun6i_a31s_quirks = {
+	.has_channel_1	= true,
+};
+
 static const struct sun4i_tcon_quirks sun8i_a33_quirks = {
 	/* nothing is supported */
 };
 
 static const struct of_device_id sun4i_tcon_of_table[] = {
 	{ .compatible = "allwinner,sun5i-a13-tcon", .data = &sun5i_a13_quirks },
+	{ .compatible = "allwinner,sun6i-a31-tcon", .data = &sun6i_a31_quirks },
+	{ .compatible = "allwinner,sun6i-a31s-tcon", .data = &sun6i_a31s_quirks },
 	{ .compatible = "allwinner,sun8i-a33-tcon", .data = &sun8i_a33_quirks },
 	{ }
 };
-- 
2.9.3

  parent reply	other threads:[~2016-10-20  3:45 UTC|newest]

Thread overview: 76+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-20  3:43 [PATCH v2 0/8] drm/sun4i: Support first display pipeline on sun6i Chen-Yu Tsai
2016-10-20  3:43 ` Chen-Yu Tsai
2016-10-20  3:43 ` Chen-Yu Tsai
2016-10-20  3:43 ` [PATCH v2 1/8] drm/bridge: rgb-to-vga: Support an enable GPIO Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 13:00   ` Maxime Ripard
2016-10-20 13:00     ` Maxime Ripard
2016-10-25  8:09   ` Archit Taneja
2016-10-25  8:09     ` Archit Taneja
2016-10-25  8:09     ` Archit Taneja
2016-10-25  8:59     ` Chen-Yu Tsai
2016-10-25  8:59       ` Chen-Yu Tsai
2016-10-25  8:59       ` Chen-Yu Tsai
2016-10-27  6:40       ` Archit Taneja
2016-10-27  6:40         ` Archit Taneja
2016-10-27  6:40         ` Archit Taneja
2016-10-27  6:52         ` Chen-Yu Tsai
2016-10-27  6:52           ` Chen-Yu Tsai
2016-10-27  6:52           ` Chen-Yu Tsai
2016-10-26 22:13   ` Rob Herring
2016-10-26 22:13     ` Rob Herring
2016-10-26 22:13     ` Rob Herring
2016-10-26 22:17     ` Maxime Ripard
2016-10-26 22:17       ` Maxime Ripard
2016-10-26 22:17       ` Maxime Ripard
2016-10-31 15:56       ` Russell King - ARM Linux
2016-10-31 15:56         ` Russell King - ARM Linux
2016-10-20  3:43 ` [PATCH v2 2/8] drm/sun4i: sun6i-drc: Support DRC on A31 and A31s Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 15:58   ` Maxime Ripard
2016-10-20 15:58     ` Maxime Ripard
2016-10-20 15:58     ` Maxime Ripard
2016-10-20  3:43 ` [PATCH v2 3/8] drm/sun4i: tcon: Move SoC specific quirks to a DT matched data structure Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 15:58   ` Maxime Ripard
2016-10-20 15:58     ` Maxime Ripard
2016-10-20 15:58     ` Maxime Ripard
2016-10-20  3:43 ` Chen-Yu Tsai [this message]
2016-10-20  3:43   ` [PATCH v2 4/8] drm/sun4i: Add compatible string for A31/A31s TCON (timing controller) Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 15:59   ` Maxime Ripard
2016-10-20 15:59     ` Maxime Ripard
2016-10-20 15:59     ` Maxime Ripard
2016-10-20  3:43 ` [PATCH v2 5/8] drm/sun4i: Add compatible strings for A31/A31s display pipelines Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 16:00   ` Maxime Ripard
2016-10-20 16:00     ` Maxime Ripard
2016-10-20 16:00     ` Maxime Ripard
2016-10-20  3:43 ` [PATCH v2 6/8] ARM: dts: sun6i: Add device nodes for first display pipeline Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 16:02   ` Maxime Ripard
2016-10-20 16:02     ` Maxime Ripard
2016-10-20 16:02     ` Maxime Ripard
2016-10-20  3:43 ` [PATCH v2 7/8] ARM: dts: sun6i: Add A31 LCD0 RGB888 pins Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 16:01   ` Maxime Ripard
2016-10-20 16:01     ` Maxime Ripard
2016-10-20 16:01     ` Maxime Ripard
2016-10-20  3:43 ` [PATCH v2 8/8] ARM: dts: sun6i: hummingbird-a31: Enable display output through VGA bridge Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20  3:43   ` Chen-Yu Tsai
2016-10-20 16:02   ` Maxime Ripard
2016-10-20 16:02     ` Maxime Ripard
2016-10-20 16:02     ` Maxime Ripard
2016-10-25  8:13   ` Archit Taneja
2016-10-25  8:13     ` Archit Taneja
2016-10-25  8:13     ` Archit Taneja
2016-10-25  8:50     ` Chen-Yu Tsai
2016-10-25  8:50       ` Chen-Yu Tsai
2016-10-25  8:50       ` Chen-Yu Tsai

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=20161020034344.14154-5-wens@csie.org \
    --to=wens@csie.org \
    --cc=airlied@linux.ie \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sunxi@googlegroups.com \
    --cc=mark.rutland@arm.com \
    --cc=maxime.ripard@free-electrons.com \
    --cc=robh+dt@kernel.org \
    /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.