Hi Mike,
I just did some refactoring to reduced thge churn and duplication. Can you check if this work for you ? I could not give it much testing.
Regards, Sudeep
--->8 Juno r1/r2 boards have different CoreSight infrastructure outside the CPU clusters. This patchset adds the additional coreSight components to separate .dtsi files to support these differences.
v1->v2: - moved the addition of the STM component into a separate patch
v2->v3: - moved the back the common coreSight components back into juno-base.dtsi
Mike Leach (2): arm64: dts: juno: fix CoreSight support for Juno r1/r2 variants arm64: dts: juno: add missing CoreSight STM component
Sudeep Holla (1): arm64: dts: juno: refactor CoreSight support on Juno r0
arch/arm64/boot/dts/arm/juno-base.dtsi | 31 ++++++--- arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 13 ++++ arch/arm64/boot/dts/arm/juno-r2.dts | 13 ++++ arch/arm64/boot/dts/arm/juno.dts | 24 +++++++ 5 files changed, 175 insertions(+), 8 deletions(-) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
-- 2.7.4
Currently the Coresight components are supported only on Juno r0 variant. In preparation to add support to Juno r1/r2 variants, this patch refactors the existing coresight device nodes so that r1/r2 support can be added easily.
Signed-off-by: Sudeep Holla sudeep.holla@arm.com --- arch/arm64/boot/dts/arm/juno-base.dtsi | 16 ++++++++-------- arch/arm64/boot/dts/arm/juno.dts | 8 ++++++++ 2 files changed, 16 insertions(+), 8 deletions(-)
diff --git a/arch/arm64/boot/dts/arm/juno-base.dtsi b/arch/arm64/boot/dts/arm/juno-base.dtsi index 7d832247d0db..6d7f56573e89 100644 --- a/arch/arm64/boot/dts/arm/juno-base.dtsi +++ b/arch/arm64/boot/dts/arm/juno-base.dtsi @@ -83,7 +83,7 @@ * The actual size is just 4K though 64K is reserved. Access to the * unmapped reserved region results in a DECERR response. */ - etf@20010000 { + etf0@20010000 { compatible = "arm,coresight-tmc", "arm,primecell"; reg = <0 0x20010000 0 0x1000>;
@@ -97,7 +97,7 @@ /* input port */ port@0 { reg = <0>; - etf_in_port: endpoint { + etf0_in_port: endpoint { slave-mode; remote-endpoint = <&main_funnel_out_port>; }; @@ -106,8 +106,7 @@ /* output port */ port@1 { reg = <0>; - etf_out_port: endpoint { - remote-endpoint = <&replicator_in_port0>; + etf0_out_port: endpoint { }; }; }; @@ -128,7 +127,8 @@ }; };
- main-funnel@20040000 { + /* This is labelled cssys0 funnel in the Juno r1/r2 TRM */ + main_funnel: main-funnel@20040000 { compatible = "arm,coresight-funnel", "arm,primecell"; reg = <0 0x20040000 0 0x1000>;
@@ -139,13 +139,15 @@ #address-cells = <1>; #size-cells = <0>;
+ /* output port */ port@0 { reg = <0>; main_funnel_out_port: endpoint { - remote-endpoint = <&etf_in_port>; + remote-endpoint = <&etf0_in_port>; }; };
+ /* input ports */ port@1 { reg = <0>; main_funnel_in_port0: endpoint { @@ -161,7 +163,6 @@ remote-endpoint = <&cluster1_funnel_out_port>; }; }; - }; };
@@ -382,7 +383,6 @@ reg = <0>; replicator_in_port0: endpoint { slave-mode; - remote-endpoint = <&etf_out_port>; }; }; }; diff --git a/arch/arm64/boot/dts/arm/juno.dts b/arch/arm64/boot/dts/arm/juno.dts index ac5ceb73f45f..ba10d688beaa 100644 --- a/arch/arm64/boot/dts/arm/juno.dts +++ b/arch/arm64/boot/dts/arm/juno.dts @@ -203,3 +203,11 @@ &etm5 { cpu = <&A53_3>; }; + +&etf0_out_port { + remote-endpoint = <&replicator_in_port0>; +}; + +&replicator_in_port0 { + remote-endpoint = <&etf0_out_port>; +};
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com --- arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@ + csys1_funnel@20130000 { + compatible = "arm,coresight-funnel", "arm,primecell"; + reg = <0 0x20130000 0 0x1000>; + + clocks = <&soc_smc50mhz>; + clock-names = "apb_pclk"; + power-domains = <&scpi_devpd 0>; + ports { + #address-cells = <1>; + #size-cells = <0>; + + /* input port */ + port@0 { + reg = <0>; + csys1_funnel_out_port: endpoint { + remote-endpoint = + <&etf1_in_port>; + }; + }; + + /* output port */ + port@1 { + reg = <0>; + csys1_funnel_in_port0: endpoint { + slave-mode; + }; + }; + + }; + }; + + etf1@20140000 { + compatible = "arm,coresight-tmc", "arm,primecell"; + reg = <0 0x20140000 0 0x1000>; + + clocks = <&soc_smc50mhz>; + clock-names = "apb_pclk"; + power-domains = <&scpi_devpd 0>; + ports { + #address-cells = <1>; + #size-cells = <0>; + + /* input port */ + port@0 { + reg = <0>; + etf1_in_port: endpoint { + slave-mode; + remote-endpoint = + <&csys1_funnel_out_port>; + }; + }; + + /* output port */ + port@1 { + reg = <0>; + etf1_out_port: endpoint { + remote-endpoint = + <&csys2_funnel_in_port1>; + }; + }; + }; + }; + + csys2_funnel@20150000 { + compatible = "arm,coresight-funnel", "arm,primecell"; + reg = <0 0x20150000 0 0x1000>; + + clocks = <&soc_smc50mhz>; + clock-names = "apb_pclk"; + power-domains = <&scpi_devpd 0>; + ports { + #address-cells = <1>; + #size-cells = <0>; + + /* output port */ + port@0 { + reg = <0>; + csys2_funnel_out_port: endpoint { + remote-endpoint = + <&replicator_in_port0>; + }; + }; + + /* input ports */ + port@1 { + reg = <0>; + csys2_funnel_in_port0: endpoint { + slave-mode; + remote-endpoint = <&etf0_out_port>; + }; + }; + + port@2 { + reg = <1>; + csys2_funnel_in_port1: endpoint { + slave-mode; + remote-endpoint = <&etf1_out_port>; + }; + }; + + }; + }; diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index eec37feee8fc..d4b85d9d343e 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi" + #include "juno-cs-r1r2.dtsi" };
&memtimer { @@ -227,3 +228,11 @@ &gpu1_thermal_zone { status = "okay"; }; + +&etf0_out_port { + remote-endpoint = <&csys2_funnel_in_port0>; +}; + +&replicator_in_port0 { + remote-endpoint = <&csys2_funnel_out_port>; +}; diff --git a/arch/arm64/boot/dts/arm/juno-r2.dts b/arch/arm64/boot/dts/arm/juno-r2.dts index 28f40ec44090..14b29517065c 100644 --- a/arch/arm64/boot/dts/arm/juno-r2.dts +++ b/arch/arm64/boot/dts/arm/juno-r2.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi" + #include "juno-cs-r1r2.dtsi" };
&memtimer { @@ -227,3 +228,11 @@ &gpu1_thermal_zone { status = "okay"; }; + +&etf0_out_port { + remote-endpoint = <&csys2_funnel_in_port0>; +}; + +&replicator_in_port0 { + remote-endpoint = <&csys2_funnel_out_port>; +};
On 12 January 2017 at 08:20, Sudeep Holla sudeep.holla@arm.com wrote:
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com
arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@
csys1_funnel@20130000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20130000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
csys1_funnel_out_port: endpoint {
remote-endpoint =
<&etf1_in_port>;
};
};
/* output port */
port@1 {
reg = <0>;
csys1_funnel_in_port0: endpoint {
slave-mode;
};
};
The comments related to the input and output port are reversed.
};
};
etf1@20140000 {
compatible = "arm,coresight-tmc", "arm,primecell";
reg = <0 0x20140000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
etf1_in_port: endpoint {
slave-mode;
remote-endpoint =
<&csys1_funnel_out_port>;
};
};
/* output port */
port@1 {
reg = <0>;
etf1_out_port: endpoint {
remote-endpoint =
<&csys2_funnel_in_port1>;
};
};
};
};
csys2_funnel@20150000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20150000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* output port */
port@0 {
reg = <0>;
csys2_funnel_out_port: endpoint {
remote-endpoint =
<&replicator_in_port0>;
};
};
/* input ports */
port@1 {
reg = <0>;
csys2_funnel_in_port0: endpoint {
slave-mode;
remote-endpoint = <&etf0_out_port>;
};
};
port@2 {
reg = <1>;
csys2_funnel_in_port1: endpoint {
slave-mode;
remote-endpoint = <&etf1_out_port>;
};
};
};
};
diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index eec37feee8fc..d4b85d9d343e 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi"
#include "juno-cs-r1r2.dtsi"
};
&memtimer { @@ -227,3 +228,11 @@ &gpu1_thermal_zone { status = "okay"; };
+&etf0_out_port {
remote-endpoint = <&csys2_funnel_in_port0>;
+};
+&replicator_in_port0 {
remote-endpoint = <&csys2_funnel_out_port>;
+}; diff --git a/arch/arm64/boot/dts/arm/juno-r2.dts b/arch/arm64/boot/dts/arm/juno-r2.dts index 28f40ec44090..14b29517065c 100644 --- a/arch/arm64/boot/dts/arm/juno-r2.dts +++ b/arch/arm64/boot/dts/arm/juno-r2.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi"
#include "juno-cs-r1r2.dtsi"
};
&memtimer { @@ -227,3 +228,11 @@ &gpu1_thermal_zone { status = "okay"; };
+&etf0_out_port {
remote-endpoint = <&csys2_funnel_in_port0>;
+};
+&replicator_in_port0 {
remote-endpoint = <&csys2_funnel_out_port>;
+};
2.7.4
CoreSight mailing list CoreSight@lists.linaro.org https://lists.linaro.org/mailman/listinfo/coresight
On 12/01/17 16:51, Mathieu Poirier wrote:
On 12 January 2017 at 08:20, Sudeep Holla sudeep.holla@arm.com wrote:
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com
arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@
csys1_funnel@20130000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20130000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
csys1_funnel_out_port: endpoint {
remote-endpoint =
<&etf1_in_port>;
};
};
/* output port */
port@1 {
reg = <0>;
csys1_funnel_in_port0: endpoint {
slave-mode;
};
};
The comments related to the input and output port are reversed.
Fixed locally.
Hi,
On Thu, Jan 12, 2017 at 7:20 AM, Sudeep Holla sudeep.holla@arm.com wrote:
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com
arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@
csys1_funnel@20130000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20130000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
csys1_funnel_out_port: endpoint {
remote-endpoint =
<&etf1_in_port>;
};
};
/* output port */
port@1 {
reg = <0>;
csys1_funnel_in_port0: endpoint {
slave-mode;
};
};
};
};
etf1@20140000 {
The concept behind device-tree is that you name the nodes based on the type of device they are. "i2c", "ethernet", etc. Not "eth0", "i2c3", and so on.
So, this should probably be something else than "etf1", and the etf->etf0 rename you did somewhere else shouldn't be made either.
csys1_funnel should probably/maybe be named something more generic as well.
compatible = "arm,coresight-tmc", "arm,primecell";
reg = <0 0x20140000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
etf1_in_port: endpoint {
slave-mode;
remote-endpoint =
<&csys1_funnel_out_port>;
};
};
/* output port */
port@1 {
reg = <0>;
etf1_out_port: endpoint {
remote-endpoint =
<&csys2_funnel_in_port1>;
};
};
};
};
csys2_funnel@20150000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20150000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* output port */
port@0 {
reg = <0>;
csys2_funnel_out_port: endpoint {
remote-endpoint =
<&replicator_in_port0>;
};
};
/* input ports */
port@1 {
reg = <0>;
csys2_funnel_in_port0: endpoint {
slave-mode;
remote-endpoint = <&etf0_out_port>;
};
};
port@2 {
reg = <1>;
csys2_funnel_in_port1: endpoint {
slave-mode;
remote-endpoint = <&etf1_out_port>;
};
};
};
};
diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index eec37feee8fc..d4b85d9d343e 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi"
#include "juno-cs-r1r2.dtsi"
Please don't nest dtsi inside a structure like this. We normally let them stand by themselves at the top of the file instead.
(yes, please fix for juno-base too).
-Olof
On 17/01/17 06:58, Olof Johansson wrote:
Hi,
On Thu, Jan 12, 2017 at 7:20 AM, Sudeep Holla sudeep.holla@arm.com wrote:
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com
arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@
csys1_funnel@20130000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20130000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
csys1_funnel_out_port: endpoint {
remote-endpoint =
<&etf1_in_port>;
};
};
/* output port */
port@1 {
reg = <0>;
csys1_funnel_in_port0: endpoint {
slave-mode;
};
};
};
};
etf1@20140000 {
The concept behind device-tree is that you name the nodes based on the type of device they are. "i2c", "ethernet", etc. Not "eth0", "i2c3", and so on.
So, this should probably be something else than "etf1", and the etf->etf0 rename you did somewhere else shouldn't be made either.
Agreed, will fix it. Sorry for not noticing that before. I somehow always confused them to be labels rather that node names and even missed to observe that when I changed for R0.
[...]
diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index eec37feee8fc..d4b85d9d343e 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi"
#include "juno-cs-r1r2.dtsi"
Please don't nest dtsi inside a structure like this. We normally let them stand by themselves at the top of the file instead.
(yes, please fix for juno-base too).
Agreed and fixed locally, will post it as part of v4.
On Tue, Jan 17, 2017 at 3:37 AM, Sudeep Holla sudeep.holla@arm.com wrote:
On 17/01/17 06:58, Olof Johansson wrote:
Hi,
On Thu, Jan 12, 2017 at 7:20 AM, Sudeep Holla sudeep.holla@arm.com wrote:
From: Mike Leach mike.leach@linaro.org
The CoreSight support added for Juno is valid for only Juno r0. The Juno r1 and r2 variants have additional components and alternative connection routes between trace source and sinks.
This patch builds on top of the existing r0 support and extends it to Juno r1/r2 variants.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the common coresight components back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com
arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 9 +++ arch/arm64/boot/dts/arm/juno-r2.dts | 9 +++ 3 files changed, 120 insertions(+) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
diff --git a/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi new file mode 100644 index 000000000000..89fcef366ff9 --- /dev/null +++ b/arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi @@ -0,0 +1,102 @@
csys1_funnel@20130000 {
compatible = "arm,coresight-funnel", "arm,primecell";
reg = <0 0x20130000 0 0x1000>;
clocks = <&soc_smc50mhz>;
clock-names = "apb_pclk";
power-domains = <&scpi_devpd 0>;
ports {
#address-cells = <1>;
#size-cells = <0>;
/* input port */
port@0 {
reg = <0>;
csys1_funnel_out_port: endpoint {
remote-endpoint =
<&etf1_in_port>;
};
};
/* output port */
port@1 {
reg = <0>;
csys1_funnel_in_port0: endpoint {
slave-mode;
};
};
};
};
etf1@20140000 {
The concept behind device-tree is that you name the nodes based on the type of device they are. "i2c", "ethernet", etc. Not "eth0", "i2c3", and so on.
So, this should probably be something else than "etf1", and the etf->etf0 rename you did somewhere else shouldn't be made either.
Agreed, will fix it. Sorry for not noticing that before. I somehow always confused them to be labels rather that node names and even missed to observe that when I changed for R0.
[...]
diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index eec37feee8fc..d4b85d9d343e 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -178,6 +178,7 @@ };
#include "juno-base.dtsi"
#include "juno-cs-r1r2.dtsi"
Please don't nest dtsi inside a structure like this. We normally let them stand by themselves at the top of the file instead.
(yes, please fix for juno-base too).
Agreed and fixed locally, will post it as part of v4.
Both look reasonable here on repost!
-Olof
From: Mike Leach mike.leach@linaro.org
This patch adds the missing CoreSight STM component definition to the device tree of all the juno variants(r0,r1,r2)
STM component is connected to different funnels depending on Juno platform variant.
Signed-off-by: Mike Leach mike.leach@linaro.org [sudeep.holla@arm.com: minor changelog update and reorganising the STM node back into juno-base.dtsi to avoid duplication] Signed-off-by: Sudeep Holla sudeep.holla@arm.com --- arch/arm64/boot/dts/arm/juno-base.dtsi | 15 +++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 4 ++++ arch/arm64/boot/dts/arm/juno-r2.dts | 4 ++++ arch/arm64/boot/dts/arm/juno.dts | 16 ++++++++++++++++ 4 files changed, 39 insertions(+)
diff --git a/arch/arm64/boot/dts/arm/juno-base.dtsi b/arch/arm64/boot/dts/arm/juno-base.dtsi index 6d7f56573e89..77fe75de5cae 100644 --- a/arch/arm64/boot/dts/arm/juno-base.dtsi +++ b/arch/arm64/boot/dts/arm/juno-base.dtsi @@ -182,6 +182,21 @@ }; };
+ stm@20100000 { + compatible = "arm,coresight-stm", "arm,primecell"; + reg = <0 0x20100000 0 0x1000>, + <0 0x28000000 0 0x180000>; + reg-names = "stm-base", "stm-stimulus-base"; + + clocks = <&soc_smc50mhz>; + clock-names = "apb_pclk"; + power-domains = <&scpi_devpd 0>; + port { + stm_out_port: endpoint { + }; + }; + }; + etm0: etm@22040000 { compatible = "arm,coresight-etm4x", "arm,primecell"; reg = <0 0x22040000 0 0x1000>; diff --git a/arch/arm64/boot/dts/arm/juno-r1.dts b/arch/arm64/boot/dts/arm/juno-r1.dts index d4b85d9d343e..6df25c7a6b90 100644 --- a/arch/arm64/boot/dts/arm/juno-r1.dts +++ b/arch/arm64/boot/dts/arm/juno-r1.dts @@ -236,3 +236,7 @@ &replicator_in_port0 { remote-endpoint = <&csys2_funnel_out_port>; }; + +&stm_out_port { + remote-endpoint = <&csys1_funnel_in_port0>; +}; diff --git a/arch/arm64/boot/dts/arm/juno-r2.dts b/arch/arm64/boot/dts/arm/juno-r2.dts index 14b29517065c..dafe92c20f65 100644 --- a/arch/arm64/boot/dts/arm/juno-r2.dts +++ b/arch/arm64/boot/dts/arm/juno-r2.dts @@ -236,3 +236,7 @@ &replicator_in_port0 { remote-endpoint = <&csys2_funnel_out_port>; }; + +&stm_out_port { + remote-endpoint = <&csys1_funnel_in_port0>; +}; diff --git a/arch/arm64/boot/dts/arm/juno.dts b/arch/arm64/boot/dts/arm/juno.dts index ba10d688beaa..dbec40a4c4a7 100644 --- a/arch/arm64/boot/dts/arm/juno.dts +++ b/arch/arm64/boot/dts/arm/juno.dts @@ -211,3 +211,19 @@ &replicator_in_port0 { remote-endpoint = <&etf0_out_port>; }; + +&stm_out_port { + remote-endpoint = <&main_funnel_in_port2>; +}; + +&main_funnel { + ports { + port@3 { + reg = <2>; + main_funnel_in_port2: endpoint { + slave-mode; + remote-endpoint = <&stm_out_port>; + }; + }; + }; +};
On 12 January 2017 at 08:20, Sudeep Holla sudeep.holla@arm.com wrote:
Hi Mike,
I just did some refactoring to reduced thge churn and duplication. Can you check if this work for you ? I could not give it much testing.
Regards, Sudeep
--->8 Juno r1/r2 boards have different CoreSight infrastructure outside the CPU clusters. This patchset adds the additional coreSight components to separate .dtsi files to support these differences.
v1->v2: - moved the addition of the STM component into a separate patch
v2->v3: - moved the back the common coreSight components back into juno-base.dtsi
Mike Leach (2): arm64: dts: juno: fix CoreSight support for Juno r1/r2 variants arm64: dts: juno: add missing CoreSight STM component
Sudeep Holla (1): arm64: dts: juno: refactor CoreSight support on Juno r0
arch/arm64/boot/dts/arm/juno-base.dtsi | 31 ++++++--- arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 13 ++++ arch/arm64/boot/dts/arm/juno-r2.dts | 13 ++++ arch/arm64/boot/dts/arm/juno.dts | 24 +++++++ 5 files changed, 175 insertions(+), 8 deletions(-) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
For the set:
Reviewed-by: Mathieu Poirier mathieu.poirier@linaro.org Tested-by: Mathieu Poirier mathieu.poirier@linaro.org (On R0 only)
-- 2.7.4
CoreSight mailing list CoreSight@lists.linaro.org https://lists.linaro.org/mailman/listinfo/coresight
On 12/01/17 17:08, Mathieu Poirier wrote:
On 12 January 2017 at 08:20, Sudeep Holla sudeep.holla@arm.com wrote:
Hi Mike,
I just did some refactoring to reduced thge churn and duplication. Can you check if this work for you ? I could not give it much testing.
Regards, Sudeep
--->8 Juno r1/r2 boards have different CoreSight infrastructure outside the CPU clusters. This patchset adds the additional coreSight components to separate .dtsi files to support these differences.
v1->v2: - moved the addition of the STM component into a separate patch
v2->v3: - moved the back the common coreSight components back into juno-base.dtsi
Mike Leach (2): arm64: dts: juno: fix CoreSight support for Juno r1/r2 variants arm64: dts: juno: add missing CoreSight STM component
Sudeep Holla (1): arm64: dts: juno: refactor CoreSight support on Juno r0
arch/arm64/boot/dts/arm/juno-base.dtsi | 31 ++++++--- arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102 ++++++++++++++++++++++++++++++ arch/arm64/boot/dts/arm/juno-r1.dts | 13 ++++ arch/arm64/boot/dts/arm/juno-r2.dts | 13 ++++ arch/arm64/boot/dts/arm/juno.dts | 24 +++++++ 5 files changed, 175 insertions(+), 8 deletions(-) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
For the set:
Reviewed-by: Mathieu Poirier mathieu.poirier@linaro.org Tested-by: Mathieu Poirier mathieu.poirier@linaro.org (On R0 only)
Thanks for reviewing and testing.
Hi Sudeep,
Patchset tested successfully on juno-r1
Mike
On 12 January 2017 at 17:19, Sudeep Holla sudeep.holla@arm.com wrote:
On 12/01/17 17:08, Mathieu Poirier wrote:
On 12 January 2017 at 08:20, Sudeep Holla sudeep.holla@arm.com wrote:
Hi Mike,
I just did some refactoring to reduced thge churn and duplication. Can you check if this work for you ? I could not give it much testing.
Regards, Sudeep
--->8 Juno r1/r2 boards have different CoreSight infrastructure outside the CPU clusters. This patchset adds the additional coreSight components to separate .dtsi files to support these differences.
v1->v2: - moved the addition of the STM component into a separate patch
v2->v3: - moved the back the common coreSight components back into juno-base.dtsi
Mike Leach (2): arm64: dts: juno: fix CoreSight support for Juno r1/r2 variants arm64: dts: juno: add missing CoreSight STM component
Sudeep Holla (1): arm64: dts: juno: refactor CoreSight support on Juno r0
arch/arm64/boot/dts/arm/juno-base.dtsi | 31 ++++++--- arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi | 102
++++++++++++++++++++++++++++++
arch/arm64/boot/dts/arm/juno-r1.dts | 13 ++++ arch/arm64/boot/dts/arm/juno-r2.dts | 13 ++++ arch/arm64/boot/dts/arm/juno.dts | 24 +++++++ 5 files changed, 175 insertions(+), 8 deletions(-) create mode 100644 arch/arm64/boot/dts/arm/juno-cs-r1r2.dtsi
For the set:
Reviewed-by: Mathieu Poirier mathieu.poirier@linaro.org Tested-by: Mathieu Poirier mathieu.poirier@linaro.org (On R0 only)
Thanks for reviewing and testing.
-- Regards, Sudeep
On 13/01/17 11:09, Mike Leach wrote:
Hi Sudeep,
Patchset tested successfully on juno-r1
Thanks and I did a quick test on Juno R2. I have pushed the branch [1] with minor comment change as pointed out my Mathieu.