Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1360543 > unrolled thread

[RFC v3 0/3] Mediatek MT8173 CMDQ support

Started byHS Liao <hs.liao@mediatek.com>
First post2016-03-18 12:30 +0100
Last post2016-03-18 12:30 +0100
Articles 5 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [RFC v3 0/3] Mediatek MT8173 CMDQ support HS Liao <hs.liao@mediatek.com> - 2016-03-18 12:30 +0100
    [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit HS Liao <hs.liao@mediatek.com> - 2016-03-18 12:30 +0100
      Re: [RFC v3 1/3] dt-bindings: soc: Add documentation for the  MediaTek GCE unit Rob Herring <robh@kernel.org> - 2016-03-20 02:00 +0100
        Re: [RFC v3 1/3] dt-bindings: soc: Add documentation for the  MediaTek GCE unit Horng-Shyang Liao <hs.liao@mediatek.com> - 2016-03-21 09:20 +0100
    [RFC v3 3/3] arm64: dts: mt8173: Add GCE node HS Liao <hs.liao@mediatek.com> - 2016-03-18 12:30 +0100

#1360543 — [RFC v3 0/3] Mediatek MT8173 CMDQ support

FromHS Liao <hs.liao@mediatek.com>
Date2016-03-18 12:30 +0100
Subject[RFC v3 0/3] Mediatek MT8173 CMDQ support
Message-ID<re0Lo-4Z2-25@gated-at.bofh.it>
Hi,

This is Mediatek MT8173 Command Queue(CMDQ) driver. The CMDQ is used
to help read/write registers with critical time limitation, such as
updating display configuration during the vblank. It controls Global
Command Engine (GCE) hardware to achieve this requirement.

These patches have a build dependency on top of v4.5-rc1.

Changes since v2:
 - use cmdq instead of cqctx
 - document cmdq_code
 - use cmdq thread base instead of thread id, so remove thread id
 - remove buffer pool and let linux manage memory
 - remove task_free_list
 - merge cmdq_task_exec_async_impl into cmdq_task_exec_async
 - use list_for_each_entry_safe instead of list_for_each_safe
 - merge cmdq_dev_init into cmdq_probe
 - use cmdq record(rec) instead of cmdq handle
 - use cmdq command instead of cmdq desc
 - remove unused interfaces
 - set IRQF_TRIGGER_LOW in device tree
 - remove event array and related code since client should clear event
   before wait it
 - report status to callback function
 - remove some debug code
 - remove some protection code, e.g. suspend/resume
 - rewrite some code to shrink code size

Best regards,
HS Liao

HS Liao (3):
  dt-bindings: soc: Add documentation for the MediaTek GCE unit
  CMDQ: Mediatek CMDQ driver
  arm64: dts: mt8173: Add GCE node

 .../devicetree/bindings/soc/mediatek/gce.txt       |   34 +
 arch/arm64/boot/dts/mediatek/mt8173.dtsi           |    8 +
 drivers/soc/mediatek/Kconfig                       |   10 +
 drivers/soc/mediatek/Makefile                      |    1 +
 drivers/soc/mediatek/mtk-cmdq.c                    | 1805 ++++++++++++++++++++
 include/soc/mediatek/cmdq.h                        |  181 ++
 6 files changed, 2039 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/soc/mediatek/gce.txt
 create mode 100644 drivers/soc/mediatek/mtk-cmdq.c
 create mode 100644 include/soc/mediatek/cmdq.h

-- 
1.7.9.5

[toc] | [next] | [standalone]


#1360545 — [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit

FromHS Liao <hs.liao@mediatek.com>
Date2016-03-18 12:30 +0100
Subject[RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit
Message-ID<re0Lp-4Z2-35@gated-at.bofh.it>
In reply to#1360543
This adds documentation for the MediaTek Global Command Engine (GCE) unit
found in MT8173 SoCs.

Signed-off-by: HS Liao <hs.liao@mediatek.com>
---
 .../devicetree/bindings/soc/mediatek/gce.txt       |   34 ++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/soc/mediatek/gce.txt

diff --git a/Documentation/devicetree/bindings/soc/mediatek/gce.txt b/Documentation/devicetree/bindings/soc/mediatek/gce.txt
new file mode 100644
index 0000000..eff07e2
--- /dev/null
+++ b/Documentation/devicetree/bindings/soc/mediatek/gce.txt
@@ -0,0 +1,34 @@
+MediaTek GCE
+===============
+
+The Global Command Engine (GCE) is used to help read/write registers with
+critical time limitation, such as updating display configuration during the
+vblank. The GCE can be used to implement the Command Queue (CMDQ) driver.
+
+Required properties:
+- compatible: Must be "mediatek,mt8173-gce"
+- reg: Address range of the GCE unit
+- interrupts: The interrupt signal from the GCE block
+- clock: Clocks according to the common clock binding
+- clock-names: Must be "gce" to stand for GCE clock
+
+Required properties for a client device:
+- mediatek,gce: Should point to the respective GCE block
+
+Example:
+
+	gce: gce@10212000 {
+		compatible = "mediatek,mt8173-gce";
+		reg = <0 0x10212000 0 0x1000>;
+		interrupts = <GIC_SPI 135 IRQ_TYPE_LEVEL_LOW>;
+		clocks = <&infracfg CLK_INFRA_GCE>;
+		clock-names = "gce";
+	};
+
+Example for a client device:
+
+	mmsys: clock-controller@14000000 {
+		compatible = "mediatek,mt8173-mmsys";
+		mediatek,gce = <&gce>;
+		...
+	};
-- 
1.7.9.5

[toc] | [prev] | [next] | [standalone]


#1361189 — Re: [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit

FromRob Herring <robh@kernel.org>
Date2016-03-20 02:00 +0100
SubjectRe: [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit
Message-ID<rezSO-7EP-9@gated-at.bofh.it>
In reply to#1360545
On Fri, Mar 18, 2016 at 07:27:12PM +0800, HS Liao wrote:
> This adds documentation for the MediaTek Global Command Engine (GCE) unit
> found in MT8173 SoCs.
> 
> Signed-off-by: HS Liao <hs.liao@mediatek.com>
> ---
>  .../devicetree/bindings/soc/mediatek/gce.txt       |   34 ++++++++++++++++++++
>  1 file changed, 34 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/soc/mediatek/gce.txt

I already acked this. Please add acks when posting subsequent versions.

Acked-by: Rob Herring <robh@kernel.org>

[toc] | [prev] | [next] | [standalone]


#1361587 — Re: [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit

FromHorng-Shyang Liao <hs.liao@mediatek.com>
Date2016-03-21 09:20 +0100
SubjectRe: [RFC v3 1/3] dt-bindings: soc: Add documentation for the MediaTek GCE unit
Message-ID<rf3ea-2Ra-17@gated-at.bofh.it>
In reply to#1361189
On Sat, 2016-03-19 at 19:58 -0500, Rob Herring wrote:
> On Fri, Mar 18, 2016 at 07:27:12PM +0800, HS Liao wrote:
> > This adds documentation for the MediaTek Global Command Engine (GCE) unit
> > found in MT8173 SoCs.
> > 
> > Signed-off-by: HS Liao <hs.liao@mediatek.com>
> > ---
> >  .../devicetree/bindings/soc/mediatek/gce.txt       |   34 ++++++++++++++++++++
> >  1 file changed, 34 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/soc/mediatek/gce.txt
> 
> I already acked this. Please add acks when posting subsequent versions.
> 
> Acked-by: Rob Herring <robh@kernel.org>


Hi Rob,

Sorry, I will add acked-by from next version.

Best regards,
HS Liao

[toc] | [prev] | [next] | [standalone]


#1360547 — [RFC v3 3/3] arm64: dts: mt8173: Add GCE node

FromHS Liao <hs.liao@mediatek.com>
Date2016-03-18 12:30 +0100
Subject[RFC v3 3/3] arm64: dts: mt8173: Add GCE node
Message-ID<re0Lp-4Z2-41@gated-at.bofh.it>
In reply to#1360543
This patch adds the device node of the GCE hardware for CMDQ module.

Signed-off-by: HS Liao <hs.liao@mediatek.com>
---
 arch/arm64/boot/dts/mediatek/mt8173.dtsi |    8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt8173.dtsi b/arch/arm64/boot/dts/mediatek/mt8173.dtsi
index ec135ea..6089095 100644
--- a/arch/arm64/boot/dts/mediatek/mt8173.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8173.dtsi
@@ -283,6 +283,14 @@
 			#clock-cells = <1>;
 		};
 
+		gce: gce@10212000 {
+			compatible = "mediatek,mt8173-gce";
+			reg = <0 0x10212000 0 0x1000>;
+			interrupts = <GIC_SPI 135 IRQ_TYPE_LEVEL_LOW>;
+			clocks = <&infracfg CLK_INFRA_GCE>;
+			clock-names = "gce";
+		};
+
 		gic: interrupt-controller@10220000 {
 			compatible = "arm,gic-400";
 			#interrupt-cells = <3>;
-- 
1.7.9.5

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web