All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-02 15:19 ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel

This series add SMP brinup support for MediaTek SoCs. This is v5 and
is based on v4.3-rc1.

There are similar but different SMP bringup up methods on MediaTek
mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
firmware. Others, like MT6589, doesn't have trustzone, and run kernel
directly in secure world.

Patch 1 enable arch timer support.
Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
"mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
and TZ platform.
Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.

Changes in v5:
- Fix dts error
- Add Rob's Ack tag.

Changes in v4[3]:
- rebase to v4.3-rc1
- Reserve trustzone bootinfo memory area in device tree.

Changes in v3:
- v3 in [1]
- The first 2 patches in v2 are merged in v4.2-rc1.
- Patch 3~4 in v2 are moved to another series [2]
- platsmp.c changes based on Stephen's suggestion
- Change cpu enable-method name to "mediatek,mt6589-smp"

Changes in v2:
- Fix boot issue for THUMB2 kernel.
- Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
- Change platsmp.c according to Matthias' suggestion
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html

v1:
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html

[1]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html

[2]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html

[3]
http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html


Matthias Brugger (1):
  ARM: mediatek: enable gpt6 on boot up to make arch timer working

Yingjoe Chen (4):
  devicetree: bindings: add new SMP enable method Mediatek SoC
  ARM: mediatek: add smp bringup code
  ARM: dts: mt8135: enable basic SMP bringup for mt8135
  ARM: dts: mt8127: enable basic SMP bringup for mt8127

 Documentation/devicetree/bindings/arm/cpus.txt |   2 +
 arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
 arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
 arch/arm/mach-mediatek/Makefile                |   3 +
 arch/arm/mach-mediatek/mediatek.c              |  27 +++++
 arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
 6 files changed, 227 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

-- 
1.9.1


^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-02 15:19 ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel

This series add SMP brinup support for MediaTek SoCs. This is v5 and
is based on v4.3-rc1.

There are similar but different SMP bringup up methods on MediaTek
mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
firmware. Others, like MT6589, doesn't have trustzone, and run kernel
directly in secure world.

Patch 1 enable arch timer support.
Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
"mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
and TZ platform.
Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.

Changes in v5:
- Fix dts error
- Add Rob's Ack tag.

Changes in v4[3]:
- rebase to v4.3-rc1
- Reserve trustzone bootinfo memory area in device tree.

Changes in v3:
- v3 in [1]
- The first 2 patches in v2 are merged in v4.2-rc1.
- Patch 3~4 in v2 are moved to another series [2]
- platsmp.c changes based on Stephen's suggestion
- Change cpu enable-method name to "mediatek,mt6589-smp"

Changes in v2:
- Fix boot issue for THUMB2 kernel.
- Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
- Change platsmp.c according to Matthias' suggestion
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html

v1:
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html

[1]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html

[2]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html

[3]
http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html


Matthias Brugger (1):
  ARM: mediatek: enable gpt6 on boot up to make arch timer working

Yingjoe Chen (4):
  devicetree: bindings: add new SMP enable method Mediatek SoC
  ARM: mediatek: add smp bringup code
  ARM: dts: mt8135: enable basic SMP bringup for mt8135
  ARM: dts: mt8127: enable basic SMP bringup for mt8127

 Documentation/devicetree/bindings/arm/cpus.txt |   2 +
 arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
 arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
 arch/arm/mach-mediatek/Makefile                |   3 +
 arch/arm/mach-mediatek/mediatek.c              |  27 +++++
 arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
 6 files changed, 227 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

-- 
1.9.1

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-02 15:19 ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

This series add SMP brinup support for MediaTek SoCs. This is v5 and
is based on v4.3-rc1.

There are similar but different SMP bringup up methods on MediaTek
mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
firmware. Others, like MT6589, doesn't have trustzone, and run kernel
directly in secure world.

Patch 1 enable arch timer support.
Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
"mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
and TZ platform.
Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.

Changes in v5:
- Fix dts error
- Add Rob's Ack tag.

Changes in v4[3]:
- rebase to v4.3-rc1
- Reserve trustzone bootinfo memory area in device tree.

Changes in v3:
- v3 in [1]
- The first 2 patches in v2 are merged in v4.2-rc1.
- Patch 3~4 in v2 are moved to another series [2]
- platsmp.c changes based on Stephen's suggestion
- Change cpu enable-method name to "mediatek,mt6589-smp"

Changes in v2:
- Fix boot issue for THUMB2 kernel.
- Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
- Change platsmp.c according to Matthias' suggestion
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html

v1:
http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html

[1]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html

[2]
http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html

[3]
http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html


Matthias Brugger (1):
  ARM: mediatek: enable gpt6 on boot up to make arch timer working

Yingjoe Chen (4):
  devicetree: bindings: add new SMP enable method Mediatek SoC
  ARM: mediatek: add smp bringup code
  ARM: dts: mt8135: enable basic SMP bringup for mt8135
  ARM: dts: mt8127: enable basic SMP bringup for mt8127

 Documentation/devicetree/bindings/arm/cpus.txt |   2 +
 arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
 arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
 arch/arm/mach-mediatek/Makefile                |   3 +
 arch/arm/mach-mediatek/mediatek.c              |  27 +++++
 arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
 6 files changed, 227 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

-- 
1.9.1

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 1/5] ARM: mediatek: enable gpt6 on boot up to make arch timer working
  2015-10-02 15:19 ` Yingjoe Chen
  (?)
@ 2015-10-02 15:19   ` Yingjoe Chen
  -1 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

From: Matthias Brugger <matthias.bgg@gmail.com>

We enable GTP6 which ungates the arch timer clock.
In the future this should be done in the bootloader.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/mediatek.c | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/mach-mediatek/mediatek.c b/arch/arm/mach-mediatek/mediatek.c
index a954900..19dc738 100644
--- a/arch/arm/mach-mediatek/mediatek.c
+++ b/arch/arm/mach-mediatek/mediatek.c
@@ -16,6 +16,32 @@
  */
 #include <linux/init.h>
 #include <asm/mach/arch.h>
+#include <linux/of.h>
+#include <linux/clk-provider.h>
+#include <linux/clocksource.h>
+
+
+#define GPT6_CON_MT65xx 0x10008060
+#define GPT_ENABLE      0x31
+
+static void __init mediatek_timer_init(void)
+{
+	void __iomem *gpt_base;
+
+	if (of_machine_is_compatible("mediatek,mt6589") ||
+	    of_machine_is_compatible("mediatek,mt8135") ||
+	    of_machine_is_compatible("mediatek,mt8127")) {
+		/* turn on GPT6 which ungates arch timer clocks */
+		gpt_base = ioremap(GPT6_CON_MT65xx, 0x04);
+
+		/* enable clock and set to free-run */
+		writel(GPT_ENABLE, gpt_base);
+		iounmap(gpt_base);
+	}
+
+	of_clk_init(NULL);
+	clocksource_of_init();
+};
 
 static const char * const mediatek_board_dt_compat[] = {
 	"mediatek,mt6589",
@@ -27,4 +53,5 @@ static const char * const mediatek_board_dt_compat[] = {
 
 DT_MACHINE_START(MEDIATEK_DT, "Mediatek Cortex-A7 (Device Tree)")
 	.dt_compat	= mediatek_board_dt_compat,
+	.init_time	= mediatek_timer_init,
 MACHINE_END
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 1/5] ARM: mediatek: enable gpt6 on boot up to make arch timer working
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

From: Matthias Brugger <matthias.bgg@gmail.com>

We enable GTP6 which ungates the arch timer clock.
In the future this should be done in the bootloader.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/mediatek.c | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/mach-mediatek/mediatek.c b/arch/arm/mach-mediatek/mediatek.c
index a954900..19dc738 100644
--- a/arch/arm/mach-mediatek/mediatek.c
+++ b/arch/arm/mach-mediatek/mediatek.c
@@ -16,6 +16,32 @@
  */
 #include <linux/init.h>
 #include <asm/mach/arch.h>
+#include <linux/of.h>
+#include <linux/clk-provider.h>
+#include <linux/clocksource.h>
+
+
+#define GPT6_CON_MT65xx 0x10008060
+#define GPT_ENABLE      0x31
+
+static void __init mediatek_timer_init(void)
+{
+	void __iomem *gpt_base;
+
+	if (of_machine_is_compatible("mediatek,mt6589") ||
+	    of_machine_is_compatible("mediatek,mt8135") ||
+	    of_machine_is_compatible("mediatek,mt8127")) {
+		/* turn on GPT6 which ungates arch timer clocks */
+		gpt_base = ioremap(GPT6_CON_MT65xx, 0x04);
+
+		/* enable clock and set to free-run */
+		writel(GPT_ENABLE, gpt_base);
+		iounmap(gpt_base);
+	}
+
+	of_clk_init(NULL);
+	clocksource_of_init();
+};
 
 static const char * const mediatek_board_dt_compat[] = {
 	"mediatek,mt6589",
@@ -27,4 +53,5 @@ static const char * const mediatek_board_dt_compat[] = {
 
 DT_MACHINE_START(MEDIATEK_DT, "Mediatek Cortex-A7 (Device Tree)")
 	.dt_compat	= mediatek_board_dt_compat,
+	.init_time	= mediatek_timer_init,
 MACHINE_END
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 1/5] ARM: mediatek: enable gpt6 on boot up to make arch timer working
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

From: Matthias Brugger <matthias.bgg@gmail.com>

We enable GTP6 which ungates the arch timer clock.
In the future this should be done in the bootloader.

Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/mediatek.c | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/mach-mediatek/mediatek.c b/arch/arm/mach-mediatek/mediatek.c
index a954900..19dc738 100644
--- a/arch/arm/mach-mediatek/mediatek.c
+++ b/arch/arm/mach-mediatek/mediatek.c
@@ -16,6 +16,32 @@
  */
 #include <linux/init.h>
 #include <asm/mach/arch.h>
+#include <linux/of.h>
+#include <linux/clk-provider.h>
+#include <linux/clocksource.h>
+
+
+#define GPT6_CON_MT65xx 0x10008060
+#define GPT_ENABLE      0x31
+
+static void __init mediatek_timer_init(void)
+{
+	void __iomem *gpt_base;
+
+	if (of_machine_is_compatible("mediatek,mt6589") ||
+	    of_machine_is_compatible("mediatek,mt8135") ||
+	    of_machine_is_compatible("mediatek,mt8127")) {
+		/* turn on GPT6 which ungates arch timer clocks */
+		gpt_base = ioremap(GPT6_CON_MT65xx, 0x04);
+
+		/* enable clock and set to free-run */
+		writel(GPT_ENABLE, gpt_base);
+		iounmap(gpt_base);
+	}
+
+	of_clk_init(NULL);
+	clocksource_of_init();
+};
 
 static const char * const mediatek_board_dt_compat[] = {
 	"mediatek,mt6589",
@@ -27,4 +53,5 @@ static const char * const mediatek_board_dt_compat[] = {
 
 DT_MACHINE_START(MEDIATEK_DT, "Mediatek Cortex-A7 (Device Tree)")
 	.dt_compat	= mediatek_board_dt_compat,
+	.init_time	= mediatek_timer_init,
 MACHINE_END
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 2/5] devicetree: bindings: add new SMP enable method Mediatek SoC
  2015-10-02 15:19 ` Yingjoe Chen
  (?)
@ 2015-10-02 15:19   ` Yingjoe Chen
  -1 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

This commit add new cpu enable method "mediatek,mt65xx-smp" and
"mediatek,mt81xx-tz-smp".

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 Documentation/devicetree/bindings/arm/cpus.txt | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/cpus.txt b/Documentation/devicetree/bindings/arm/cpus.txt
index 91e6e5c..3a07a87 100644
--- a/Documentation/devicetree/bindings/arm/cpus.txt
+++ b/Documentation/devicetree/bindings/arm/cpus.txt
@@ -195,6 +195,8 @@ nodes to be present and contain the properties described below.
 			    "marvell,armada-380-smp"
 			    "marvell,armada-390-smp"
 			    "marvell,armada-xp-smp"
+			    "mediatek,mt6589-smp"
+			    "mediatek,mt81xx-tz-smp"
 			    "qcom,gcc-msm8660"
 			    "qcom,kpss-acc-v1"
 			    "qcom,kpss-acc-v2"
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 2/5] devicetree: bindings: add new SMP enable method Mediatek SoC
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

This commit add new cpu enable method "mediatek,mt65xx-smp" and
"mediatek,mt81xx-tz-smp".

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 Documentation/devicetree/bindings/arm/cpus.txt | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/cpus.txt b/Documentation/devicetree/bindings/arm/cpus.txt
index 91e6e5c..3a07a87 100644
--- a/Documentation/devicetree/bindings/arm/cpus.txt
+++ b/Documentation/devicetree/bindings/arm/cpus.txt
@@ -195,6 +195,8 @@ nodes to be present and contain the properties described below.
 			    "marvell,armada-380-smp"
 			    "marvell,armada-390-smp"
 			    "marvell,armada-xp-smp"
+			    "mediatek,mt6589-smp"
+			    "mediatek,mt81xx-tz-smp"
 			    "qcom,gcc-msm8660"
 			    "qcom,kpss-acc-v1"
 			    "qcom,kpss-acc-v2"
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 2/5] devicetree: bindings: add new SMP enable method Mediatek SoC
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

This commit add new cpu enable method "mediatek,mt65xx-smp" and
"mediatek,mt81xx-tz-smp".

Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 Documentation/devicetree/bindings/arm/cpus.txt | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/cpus.txt b/Documentation/devicetree/bindings/arm/cpus.txt
index 91e6e5c..3a07a87 100644
--- a/Documentation/devicetree/bindings/arm/cpus.txt
+++ b/Documentation/devicetree/bindings/arm/cpus.txt
@@ -195,6 +195,8 @@ nodes to be present and contain the properties described below.
 			    "marvell,armada-380-smp"
 			    "marvell,armada-390-smp"
 			    "marvell,armada-xp-smp"
+			    "mediatek,mt6589-smp"
+			    "mediatek,mt81xx-tz-smp"
 			    "qcom,gcc-msm8660"
 			    "qcom,kpss-acc-v1"
 			    "qcom,kpss-acc-v2"
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 3/5] ARM: mediatek: add smp bringup code
  2015-10-02 15:19 ` Yingjoe Chen
  (?)
@ 2015-10-02 15:19   ` Yingjoe Chen
  -1 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

Add support for booting secondary CPUs on mt6589, mt8127
and mt8135.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/Makefile  |   3 +
 arch/arm/mach-mediatek/platsmp.c | 141 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 144 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

diff --git a/arch/arm/mach-mediatek/Makefile b/arch/arm/mach-mediatek/Makefile
index 43e619f..2116460 100644
--- a/arch/arm/mach-mediatek/Makefile
+++ b/arch/arm/mach-mediatek/Makefile
@@ -1 +1,4 @@
+ifeq ($(CONFIG_SMP),y)
+obj-$(CONFIG_ARCH_MEDIATEK) += platsmp.o
+endif
 obj-$(CONFIG_ARCH_MEDIATEK) += mediatek.o
diff --git a/arch/arm/mach-mediatek/platsmp.c b/arch/arm/mach-mediatek/platsmp.c
new file mode 100644
index 0000000..8141f3f
--- /dev/null
+++ b/arch/arm/mach-mediatek/platsmp.c
@@ -0,0 +1,141 @@
+/*
+ * arch/arm/mach-mediatek/platsmp.c
+ *
+ * Copyright (c) 2014 Mediatek Inc.
+ * Author: Shunli Wang <shunli.wang@mediatek.com>
+ *         Yingjoe Chen <yingjoe.chen@mediatek.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ */
+#include <linux/io.h>
+#include <linux/memblock.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
+#include <linux/string.h>
+#include <linux/threads.h>
+
+#define MTK_MAX_CPU		8
+#define MTK_SMP_REG_SIZE	0x1000
+
+struct mtk_smp_boot_info {
+	unsigned long smp_base;
+	unsigned int jump_reg;
+	unsigned int core_keys[MTK_MAX_CPU - 1];
+	unsigned int core_regs[MTK_MAX_CPU - 1];
+};
+
+static const struct mtk_smp_boot_info mtk_mt8135_tz_boot = {
+	0x80002000, 0x3fc,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x3f8, 0x3f8, 0x3f8 },
+};
+
+static const struct mtk_smp_boot_info mtk_mt6589_boot = {
+	0x10002000, 0x34,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x38, 0x3c, 0x40 },
+};
+
+static const struct of_device_id mtk_tz_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt8135", .data = &mtk_mt8135_tz_boot },
+	{ .compatible   = "mediatek,mt8127", .data = &mtk_mt8135_tz_boot },
+};
+
+static const struct of_device_id mtk_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt6589", .data = &mtk_mt6589_boot },
+};
+
+static void __iomem *mtk_smp_base;
+static const struct mtk_smp_boot_info *mtk_smp_info;
+
+static int mtk_boot_secondary(unsigned int cpu, struct task_struct *idle)
+{
+	if (!mtk_smp_base)
+		return -EINVAL;
+
+	if (!mtk_smp_info->core_keys[cpu-1])
+		return -EINVAL;
+
+	writel_relaxed(mtk_smp_info->core_keys[cpu-1],
+		mtk_smp_base + mtk_smp_info->core_regs[cpu-1]);
+
+	arch_send_wakeup_ipi_mask(cpumask_of(cpu));
+
+	return 0;
+}
+
+static void __init __mtk_smp_prepare_cpus(unsigned int max_cpus, int trustzone)
+{
+	int i, num;
+	const struct of_device_id *infos;
+
+	if (trustzone) {
+		num = ARRAY_SIZE(mtk_tz_smp_boot_infos);
+		infos = mtk_tz_smp_boot_infos;
+	} else {
+		num = ARRAY_SIZE(mtk_smp_boot_infos);
+		infos = mtk_smp_boot_infos;
+	}
+
+	/* Find smp boot info for this SoC */
+	for (i = 0; i < num; i++) {
+		if (of_machine_is_compatible(infos[i].compatible)) {
+			mtk_smp_info = infos[i].data;
+			break;
+		}
+	}
+
+	if (!mtk_smp_info) {
+		pr_err("%s: Device is not supported\n", __func__);
+		return;
+	}
+
+	if (trustzone) {
+		/* smp_base(trustzone-bootinfo) is reserved by device tree */
+		mtk_smp_base = phys_to_virt(mtk_smp_info->smp_base);
+	} else {
+		mtk_smp_base = ioremap(mtk_smp_info->smp_base, MTK_SMP_REG_SIZE);
+		if (!mtk_smp_base) {
+			pr_err("%s: Can't remap %lx\n", __func__,
+				mtk_smp_info->smp_base);
+			return;
+		}
+	}
+
+	/*
+	 * write the address of slave startup address into the system-wide
+	 * jump register
+	 */
+	writel_relaxed(virt_to_phys(secondary_startup_arm),
+			mtk_smp_base + mtk_smp_info->jump_reg);
+}
+
+static void __init mtk_tz_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 1);
+}
+
+static void __init mtk_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 0);
+}
+
+static struct smp_operations mt81xx_tz_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_tz_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt81xx_tz_smp, "mediatek,mt81xx-tz-smp", &mt81xx_tz_smp_ops);
+
+static struct smp_operations mt6589_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt6589_smp, "mediatek,mt6589-smp", &mt6589_smp_ops);
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 3/5] ARM: mediatek: add smp bringup code
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

Add support for booting secondary CPUs on mt6589, mt8127
and mt8135.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/Makefile  |   3 +
 arch/arm/mach-mediatek/platsmp.c | 141 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 144 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

diff --git a/arch/arm/mach-mediatek/Makefile b/arch/arm/mach-mediatek/Makefile
index 43e619f..2116460 100644
--- a/arch/arm/mach-mediatek/Makefile
+++ b/arch/arm/mach-mediatek/Makefile
@@ -1 +1,4 @@
+ifeq ($(CONFIG_SMP),y)
+obj-$(CONFIG_ARCH_MEDIATEK) += platsmp.o
+endif
 obj-$(CONFIG_ARCH_MEDIATEK) += mediatek.o
diff --git a/arch/arm/mach-mediatek/platsmp.c b/arch/arm/mach-mediatek/platsmp.c
new file mode 100644
index 0000000..8141f3f
--- /dev/null
+++ b/arch/arm/mach-mediatek/platsmp.c
@@ -0,0 +1,141 @@
+/*
+ * arch/arm/mach-mediatek/platsmp.c
+ *
+ * Copyright (c) 2014 Mediatek Inc.
+ * Author: Shunli Wang <shunli.wang@mediatek.com>
+ *         Yingjoe Chen <yingjoe.chen@mediatek.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ */
+#include <linux/io.h>
+#include <linux/memblock.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
+#include <linux/string.h>
+#include <linux/threads.h>
+
+#define MTK_MAX_CPU		8
+#define MTK_SMP_REG_SIZE	0x1000
+
+struct mtk_smp_boot_info {
+	unsigned long smp_base;
+	unsigned int jump_reg;
+	unsigned int core_keys[MTK_MAX_CPU - 1];
+	unsigned int core_regs[MTK_MAX_CPU - 1];
+};
+
+static const struct mtk_smp_boot_info mtk_mt8135_tz_boot = {
+	0x80002000, 0x3fc,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x3f8, 0x3f8, 0x3f8 },
+};
+
+static const struct mtk_smp_boot_info mtk_mt6589_boot = {
+	0x10002000, 0x34,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x38, 0x3c, 0x40 },
+};
+
+static const struct of_device_id mtk_tz_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt8135", .data = &mtk_mt8135_tz_boot },
+	{ .compatible   = "mediatek,mt8127", .data = &mtk_mt8135_tz_boot },
+};
+
+static const struct of_device_id mtk_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt6589", .data = &mtk_mt6589_boot },
+};
+
+static void __iomem *mtk_smp_base;
+static const struct mtk_smp_boot_info *mtk_smp_info;
+
+static int mtk_boot_secondary(unsigned int cpu, struct task_struct *idle)
+{
+	if (!mtk_smp_base)
+		return -EINVAL;
+
+	if (!mtk_smp_info->core_keys[cpu-1])
+		return -EINVAL;
+
+	writel_relaxed(mtk_smp_info->core_keys[cpu-1],
+		mtk_smp_base + mtk_smp_info->core_regs[cpu-1]);
+
+	arch_send_wakeup_ipi_mask(cpumask_of(cpu));
+
+	return 0;
+}
+
+static void __init __mtk_smp_prepare_cpus(unsigned int max_cpus, int trustzone)
+{
+	int i, num;
+	const struct of_device_id *infos;
+
+	if (trustzone) {
+		num = ARRAY_SIZE(mtk_tz_smp_boot_infos);
+		infos = mtk_tz_smp_boot_infos;
+	} else {
+		num = ARRAY_SIZE(mtk_smp_boot_infos);
+		infos = mtk_smp_boot_infos;
+	}
+
+	/* Find smp boot info for this SoC */
+	for (i = 0; i < num; i++) {
+		if (of_machine_is_compatible(infos[i].compatible)) {
+			mtk_smp_info = infos[i].data;
+			break;
+		}
+	}
+
+	if (!mtk_smp_info) {
+		pr_err("%s: Device is not supported\n", __func__);
+		return;
+	}
+
+	if (trustzone) {
+		/* smp_base(trustzone-bootinfo) is reserved by device tree */
+		mtk_smp_base = phys_to_virt(mtk_smp_info->smp_base);
+	} else {
+		mtk_smp_base = ioremap(mtk_smp_info->smp_base, MTK_SMP_REG_SIZE);
+		if (!mtk_smp_base) {
+			pr_err("%s: Can't remap %lx\n", __func__,
+				mtk_smp_info->smp_base);
+			return;
+		}
+	}
+
+	/*
+	 * write the address of slave startup address into the system-wide
+	 * jump register
+	 */
+	writel_relaxed(virt_to_phys(secondary_startup_arm),
+			mtk_smp_base + mtk_smp_info->jump_reg);
+}
+
+static void __init mtk_tz_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 1);
+}
+
+static void __init mtk_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 0);
+}
+
+static struct smp_operations mt81xx_tz_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_tz_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt81xx_tz_smp, "mediatek,mt81xx-tz-smp", &mt81xx_tz_smp_ops);
+
+static struct smp_operations mt6589_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt6589_smp, "mediatek,mt6589-smp", &mt6589_smp_ops);
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 3/5] ARM: mediatek: add smp bringup code
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

Add support for booting secondary CPUs on mt6589, mt8127
and mt8135.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/mach-mediatek/Makefile  |   3 +
 arch/arm/mach-mediatek/platsmp.c | 141 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 144 insertions(+)
 create mode 100644 arch/arm/mach-mediatek/platsmp.c

diff --git a/arch/arm/mach-mediatek/Makefile b/arch/arm/mach-mediatek/Makefile
index 43e619f..2116460 100644
--- a/arch/arm/mach-mediatek/Makefile
+++ b/arch/arm/mach-mediatek/Makefile
@@ -1 +1,4 @@
+ifeq ($(CONFIG_SMP),y)
+obj-$(CONFIG_ARCH_MEDIATEK) += platsmp.o
+endif
 obj-$(CONFIG_ARCH_MEDIATEK) += mediatek.o
diff --git a/arch/arm/mach-mediatek/platsmp.c b/arch/arm/mach-mediatek/platsmp.c
new file mode 100644
index 0000000..8141f3f
--- /dev/null
+++ b/arch/arm/mach-mediatek/platsmp.c
@@ -0,0 +1,141 @@
+/*
+ * arch/arm/mach-mediatek/platsmp.c
+ *
+ * Copyright (c) 2014 Mediatek Inc.
+ * Author: Shunli Wang <shunli.wang@mediatek.com>
+ *         Yingjoe Chen <yingjoe.chen@mediatek.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ */
+#include <linux/io.h>
+#include <linux/memblock.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
+#include <linux/string.h>
+#include <linux/threads.h>
+
+#define MTK_MAX_CPU		8
+#define MTK_SMP_REG_SIZE	0x1000
+
+struct mtk_smp_boot_info {
+	unsigned long smp_base;
+	unsigned int jump_reg;
+	unsigned int core_keys[MTK_MAX_CPU - 1];
+	unsigned int core_regs[MTK_MAX_CPU - 1];
+};
+
+static const struct mtk_smp_boot_info mtk_mt8135_tz_boot = {
+	0x80002000, 0x3fc,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x3f8, 0x3f8, 0x3f8 },
+};
+
+static const struct mtk_smp_boot_info mtk_mt6589_boot = {
+	0x10002000, 0x34,
+	{ 0x534c4131, 0x4c415332, 0x41534c33 },
+	{ 0x38, 0x3c, 0x40 },
+};
+
+static const struct of_device_id mtk_tz_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt8135", .data = &mtk_mt8135_tz_boot },
+	{ .compatible   = "mediatek,mt8127", .data = &mtk_mt8135_tz_boot },
+};
+
+static const struct of_device_id mtk_smp_boot_infos[] __initconst = {
+	{ .compatible   = "mediatek,mt6589", .data = &mtk_mt6589_boot },
+};
+
+static void __iomem *mtk_smp_base;
+static const struct mtk_smp_boot_info *mtk_smp_info;
+
+static int mtk_boot_secondary(unsigned int cpu, struct task_struct *idle)
+{
+	if (!mtk_smp_base)
+		return -EINVAL;
+
+	if (!mtk_smp_info->core_keys[cpu-1])
+		return -EINVAL;
+
+	writel_relaxed(mtk_smp_info->core_keys[cpu-1],
+		mtk_smp_base + mtk_smp_info->core_regs[cpu-1]);
+
+	arch_send_wakeup_ipi_mask(cpumask_of(cpu));
+
+	return 0;
+}
+
+static void __init __mtk_smp_prepare_cpus(unsigned int max_cpus, int trustzone)
+{
+	int i, num;
+	const struct of_device_id *infos;
+
+	if (trustzone) {
+		num = ARRAY_SIZE(mtk_tz_smp_boot_infos);
+		infos = mtk_tz_smp_boot_infos;
+	} else {
+		num = ARRAY_SIZE(mtk_smp_boot_infos);
+		infos = mtk_smp_boot_infos;
+	}
+
+	/* Find smp boot info for this SoC */
+	for (i = 0; i < num; i++) {
+		if (of_machine_is_compatible(infos[i].compatible)) {
+			mtk_smp_info = infos[i].data;
+			break;
+		}
+	}
+
+	if (!mtk_smp_info) {
+		pr_err("%s: Device is not supported\n", __func__);
+		return;
+	}
+
+	if (trustzone) {
+		/* smp_base(trustzone-bootinfo) is reserved by device tree */
+		mtk_smp_base = phys_to_virt(mtk_smp_info->smp_base);
+	} else {
+		mtk_smp_base = ioremap(mtk_smp_info->smp_base, MTK_SMP_REG_SIZE);
+		if (!mtk_smp_base) {
+			pr_err("%s: Can't remap %lx\n", __func__,
+				mtk_smp_info->smp_base);
+			return;
+		}
+	}
+
+	/*
+	 * write the address of slave startup address into the system-wide
+	 * jump register
+	 */
+	writel_relaxed(virt_to_phys(secondary_startup_arm),
+			mtk_smp_base + mtk_smp_info->jump_reg);
+}
+
+static void __init mtk_tz_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 1);
+}
+
+static void __init mtk_smp_prepare_cpus(unsigned int max_cpus)
+{
+	__mtk_smp_prepare_cpus(max_cpus, 0);
+}
+
+static struct smp_operations mt81xx_tz_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_tz_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt81xx_tz_smp, "mediatek,mt81xx-tz-smp", &mt81xx_tz_smp_ops);
+
+static struct smp_operations mt6589_smp_ops __initdata = {
+	.smp_prepare_cpus = mtk_smp_prepare_cpus,
+	.smp_boot_secondary = mtk_boot_secondary,
+};
+CPU_METHOD_OF_DECLARE(mt6589_smp, "mediatek,mt6589-smp", &mt6589_smp_ops);
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-02 15:19 ` Yingjoe Chen
  (?)
@ 2015-10-02 15:19   ` Yingjoe Chen
  -1 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

Add arch timer node to enable arch-timer support. MT8135 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/boot/dts/mt8135.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8135.dtsi b/arch/arm/boot/dts/mt8135.dtsi
index 08371db..cb99b02 100644
--- a/arch/arm/boot/dts/mt8135.dtsi
+++ b/arch/arm/boot/dts/mt8135.dtsi
@@ -46,6 +46,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu0: cpu@0 {
 			device_type = "cpu";
@@ -72,6 +73,17 @@
 		};
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo@80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -97,6 +109,21 @@
 		};
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

Add arch timer node to enable arch-timer support. MT8135 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/boot/dts/mt8135.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8135.dtsi b/arch/arm/boot/dts/mt8135.dtsi
index 08371db..cb99b02 100644
--- a/arch/arm/boot/dts/mt8135.dtsi
+++ b/arch/arm/boot/dts/mt8135.dtsi
@@ -46,6 +46,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu0: cpu@0 {
 			device_type = "cpu";
@@ -72,6 +73,17 @@
 		};
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo@80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -97,6 +109,21 @@
 		};
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

Add arch timer node to enable arch-timer support. MT8135 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/boot/dts/mt8135.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8135.dtsi b/arch/arm/boot/dts/mt8135.dtsi
index 08371db..cb99b02 100644
--- a/arch/arm/boot/dts/mt8135.dtsi
+++ b/arch/arm/boot/dts/mt8135.dtsi
@@ -46,6 +46,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu0: cpu at 0 {
 			device_type = "cpu";
@@ -72,6 +73,17 @@
 		};
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo at 80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -97,6 +109,21 @@
 		};
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 5/5] ARM: dts: mt8127: enable basic SMP bringup for mt8127
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel, Yingjoe Chen

Add arch timer node to enable arch-timer support. MT8127 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/boot/dts/mt8127.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8127.dtsi b/arch/arm/boot/dts/mt8127.dtsi
index ca3402e..52086c8 100644
--- a/arch/arm/boot/dts/mt8127.dtsi
+++ b/arch/arm/boot/dts/mt8127.dtsi
@@ -23,6 +23,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu@0 {
 			device_type = "cpu";
@@ -47,6 +48,17 @@
 
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo@80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -72,6 +84,21 @@
                 };
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 5/5] ARM: dts: mt8127: enable basic SMP bringup for mt8127
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: Russell King - ARM Linux, Matthias Brugger
  Cc: devicetree-u79uwXL29TY76Z2rM5mHXA,
	srv_heupstream-NuS5LvNUpcJWk0Htik3J/w, Arnd Bergmann,
	Stephen Boyd, linux-kernel-u79uwXL29TY76Z2rM5mHXA, Rob Herring,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Sascha Hauer,
	Olof Johansson,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Yingjoe Chen

Add arch timer node to enable arch-timer support. MT8127 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
---
 arch/arm/boot/dts/mt8127.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8127.dtsi b/arch/arm/boot/dts/mt8127.dtsi
index ca3402e..52086c8 100644
--- a/arch/arm/boot/dts/mt8127.dtsi
+++ b/arch/arm/boot/dts/mt8127.dtsi
@@ -23,6 +23,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu@0 {
 			device_type = "cpu";
@@ -47,6 +48,17 @@
 
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo@80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -72,6 +84,21 @@
                 };
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
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

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* [PATCH v5 5/5] ARM: dts: mt8127: enable basic SMP bringup for mt8127
@ 2015-10-02 15:19   ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-02 15:19 UTC (permalink / raw)
  To: linux-arm-kernel

Add arch timer node to enable arch-timer support. MT8127 firmware
doesn't correctly setup arch-timer frequency and CNTVOFF, add
properties to workaround this.

This also set cpu enable-method to enable SMP.

Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
---
 arch/arm/boot/dts/mt8127.dtsi | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/arch/arm/boot/dts/mt8127.dtsi b/arch/arm/boot/dts/mt8127.dtsi
index ca3402e..52086c8 100644
--- a/arch/arm/boot/dts/mt8127.dtsi
+++ b/arch/arm/boot/dts/mt8127.dtsi
@@ -23,6 +23,7 @@
 	cpus {
 		#address-cells = <1>;
 		#size-cells = <0>;
+		enable-method = "mediatek,mt81xx-tz-smp";
 
 		cpu at 0 {
 			device_type = "cpu";
@@ -47,6 +48,17 @@
 
 	};
 
+	reserved-memory {
+		#address-cells = <2>;
+		#size-cells = <2>;
+		ranges;
+
+		trustzone-bootinfo at 80002000 {
+			compatible = "mediatek,trustzone-bootinfo";
+			reg = <0 0x80002000 0 0x1000>;
+		};
+	};
+
 	clocks {
 		#address-cells = <2>;
 		#size-cells = <2>;
@@ -72,6 +84,21 @@
                 };
 	};
 
+	timer {
+		compatible = "arm,armv7-timer";
+		interrupt-parent = <&gic>;
+		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>,
+			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) |
+					  IRQ_TYPE_LEVEL_LOW)>;
+		clock-frequency = <13000000>;
+		arm,cpu-registers-not-fw-configured;
+	};
+
 	soc {
 		#address-cells = <2>;
 		#size-cells = <2>;
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-12 17:30   ` Matthias Brugger
  0 siblings, 0 replies; 66+ messages in thread
From: Matthias Brugger @ 2015-10-12 17:30 UTC (permalink / raw)
  To: Yingjoe Chen, Russell King - ARM Linux
  Cc: devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd,
	linux-kernel, Rob Herring, linux-mediatek, Sascha Hauer,
	Olof Johansson, linux-arm-kernel



On 02/10/15 17:19, Yingjoe Chen wrote:
> This series add SMP brinup support for MediaTek SoCs. This is v5 and
> is based on v4.3-rc1.
>
> There are similar but different SMP bringup up methods on MediaTek
> mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
> firmware. Others, like MT6589, doesn't have trustzone, and run kernel
> directly in secure world.
>
> Patch 1 enable arch timer support.
> Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
> "mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
> and TZ platform.
> Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.
>
> Changes in v5:
> - Fix dts error
> - Add Rob's Ack tag.
>
> Changes in v4[3]:
> - rebase to v4.3-rc1
> - Reserve trustzone bootinfo memory area in device tree.
>
> Changes in v3:
> - v3 in [1]
> - The first 2 patches in v2 are merged in v4.2-rc1.
> - Patch 3~4 in v2 are moved to another series [2]
> - platsmp.c changes based on Stephen's suggestion
> - Change cpu enable-method name to "mediatek,mt6589-smp"
>
> Changes in v2:
> - Fix boot issue for THUMB2 kernel.
> - Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
> - Change platsmp.c according to Matthias' suggestion
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html
>
> v1:
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html
>
> [1]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html
>
> [2]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html
>
> [3]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html
>
>
> Matthias Brugger (1):
>    ARM: mediatek: enable gpt6 on boot up to make arch timer working
>
> Yingjoe Chen (4):
>    devicetree: bindings: add new SMP enable method Mediatek SoC
>    ARM: mediatek: add smp bringup code
>    ARM: dts: mt8135: enable basic SMP bringup for mt8135
>    ARM: dts: mt8127: enable basic SMP bringup for mt8127
>
>   Documentation/devicetree/bindings/arm/cpus.txt |   2 +
>   arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
>   arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
>   arch/arm/mach-mediatek/Makefile                |   3 +
>   arch/arm/mach-mediatek/mediatek.c              |  27 +++++
>   arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
>   6 files changed, 227 insertions(+)
>   create mode 100644 arch/arm/mach-mediatek/platsmp.c
>

Applied, thanks.

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-12 17:30   ` Matthias Brugger
  0 siblings, 0 replies; 66+ messages in thread
From: Matthias Brugger @ 2015-10-12 17:30 UTC (permalink / raw)
  To: Yingjoe Chen, Russell King - ARM Linux
  Cc: devicetree-u79uwXL29TY76Z2rM5mHXA,
	srv_heupstream-NuS5LvNUpcJWk0Htik3J/w, Arnd Bergmann,
	Stephen Boyd, linux-kernel-u79uwXL29TY76Z2rM5mHXA, Rob Herring,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Sascha Hauer,
	Olof Johansson,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r



On 02/10/15 17:19, Yingjoe Chen wrote:
> This series add SMP brinup support for MediaTek SoCs. This is v5 and
> is based on v4.3-rc1.
>
> There are similar but different SMP bringup up methods on MediaTek
> mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
> firmware. Others, like MT6589, doesn't have trustzone, and run kernel
> directly in secure world.
>
> Patch 1 enable arch timer support.
> Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
> "mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
> and TZ platform.
> Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.
>
> Changes in v5:
> - Fix dts error
> - Add Rob's Ack tag.
>
> Changes in v4[3]:
> - rebase to v4.3-rc1
> - Reserve trustzone bootinfo memory area in device tree.
>
> Changes in v3:
> - v3 in [1]
> - The first 2 patches in v2 are merged in v4.2-rc1.
> - Patch 3~4 in v2 are moved to another series [2]
> - platsmp.c changes based on Stephen's suggestion
> - Change cpu enable-method name to "mediatek,mt6589-smp"
>
> Changes in v2:
> - Fix boot issue for THUMB2 kernel.
> - Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
> - Change platsmp.c according to Matthias' suggestion
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html
>
> v1:
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html
>
> [1]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html
>
> [2]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html
>
> [3]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html
>
>
> Matthias Brugger (1):
>    ARM: mediatek: enable gpt6 on boot up to make arch timer working
>
> Yingjoe Chen (4):
>    devicetree: bindings: add new SMP enable method Mediatek SoC
>    ARM: mediatek: add smp bringup code
>    ARM: dts: mt8135: enable basic SMP bringup for mt8135
>    ARM: dts: mt8127: enable basic SMP bringup for mt8127
>
>   Documentation/devicetree/bindings/arm/cpus.txt |   2 +
>   arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
>   arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
>   arch/arm/mach-mediatek/Makefile                |   3 +
>   arch/arm/mach-mediatek/mediatek.c              |  27 +++++
>   arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
>   6 files changed, 227 insertions(+)
>   create mode 100644 arch/arm/mach-mediatek/platsmp.c
>

Applied, thanks.
--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 0/5] Add SMP bringup support for mt65xx socs
@ 2015-10-12 17:30   ` Matthias Brugger
  0 siblings, 0 replies; 66+ messages in thread
From: Matthias Brugger @ 2015-10-12 17:30 UTC (permalink / raw)
  To: linux-arm-kernel



On 02/10/15 17:19, Yingjoe Chen wrote:
> This series add SMP brinup support for MediaTek SoCs. This is v5 and
> is based on v4.3-rc1.
>
> There are similar but different SMP bringup up methods on MediaTek
> mt65xx and mt81xx. On MT8135 & MT8127, system boots with a trustzone
> firmware. Others, like MT6589, doesn't have trustzone, and run kernel
> directly in secure world.
>
> Patch 1 enable arch timer support.
> Patch 2,3 add support for cpu enable-method "mediatek,mt6589-smp" and
> "mediatek,mt81xx-tz-smp", which support Mediatek SMP bringup for non-TZ
> and TZ platform.
> Patch 4,5 finally enable SMP bringup for mt8135 and mt8127.
>
> Changes in v5:
> - Fix dts error
> - Add Rob's Ack tag.
>
> Changes in v4[3]:
> - rebase to v4.3-rc1
> - Reserve trustzone bootinfo memory area in device tree.
>
> Changes in v3:
> - v3 in [1]
> - The first 2 patches in v2 are merged in v4.2-rc1.
> - Patch 3~4 in v2 are moved to another series [2]
> - platsmp.c changes based on Stephen's suggestion
> - Change cpu enable-method name to "mediatek,mt6589-smp"
>
> Changes in v2:
> - Fix boot issue for THUMB2 kernel.
> - Not enable GPT_CLK_EVT when setup to fix GPT spurious interrupt issue
> - Change platsmp.c according to Matthias' suggestion
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000714.html
>
> v1:
> http://lists.infradead.org/pipermail/linux-mediatek/2015-May/000528.html
>
> [1]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001570.html
>
> [2]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-July/001544.html
>
> [3]
> http://lists.infradead.org/pipermail/linux-mediatek/2015-September/002377.html
>
>
> Matthias Brugger (1):
>    ARM: mediatek: enable gpt6 on boot up to make arch timer working
>
> Yingjoe Chen (4):
>    devicetree: bindings: add new SMP enable method Mediatek SoC
>    ARM: mediatek: add smp bringup code
>    ARM: dts: mt8135: enable basic SMP bringup for mt8135
>    ARM: dts: mt8127: enable basic SMP bringup for mt8127
>
>   Documentation/devicetree/bindings/arm/cpus.txt |   2 +
>   arch/arm/boot/dts/mt8127.dtsi                  |  27 +++++
>   arch/arm/boot/dts/mt8135.dtsi                  |  27 +++++
>   arch/arm/mach-mediatek/Makefile                |   3 +
>   arch/arm/mach-mediatek/mediatek.c              |  27 +++++
>   arch/arm/mach-mediatek/platsmp.c               | 141 +++++++++++++++++++++++++
>   6 files changed, 227 insertions(+)
>   create mode 100644 arch/arm/mach-mediatek/platsmp.c
>

Applied, thanks.

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-02 15:19   ` Yingjoe Chen
  (?)
@ 2015-10-26  0:56     ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  0:56 UTC (permalink / raw)
  To: Yingjoe Chen
  Cc: Russell King - ARM Linux, Matthias Brugger, devicetree,
	srv_heupstream, Arnd Bergmann, Stephen Boyd, lkml, Rob Herring,
	linux-mediatek, Sascha Hauer, Olof Johansson, linux-arm-kernel,
	Tyler Baker

Hello,

On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> Add arch timer node to enable arch-timer support. MT8135 firmware
> doesn't correctly setup arch-timer frequency and CNTVOFF, add
> properties to workaround this.
>
> This also set cpu enable-method to enable SMP.
>
> Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>

kernelci.org started detecting new boot failures for the mt8135-evb in
the arm-soc tree[1], and the boot failures were bisected down to this
patch, which landed upstream in the form of commit d186a394bb98 (ARM:
dts: mt8135: enable basic SMP bringup for mt8135)

Maybe this new SMP support requires updating the firmware on the board
as well?  If so, the changelog should've been a bit more explicit
about firmware dependencies.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/arm-soc/kernel/v4.3-rc5-795-ga4b616012d2e/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=562b1cf959b5149e07111471

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  0:56     ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  0:56 UTC (permalink / raw)
  To: Yingjoe Chen
  Cc: Russell King - ARM Linux, Matthias Brugger, devicetree,
	srv_heupstream, Arnd Bergmann, Stephen Boyd, lkml, Rob Herring,
	linux-mediatek, Sascha Hauer, Olof Johansson, linux-arm-kernel,
	Tyler Baker

Hello,

On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> Add arch timer node to enable arch-timer support. MT8135 firmware
> doesn't correctly setup arch-timer frequency and CNTVOFF, add
> properties to workaround this.
>
> This also set cpu enable-method to enable SMP.
>
> Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>

kernelci.org started detecting new boot failures for the mt8135-evb in
the arm-soc tree[1], and the boot failures were bisected down to this
patch, which landed upstream in the form of commit d186a394bb98 (ARM:
dts: mt8135: enable basic SMP bringup for mt8135)

Maybe this new SMP support requires updating the firmware on the board
as well?  If so, the changelog should've been a bit more explicit
about firmware dependencies.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/arm-soc/kernel/v4.3-rc5-795-ga4b616012d2e/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=562b1cf959b5149e07111471

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  0:56     ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  0:56 UTC (permalink / raw)
  To: linux-arm-kernel

Hello,

On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> Add arch timer node to enable arch-timer support. MT8135 firmware
> doesn't correctly setup arch-timer frequency and CNTVOFF, add
> properties to workaround this.
>
> This also set cpu enable-method to enable SMP.
>
> Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>

kernelci.org started detecting new boot failures for the mt8135-evb in
the arm-soc tree[1], and the boot failures were bisected down to this
patch, which landed upstream in the form of commit d186a394bb98 (ARM:
dts: mt8135: enable basic SMP bringup for mt8135)

Maybe this new SMP support requires updating the firmware on the board
as well?  If so, the changelog should've been a bit more explicit
about firmware dependencies.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/arm-soc/kernel/v4.3-rc5-795-ga4b616012d2e/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=562b1cf959b5149e07111471

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  7:15       ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-26  7:15 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Russell King - ARM Linux, Matthias Brugger, devicetree,
	srv_heupstream, Arnd Bergmann, Stephen Boyd, lkml, Rob Herring,
	linux-mediatek, Sascha Hauer, Olof Johansson, linux-arm-kernel,
	Tyler Baker

On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> Hello,
> 
> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> > Add arch timer node to enable arch-timer support. MT8135 firmware
> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> > properties to workaround this.
> >
> > This also set cpu enable-method to enable SMP.
> >
> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> 
> kernelci.org started detecting new boot failures for the mt8135-evb in
> the arm-soc tree[1], and the boot failures were bisected down to this
> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> dts: mt8135: enable basic SMP bringup for mt8135)
> 
> Maybe this new SMP support requires updating the firmware on the board
> as well?  If so, the changelog should've been a bit more explicit
> about firmware dependencies.

Kevin,

Thanks for testing.

No, it doesn't need new firmware. Will test to see what's going wrong.


Joe.C



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  7:15       ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-26  7:15 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Russell King - ARM Linux, Matthias Brugger,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	srv_heupstream-NuS5LvNUpcJWk0Htik3J/w, Arnd Bergmann,
	Stephen Boyd, lkml, Rob Herring,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Sascha Hauer,
	Olof Johansson,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Tyler Baker

On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> Hello,
> 
> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> > Add arch timer node to enable arch-timer support. MT8135 firmware
> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> > properties to workaround this.
> >
> > This also set cpu enable-method to enable SMP.
> >
> > Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> 
> kernelci.org started detecting new boot failures for the mt8135-evb in
> the arm-soc tree[1], and the boot failures were bisected down to this
> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> dts: mt8135: enable basic SMP bringup for mt8135)
> 
> Maybe this new SMP support requires updating the firmware on the board
> as well?  If so, the changelog should've been a bit more explicit
> about firmware dependencies.

Kevin,

Thanks for testing.

No, it doesn't need new firmware. Will test to see what's going wrong.


Joe.C


--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  7:15       ` Yingjoe Chen
  0 siblings, 0 replies; 66+ messages in thread
From: Yingjoe Chen @ 2015-10-26  7:15 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> Hello,
> 
> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> > Add arch timer node to enable arch-timer support. MT8135 firmware
> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> > properties to workaround this.
> >
> > This also set cpu enable-method to enable SMP.
> >
> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> 
> kernelci.org started detecting new boot failures for the mt8135-evb in
> the arm-soc tree[1], and the boot failures were bisected down to this
> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> dts: mt8135: enable basic SMP bringup for mt8135)
> 
> Maybe this new SMP support requires updating the firmware on the board
> as well?  If so, the changelog should've been a bit more explicit
> about firmware dependencies.

Kevin,

Thanks for testing.

No, it doesn't need new firmware. Will test to see what's going wrong.


Joe.C

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-26  7:15       ` Yingjoe Chen
  (?)
@ 2015-10-26  8:06         ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  8:06 UTC (permalink / raw)
  To: Yingjoe Chen
  Cc: Kevin Hilman, Russell King - ARM Linux, Matthias Brugger,
	devicetree, srv_heupstream, Arnd Bergmann, Stephen Boyd, lkml,
	Rob Herring, linux-mediatek, Sascha Hauer, Olof Johansson,
	linux-arm-kernel, Tyler Baker

On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> Hello,
>>
>> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> > properties to workaround this.
>> >
>> > This also set cpu enable-method to enable SMP.
>> >
>> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>>
>> kernelci.org started detecting new boot failures for the mt8135-evb in
>> the arm-soc tree[1], and the boot failures were bisected down to this
>> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> dts: mt8135: enable basic SMP bringup for mt8135)
>>
>> Maybe this new SMP support requires updating the firmware on the board
>> as well?  If so, the changelog should've been a bit more explicit
>> about firmware dependencies.
>
> Kevin,
>
> Thanks for testing.
>
> No, it doesn't need new firmware. Will test to see what's going wrong.

Thanks for following up.  I'll be glad to test any patches if you have
anything you'd like me to test.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  8:06         ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  8:06 UTC (permalink / raw)
  To: Yingjoe Chen
  Cc: Kevin Hilman, Russell King - ARM Linux, Matthias Brugger,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	srv_heupstream-NuS5LvNUpcJWk0Htik3J/w, Arnd Bergmann,
	Stephen Boyd, lkml, Rob Herring,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Sascha Hauer,
	Olof Johansson,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Tyler Baker

On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> Hello,
>>
>> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
>> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> > properties to workaround this.
>> >
>> > This also set cpu enable-method to enable SMP.
>> >
>> > Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
>>
>> kernelci.org started detecting new boot failures for the mt8135-evb in
>> the arm-soc tree[1], and the boot failures were bisected down to this
>> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> dts: mt8135: enable basic SMP bringup for mt8135)
>>
>> Maybe this new SMP support requires updating the firmware on the board
>> as well?  If so, the changelog should've been a bit more explicit
>> about firmware dependencies.
>
> Kevin,
>
> Thanks for testing.
>
> No, it doesn't need new firmware. Will test to see what's going wrong.

Thanks for following up.  I'll be glad to test any patches if you have
anything you'd like me to test.

Kevin
--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26  8:06         ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-26  8:06 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> Hello,
>>
>> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> > properties to workaround this.
>> >
>> > This also set cpu enable-method to enable SMP.
>> >
>> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>>
>> kernelci.org started detecting new boot failures for the mt8135-evb in
>> the arm-soc tree[1], and the boot failures were bisected down to this
>> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> dts: mt8135: enable basic SMP bringup for mt8135)
>>
>> Maybe this new SMP support requires updating the firmware on the board
>> as well?  If so, the changelog should've been a bit more explicit
>> about firmware dependencies.
>
> Kevin,
>
> Thanks for testing.
>
> No, it doesn't need new firmware. Will test to see what's going wrong.

Thanks for following up.  I'll be glad to test any patches if you have
anything you'd like me to test.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-26  8:06         ` Kevin Hilman
  (?)
@ 2015-10-26 11:40           ` Eddie Huang
  -1 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-26 11:40 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Kevin,

On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> Hello,
> >>
> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> > properties to workaround this.
> >> >
> >> > This also set cpu enable-method to enable SMP.
> >> >
> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >>
> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >>
> >> Maybe this new SMP support requires updating the firmware on the board
> >> as well?  If so, the changelog should've been a bit more explicit
> >> about firmware dependencies.
> >
> > Kevin,
> >
> > Thanks for testing.
> >
> > No, it doesn't need new firmware. Will test to see what's going wrong.
> 
> Thanks for following up.  I'll be glad to test any patches if you have
> anything you'd like me to test.

You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
crash" (https://lkml.org/lkml/2015/8/24/803)

Daniel Lezcano already applied this patch in his tree for 4.4.
(https://git.linaro.org/people/daniel.lezcano/linux.git)

Eddie
Thanks



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26 11:40           ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-26 11:40 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Kevin,

On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> Hello,
> >>
> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> > properties to workaround this.
> >> >
> >> > This also set cpu enable-method to enable SMP.
> >> >
> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >>
> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >>
> >> Maybe this new SMP support requires updating the firmware on the board
> >> as well?  If so, the changelog should've been a bit more explicit
> >> about firmware dependencies.
> >
> > Kevin,
> >
> > Thanks for testing.
> >
> > No, it doesn't need new firmware. Will test to see what's going wrong.
> 
> Thanks for following up.  I'll be glad to test any patches if you have
> anything you'd like me to test.

You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
crash" (https://lkml.org/lkml/2015/8/24/803)

Daniel Lezcano already applied this patch in his tree for 4.4.
(https://git.linaro.org/people/daniel.lezcano/linux.git)

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-26 11:40           ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-26 11:40 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Kevin,

On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> Hello,
> >>
> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> > properties to workaround this.
> >> >
> >> > This also set cpu enable-method to enable SMP.
> >> >
> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >>
> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >>
> >> Maybe this new SMP support requires updating the firmware on the board
> >> as well?  If so, the changelog should've been a bit more explicit
> >> about firmware dependencies.
> >
> > Kevin,
> >
> > Thanks for testing.
> >
> > No, it doesn't need new firmware. Will test to see what's going wrong.
> 
> Thanks for following up.  I'll be glad to test any patches if you have
> anything you'd like me to test.

You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
crash" (https://lkml.org/lkml/2015/8/24/803)

Daniel Lezcano already applied this patch in his tree for 4.4.
(https://git.linaro.org/people/daniel.lezcano/linux.git)

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-26 11:40           ` Eddie Huang
  (?)
@ 2015-10-29  9:12             ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-29  9:12 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Eddie Huang <eddie.huang@mediatek.com> writes:

> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>> 
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)
>

Thanks for letting us know.

In the future, these kinds of cross-tree dependencies are important to
mention in the cover letter of  the pull request so we can setup
dependency branches and keep arm-soc/for-next building and booting.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-29  9:12             ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-29  9:12 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree@vger.kernel.org,
	Russell King - ARM Linux, srv_heupstream-NuS5LvNUpcJWk0Htik3J/w,
	Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml, Olof Johansson,
	Rob Herring, linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Sascha Hauer, Matthias Brugger,
	linux-arm-kernel@lists.infradead.org

Eddie Huang <eddie.huang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> writes:

> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>> 
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)
>

Thanks for letting us know.

In the future, these kinds of cross-tree dependencies are important to
mention in the cover letter of  the pull request so we can setup
dependency branches and keep arm-soc/for-next building and booting.

Kevin
--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-29  9:12             ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-10-29  9:12 UTC (permalink / raw)
  To: linux-arm-kernel

Eddie Huang <eddie.huang@mediatek.com> writes:

> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>> 
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)
>

Thanks for letting us know.

In the future, these kinds of cross-tree dependencies are important to
mention in the cover letter of  the pull request so we can setup
dependency branches and keep arm-soc/for-next building and booting.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-29 12:03               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-29 12:03 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

On Thu, 2015-10-29 at 02:12 -0700, Kevin Hilman wrote:
> Eddie Huang <eddie.huang@mediatek.com> writes:
> 
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >> 
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> >
> 
> Thanks for letting us know.
> 
> In the future, these kinds of cross-tree dependencies are important to
> mention in the cover letter of  the pull request so we can setup
> dependency branches and keep arm-soc/for-next building and booting.
> 
sorry, we will be more careful in the future

Eddie
Thanks



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-29 12:03               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-29 12:03 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree-u79uwXL29TY76Z2rM5mHXA,
	Russell King - ARM Linux, srv_heupstream-NuS5LvNUpcJWk0Htik3J/w,
	Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml, Olof Johansson,
	Rob Herring, linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Sascha Hauer, Matthias Brugger,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

On Thu, 2015-10-29 at 02:12 -0700, Kevin Hilman wrote:
> Eddie Huang <eddie.huang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> writes:
> 
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >> 
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> >
> 
> Thanks for letting us know.
> 
> In the future, these kinds of cross-tree dependencies are important to
> mention in the cover letter of  the pull request so we can setup
> dependency branches and keep arm-soc/for-next building and booting.
> 
sorry, we will be more careful in the future

Eddie
Thanks


--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-10-29 12:03               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-10-29 12:03 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, 2015-10-29 at 02:12 -0700, Kevin Hilman wrote:
> Eddie Huang <eddie.huang@mediatek.com> writes:
> 
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >> 
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> >
> 
> Thanks for letting us know.
> 
> In the future, these kinds of cross-tree dependencies are important to
> mention in the cover letter of  the pull request so we can setup
> dependency branches and keep arm-soc/for-next building and booting.
> 
sorry, we will be more careful in the future

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-10-26 11:40           ` Eddie Huang
  (?)
@ 2015-11-09 17:59             ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-09 17:59 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Kevin Hilman, Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang@mediatek.com> wrote:
> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>>
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)

The mt8135-evp board is still failing to boot in linux-next[1] (and
has been since next-20151022.)  It appears the dependencies are not
quite correct in linux-next either.

Kevin

[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-09 17:59             ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-09 17:59 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Kevin Hilman, Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang@mediatek.com> wrote:
> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>>
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)

The mt8135-evp board is still failing to boot in linux-next[1] (and
has been since next-20151022.)  It appears the dependencies are not
quite correct in linux-next either.

Kevin

[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-09 17:59             ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-09 17:59 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang@mediatek.com> wrote:
> Hi Kevin,
>
> On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
>> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
>> >> Hello,
>> >>
>> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
>> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
>> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
>> >> > properties to workaround this.
>> >> >
>> >> > This also set cpu enable-method to enable SMP.
>> >> >
>> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
>> >>
>> >> kernelci.org started detecting new boot failures for the mt8135-evb in
>> >> the arm-soc tree[1], and the boot failures were bisected down to this
>> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
>> >> dts: mt8135: enable basic SMP bringup for mt8135)
>> >>
>> >> Maybe this new SMP support requires updating the firmware on the board
>> >> as well?  If so, the changelog should've been a bit more explicit
>> >> about firmware dependencies.
>> >
>> > Kevin,
>> >
>> > Thanks for testing.
>> >
>> > No, it doesn't need new firmware. Will test to see what's going wrong.
>>
>> Thanks for following up.  I'll be glad to test any patches if you have
>> anything you'd like me to test.
>
> You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> crash" (https://lkml.org/lkml/2015/8/24/803)
>
> Daniel Lezcano already applied this patch in his tree for 4.4.
> (https://git.linaro.org/people/daniel.lezcano/linux.git)

The mt8135-evp board is still failing to boot in linux-next[1] (and
has been since next-20151022.)  It appears the dependencies are not
quite correct in linux-next either.

Kevin

[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-10  6:11               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-10  6:11 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

On Mon, 2015-11-09 at 09:59 -0800, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang@mediatek.com> wrote:
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >>
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> 
> The mt8135-evp board is still failing to boot in linux-next[1] (and
> has been since next-20151022.)  It appears the dependencies are not
> quite correct in linux-next either.
> 
> Kevin
> 
> [1]
> http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

Hi Kevin,

I check the log [0], it seems first time mt8135-evbp1 boot to kernel
shell successfully, then boot again. In the second time, mt8135 stay in
fastboot mode, waiting host send boot image, then timeout.

I download zImage and dtb in [1], and kernel run to shell successfully
on my platform.

I don't know whether this issue caused by test environment or not.

[0]
http://storage.kernelci.org/next/next-20151109/arm-multi_v7_defconfig/lab-khilman/boot-mt8135-evbp1.txt
[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909#bisect-content




^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-10  6:11               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-10  6:11 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree-u79uwXL29TY76Z2rM5mHXA,
	Russell King - ARM Linux, srv_heupstream-NuS5LvNUpcJWk0Htik3J/w,
	Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml, Olof Johansson,
	Rob Herring, linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Sascha Hauer, Matthias Brugger,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

On Mon, 2015-11-09 at 09:59 -0800, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >>
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> 
> The mt8135-evp board is still failing to boot in linux-next[1] (and
> has been since next-20151022.)  It appears the dependencies are not
> quite correct in linux-next either.
> 
> Kevin
> 
> [1]
> http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

Hi Kevin,

I check the log [0], it seems first time mt8135-evbp1 boot to kernel
shell successfully, then boot again. In the second time, mt8135 stay in
fastboot mode, waiting host send boot image, then timeout.

I download zImage and dtb in [1], and kernel run to shell successfully
on my platform.

I don't know whether this issue caused by test environment or not.

[0]
http://storage.kernelci.org/next/next-20151109/arm-multi_v7_defconfig/lab-khilman/boot-mt8135-evbp1.txt
[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909#bisect-content



--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-10  6:11               ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-10  6:11 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, 2015-11-09 at 09:59 -0800, Kevin Hilman wrote:
> On Mon, Oct 26, 2015 at 4:40 AM, Eddie Huang <eddie.huang@mediatek.com> wrote:
> > Hi Kevin,
> >
> > On Mon, 2015-10-26 at 17:06 +0900, Kevin Hilman wrote:
> >> On Mon, Oct 26, 2015 at 4:15 PM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> > On Mon, 2015-10-26 at 09:56 +0900, Kevin Hilman wrote:
> >> >> Hello,
> >> >>
> >> >> On Sat, Oct 3, 2015 at 12:19 AM, Yingjoe Chen <yingjoe.chen@mediatek.com> wrote:
> >> >> > Add arch timer node to enable arch-timer support. MT8135 firmware
> >> >> > doesn't correctly setup arch-timer frequency and CNTVOFF, add
> >> >> > properties to workaround this.
> >> >> >
> >> >> > This also set cpu enable-method to enable SMP.
> >> >> >
> >> >> > Signed-off-by: Yingjoe Chen <yingjoe.chen@mediatek.com>
> >> >>
> >> >> kernelci.org started detecting new boot failures for the mt8135-evb in
> >> >> the arm-soc tree[1], and the boot failures were bisected down to this
> >> >> patch, which landed upstream in the form of commit d186a394bb98 (ARM:
> >> >> dts: mt8135: enable basic SMP bringup for mt8135)
> >> >>
> >> >> Maybe this new SMP support requires updating the firmware on the board
> >> >> as well?  If so, the changelog should've been a bit more explicit
> >> >> about firmware dependencies.
> >> >
> >> > Kevin,
> >> >
> >> > Thanks for testing.
> >> >
> >> > No, it doesn't need new firmware. Will test to see what's going wrong.
> >>
> >> Thanks for following up.  I'll be glad to test any patches if you have
> >> anything you'd like me to test.
> >
> > You need "clockevents/drivers/mtk: Fix spurious interrupt leading to
> > crash" (https://lkml.org/lkml/2015/8/24/803)
> >
> > Daniel Lezcano already applied this patch in his tree for 4.4.
> > (https://git.linaro.org/people/daniel.lezcano/linux.git)
> 
> The mt8135-evp board is still failing to boot in linux-next[1] (and
> has been since next-20151022.)  It appears the dependencies are not
> quite correct in linux-next either.
> 
> Kevin
> 
> [1]
> http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909

Hi Kevin,

I check the log [0], it seems first time mt8135-evbp1 boot to kernel
shell successfully, then boot again. In the second time, mt8135 stay in
fastboot mode, waiting host send boot image, then timeout.

I download zImage and dtb in [1], and kernel run to shell successfully
on my platform.

I don't know whether this issue caused by test environment or not.

[0]
http://storage.kernelci.org/next/next-20151109/arm-multi_v7_defconfig/lab-khilman/boot-mt8135-evbp1.txt
[1]
http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151109/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=564037fe59b514b2f6091909#bisect-content

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-10  6:11               ` Eddie Huang
  (?)
@ 2015-11-11  1:16                 ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11  1:16 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Eddie,

[...]

> I check the log [0],

Thanks for checking into this boot failure.

> it seems first time mt8135-evbp1 boot to kernel
> shell successfully, then boot again. In the second time, mt8135 stay in
> fastboot mode, waiting host send boot image, then timeout.

Actually, it never gets to a shell the first time.  If you look closely,
the target reboots as soon as userspace starts.   Look for the PYBOOT
line which says "finished booting, starting userspace"

Later on, pyboot thinks it finds a root shell due to finding '#'
characters, but clearly it never got to a shell.

> I download zImage and dtb in [1], and kernel run to shell successfully
> on my platform.

Are you can you try using a ramdisk as well?  You can use the pre-built
one here:
http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz

Please check my boot logs to see how I'm generating the boot.img file
(search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
that the kernel image size with a ramdisk is breaking some of the
assumptions in the fastboot mode.  I've seen problems like this on other
platforms due to hard-coded sizes/addresses in the boot firmware.

> I don't know whether this issue caused by test environment or not.

I do not think it is the test environment, since as you can see from
[1], it's booting just fine with mainline kernel, and was working fine
until next-20151102.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151110/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=5642652759b5149878091908

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11  1:16                 ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11  1:16 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Eddie,

[...]

> I check the log [0],

Thanks for checking into this boot failure.

> it seems first time mt8135-evbp1 boot to kernel
> shell successfully, then boot again. In the second time, mt8135 stay in
> fastboot mode, waiting host send boot image, then timeout.

Actually, it never gets to a shell the first time.  If you look closely,
the target reboots as soon as userspace starts.   Look for the PYBOOT
line which says "finished booting, starting userspace"

Later on, pyboot thinks it finds a root shell due to finding '#'
characters, but clearly it never got to a shell.

> I download zImage and dtb in [1], and kernel run to shell successfully
> on my platform.

Are you can you try using a ramdisk as well?  You can use the pre-built
one here:
http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz

Please check my boot logs to see how I'm generating the boot.img file
(search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
that the kernel image size with a ramdisk is breaking some of the
assumptions in the fastboot mode.  I've seen problems like this on other
platforms due to hard-coded sizes/addresses in the boot firmware.

> I don't know whether this issue caused by test environment or not.

I do not think it is the test environment, since as you can see from
[1], it's booting just fine with mainline kernel, and was working fine
until next-20151102.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151110/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=5642652759b5149878091908

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11  1:16                 ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11  1:16 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Eddie,

[...]

> I check the log [0],

Thanks for checking into this boot failure.

> it seems first time mt8135-evbp1 boot to kernel
> shell successfully, then boot again. In the second time, mt8135 stay in
> fastboot mode, waiting host send boot image, then timeout.

Actually, it never gets to a shell the first time.  If you look closely,
the target reboots as soon as userspace starts.   Look for the PYBOOT
line which says "finished booting, starting userspace"

Later on, pyboot thinks it finds a root shell due to finding '#'
characters, but clearly it never got to a shell.

> I download zImage and dtb in [1], and kernel run to shell successfully
> on my platform.

Are you can you try using a ramdisk as well?  You can use the pre-built
one here:
http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz

Please check my boot logs to see how I'm generating the boot.img file
(search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
that the kernel image size with a ramdisk is breaking some of the
assumptions in the fastboot mode.  I've seen problems like this on other
platforms due to hard-coded sizes/addresses in the boot firmware.

> I don't know whether this issue caused by test environment or not.

I do not think it is the test environment, since as you can see from
[1], it's booting just fine with mainline kernel, and was working fine
until next-20151102.

Kevin

[1] http://kernelci.org/boot/mt8135-evbp1/job/next/kernel/next-20151110/defconfig/multi_v7_defconfig/lab/lab-khilman/?_id=5642652759b5149878091908

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-11  1:16                 ` Kevin Hilman
  (?)
@ 2015-11-11  7:55                   ` Eddie Huang
  -1 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-11  7:55 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Kevin,

On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> [...]
> 
> > I check the log [0],
> 
> Thanks for checking into this boot failure.
> 
> > it seems first time mt8135-evbp1 boot to kernel
> > shell successfully, then boot again. In the second time, mt8135 stay in
> > fastboot mode, waiting host send boot image, then timeout.
> 
> Actually, it never gets to a shell the first time.  If you look closely,
> the target reboots as soon as userspace starts.   Look for the PYBOOT
> line which says "finished booting, starting userspace"
> 
> Later on, pyboot thinks it finds a root shell due to finding '#'
> characters, but clearly it never got to a shell.
> 
> > I download zImage and dtb in [1], and kernel run to shell successfully
> > on my platform.
> 
> Are you can you try using a ramdisk as well?  You can use the pre-built
> one here:
> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> 

Yes, I tried this ramdisk, and I can reproduce fail issue.

> Please check my boot logs to see how I'm generating the boot.img file
> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> that the kernel image size with a ramdisk is breaking some of the
> assumptions in the fastboot mode.  I've seen problems like this on other
> platforms due to hard-coded sizes/addresses in the boot firmware.
> 

MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
thus cause user space fail. I will prepare new firmware that extend BOOT
partition to 16MB. and put new firmware on Howard's github. I will mail
to you when I am ready..

Eddie
Thanks



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11  7:55                   ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-11  7:55 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Kevin,

On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> [...]
> 
> > I check the log [0],
> 
> Thanks for checking into this boot failure.
> 
> > it seems first time mt8135-evbp1 boot to kernel
> > shell successfully, then boot again. In the second time, mt8135 stay in
> > fastboot mode, waiting host send boot image, then timeout.
> 
> Actually, it never gets to a shell the first time.  If you look closely,
> the target reboots as soon as userspace starts.   Look for the PYBOOT
> line which says "finished booting, starting userspace"
> 
> Later on, pyboot thinks it finds a root shell due to finding '#'
> characters, but clearly it never got to a shell.
> 
> > I download zImage and dtb in [1], and kernel run to shell successfully
> > on my platform.
> 
> Are you can you try using a ramdisk as well?  You can use the pre-built
> one here:
> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> 

Yes, I tried this ramdisk, and I can reproduce fail issue.

> Please check my boot logs to see how I'm generating the boot.img file
> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> that the kernel image size with a ramdisk is breaking some of the
> assumptions in the fastboot mode.  I've seen problems like this on other
> platforms due to hard-coded sizes/addresses in the boot firmware.
> 

MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
thus cause user space fail. I will prepare new firmware that extend BOOT
partition to 16MB. and put new firmware on Howard's github. I will mail
to you when I am ready..

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11  7:55                   ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-11  7:55 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Kevin,

On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> [...]
> 
> > I check the log [0],
> 
> Thanks for checking into this boot failure.
> 
> > it seems first time mt8135-evbp1 boot to kernel
> > shell successfully, then boot again. In the second time, mt8135 stay in
> > fastboot mode, waiting host send boot image, then timeout.
> 
> Actually, it never gets to a shell the first time.  If you look closely,
> the target reboots as soon as userspace starts.   Look for the PYBOOT
> line which says "finished booting, starting userspace"
> 
> Later on, pyboot thinks it finds a root shell due to finding '#'
> characters, but clearly it never got to a shell.
> 
> > I download zImage and dtb in [1], and kernel run to shell successfully
> > on my platform.
> 
> Are you can you try using a ramdisk as well?  You can use the pre-built
> one here:
> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> 

Yes, I tried this ramdisk, and I can reproduce fail issue.

> Please check my boot logs to see how I'm generating the boot.img file
> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> that the kernel image size with a ramdisk is breaking some of the
> assumptions in the fastboot mode.  I've seen problems like this on other
> platforms due to hard-coded sizes/addresses in the boot firmware.
> 

MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
thus cause user space fail. I will prepare new firmware that extend BOOT
partition to 16MB. and put new firmware on Howard's github. I will mail
to you when I am ready..

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-11  7:55                   ` Eddie Huang
  (?)
@ 2015-11-11 23:50                     ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11 23:50 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Eddie,

Eddie Huang <eddie.huang@mediatek.com> writes:

> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> [...]
>> 
>> > I check the log [0],
>> 
>> Thanks for checking into this boot failure.
>> 
>> > it seems first time mt8135-evbp1 boot to kernel
>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> > fastboot mode, waiting host send boot image, then timeout.
>> 
>> Actually, it never gets to a shell the first time.  If you look closely,
>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> line which says "finished booting, starting userspace"
>> 
>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> characters, but clearly it never got to a shell.
>> 
>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> > on my platform.
>> 
>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> one here:
>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> 
>
> Yes, I tried this ramdisk, and I can reproduce fail issue.
>

OK, good.   Thanks for looking into it.

>> Please check my boot logs to see how I'm generating the boot.img file
>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> that the kernel image size with a ramdisk is breaking some of the
>> assumptions in the fastboot mode.  I've seen problems like this on other
>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> 
>
> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> thus cause user space fail.

Aha, I was right!  ;)

> I will prepare new firmware that extend BOOT
> partition to 16MB. and put new firmware on Howard's github. I will mail
> to you when I am ready..

Great, thanks for working on this.

Any chance of making it even bigger?  We're working on running some more
automated testing from a ramdisk, and those ramdisks will be easily
30-50 Mb with modules included and a rootfs with extra tests.

Kevin


^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11 23:50                     ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11 23:50 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree@vger.kernel.org,
	Russell King - ARM Linux, srv_heupstream-NuS5LvNUpcJWk0Htik3J/w,
	Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml, Olof Johansson,
	Rob Herring, linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Sascha Hauer, Matthias Brugger,
	linux-arm-kernel@lists.infradead.org

Hi Eddie,

Eddie Huang <eddie.huang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> writes:

> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> [...]
>> 
>> > I check the log [0],
>> 
>> Thanks for checking into this boot failure.
>> 
>> > it seems first time mt8135-evbp1 boot to kernel
>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> > fastboot mode, waiting host send boot image, then timeout.
>> 
>> Actually, it never gets to a shell the first time.  If you look closely,
>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> line which says "finished booting, starting userspace"
>> 
>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> characters, but clearly it never got to a shell.
>> 
>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> > on my platform.
>> 
>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> one here:
>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> 
>
> Yes, I tried this ramdisk, and I can reproduce fail issue.
>

OK, good.   Thanks for looking into it.

>> Please check my boot logs to see how I'm generating the boot.img file
>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> that the kernel image size with a ramdisk is breaking some of the
>> assumptions in the fastboot mode.  I've seen problems like this on other
>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> 
>
> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> thus cause user space fail.

Aha, I was right!  ;)

> I will prepare new firmware that extend BOOT
> partition to 16MB. and put new firmware on Howard's github. I will mail
> to you when I am ready..

Great, thanks for working on this.

Any chance of making it even bigger?  We're working on running some more
automated testing from a ramdisk, and those ramdisks will be easily
30-50 Mb with modules included and a rootfs with extra tests.

Kevin

--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-11 23:50                     ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-11 23:50 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Eddie,

Eddie Huang <eddie.huang@mediatek.com> writes:

> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> [...]
>> 
>> > I check the log [0],
>> 
>> Thanks for checking into this boot failure.
>> 
>> > it seems first time mt8135-evbp1 boot to kernel
>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> > fastboot mode, waiting host send boot image, then timeout.
>> 
>> Actually, it never gets to a shell the first time.  If you look closely,
>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> line which says "finished booting, starting userspace"
>> 
>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> characters, but clearly it never got to a shell.
>> 
>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> > on my platform.
>> 
>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> one here:
>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> 
>
> Yes, I tried this ramdisk, and I can reproduce fail issue.
>

OK, good.   Thanks for looking into it.

>> Please check my boot logs to see how I'm generating the boot.img file
>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> that the kernel image size with a ramdisk is breaking some of the
>> assumptions in the fastboot mode.  I've seen problems like this on other
>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> 
>
> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> thus cause user space fail.

Aha, I was right!  ;)

> I will prepare new firmware that extend BOOT
> partition to 16MB. and put new firmware on Howard's github. I will mail
> to you when I am ready..

Great, thanks for working on this.

Any chance of making it even bigger?  We're working on running some more
automated testing from a ramdisk, and those ramdisks will be easily
30-50 Mb with modules included and a rootfs with extra tests.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-11 23:50                     ` Kevin Hilman
  (?)
@ 2015-11-12  4:54                       ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12  4:54 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Eddie,

Kevin Hilman <khilman@kernel.org> writes:

> Eddie Huang <eddie.huang@mediatek.com> writes:
>
>> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>>> Hi Eddie,
>>> 
>>> [...]
>>> 
>>> > I check the log [0],
>>> 
>>> Thanks for checking into this boot failure.
>>> 
>>> > it seems first time mt8135-evbp1 boot to kernel
>>> > shell successfully, then boot again. In the second time, mt8135 stay in
>>> > fastboot mode, waiting host send boot image, then timeout.
>>> 
>>> Actually, it never gets to a shell the first time.  If you look closely,
>>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>>> line which says "finished booting, starting userspace"
>>> 
>>> Later on, pyboot thinks it finds a root shell due to finding '#'
>>> characters, but clearly it never got to a shell.
>>> 
>>> > I download zImage and dtb in [1], and kernel run to shell successfully
>>> > on my platform.
>>> 
>>> Are you can you try using a ramdisk as well?  You can use the pre-built
>>> one here:
>>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>>> 
>>
>> Yes, I tried this ramdisk, and I can reproduce fail issue.
>>
>
> OK, good.   Thanks for looking into it.
>
>>> Please check my boot logs to see how I'm generating the boot.img file
>>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>>> that the kernel image size with a ramdisk is breaking some of the
>>> assumptions in the fastboot mode.  I've seen problems like this on other
>>> platforms due to hard-coded sizes/addresses in the boot firmware.
>>> 
>>
>> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> thus cause user space fail.
>
> Aha, I was right!  ;)

Also notice in kernelci.org that the mt8173 board has also been failing
to boot in mainline[1].  I wonder if this same limitation exists in the
mt8173 boot firmware?

Kevin

[1] http://kernelci.org/boot/mt8173-evb/job/mainline/kernel/v4.3-11553-g8d3de01cfa37/defconfig/defconfig/lab/lab-khilman/?_id=5643bc3959b5145c9e0918f4

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12  4:54                       ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12  4:54 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Hi Eddie,

Kevin Hilman <khilman@kernel.org> writes:

> Eddie Huang <eddie.huang@mediatek.com> writes:
>
>> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>>> Hi Eddie,
>>> 
>>> [...]
>>> 
>>> > I check the log [0],
>>> 
>>> Thanks for checking into this boot failure.
>>> 
>>> > it seems first time mt8135-evbp1 boot to kernel
>>> > shell successfully, then boot again. In the second time, mt8135 stay in
>>> > fastboot mode, waiting host send boot image, then timeout.
>>> 
>>> Actually, it never gets to a shell the first time.  If you look closely,
>>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>>> line which says "finished booting, starting userspace"
>>> 
>>> Later on, pyboot thinks it finds a root shell due to finding '#'
>>> characters, but clearly it never got to a shell.
>>> 
>>> > I download zImage and dtb in [1], and kernel run to shell successfully
>>> > on my platform.
>>> 
>>> Are you can you try using a ramdisk as well?  You can use the pre-built
>>> one here:
>>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>>> 
>>
>> Yes, I tried this ramdisk, and I can reproduce fail issue.
>>
>
> OK, good.   Thanks for looking into it.
>
>>> Please check my boot logs to see how I'm generating the boot.img file
>>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>>> that the kernel image size with a ramdisk is breaking some of the
>>> assumptions in the fastboot mode.  I've seen problems like this on other
>>> platforms due to hard-coded sizes/addresses in the boot firmware.
>>> 
>>
>> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> thus cause user space fail.
>
> Aha, I was right!  ;)

Also notice in kernelci.org that the mt8173 board has also been failing
to boot in mainline[1].  I wonder if this same limitation exists in the
mt8173 boot firmware?

Kevin

[1] http://kernelci.org/boot/mt8173-evb/job/mainline/kernel/v4.3-11553-g8d3de01cfa37/defconfig/defconfig/lab/lab-khilman/?_id=5643bc3959b5145c9e0918f4

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12  4:54                       ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12  4:54 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Eddie,

Kevin Hilman <khilman@kernel.org> writes:

> Eddie Huang <eddie.huang@mediatek.com> writes:
>
>> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>>> Hi Eddie,
>>> 
>>> [...]
>>> 
>>> > I check the log [0],
>>> 
>>> Thanks for checking into this boot failure.
>>> 
>>> > it seems first time mt8135-evbp1 boot to kernel
>>> > shell successfully, then boot again. In the second time, mt8135 stay in
>>> > fastboot mode, waiting host send boot image, then timeout.
>>> 
>>> Actually, it never gets to a shell the first time.  If you look closely,
>>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>>> line which says "finished booting, starting userspace"
>>> 
>>> Later on, pyboot thinks it finds a root shell due to finding '#'
>>> characters, but clearly it never got to a shell.
>>> 
>>> > I download zImage and dtb in [1], and kernel run to shell successfully
>>> > on my platform.
>>> 
>>> Are you can you try using a ramdisk as well?  You can use the pre-built
>>> one here:
>>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>>> 
>>
>> Yes, I tried this ramdisk, and I can reproduce fail issue.
>>
>
> OK, good.   Thanks for looking into it.
>
>>> Please check my boot logs to see how I'm generating the boot.img file
>>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>>> that the kernel image size with a ramdisk is breaking some of the
>>> assumptions in the fastboot mode.  I've seen problems like this on other
>>> platforms due to hard-coded sizes/addresses in the boot firmware.
>>> 
>>
>> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> thus cause user space fail.
>
> Aha, I was right!  ;)

Also notice in kernelci.org that the mt8173 board has also been failing
to boot in mainline[1].  I wonder if this same limitation exists in the
mt8173 boot firmware?

Kevin

[1] http://kernelci.org/boot/mt8173-evb/job/mainline/kernel/v4.3-11553-g8d3de01cfa37/defconfig/defconfig/lab/lab-khilman/?_id=5643bc3959b5145c9e0918f4

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12 12:46                         ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-12 12:46 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> Kevin Hilman <khilman@kernel.org> writes:
> 
> > Eddie Huang <eddie.huang@mediatek.com> writes:
> >
> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >>> Hi Eddie,
> >>> 
> >>> [...]
> >>> 
> >>> > I check the log [0],
> >>> 
> >>> Thanks for checking into this boot failure.
> >>> 
> >>> > it seems first time mt8135-evbp1 boot to kernel
> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >>> > fastboot mode, waiting host send boot image, then timeout.
> >>> 
> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >>> line which says "finished booting, starting userspace"
> >>> 
> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >>> characters, but clearly it never got to a shell.
> >>> 
> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >>> > on my platform.
> >>> 
> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >>> one here:
> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >>> 
> >>
> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >>
> >
> > OK, good.   Thanks for looking into it.
> >
> >>> Please check my boot logs to see how I'm generating the boot.img file
> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >>> that the kernel image size with a ramdisk is breaking some of the
> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >>> 
> >>
> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> thus cause user space fail.
> >
> > Aha, I was right!  ;)
> 
> Also notice in kernelci.org that the mt8173 board has also been failing
> to boot in mainline[1].  I wonder if this same limitation exists in the
> mt8173 boot firmware?
> 

MT8173 is another case, the failure is due to following commit:
67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes

It is because this commit register MM subsystem clock, but kernel don't
use MM clock yet, then CCF disable it. (My internal platform kernel
command include clk_ignore_unused parameter, so don't have this
problem).I will do further checking and release solution later. Thanks
your testing.

Eddie
Thanks



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12 12:46                         ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-12 12:46 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: Yingjoe Chen, devicetree-u79uwXL29TY76Z2rM5mHXA,
	Russell King - ARM Linux, srv_heupstream-NuS5LvNUpcJWk0Htik3J/w,
	Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml, Olof Johansson,
	Rob Herring, linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	Sascha Hauer, Matthias Brugger,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> Kevin Hilman <khilman-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org> writes:
> 
> > Eddie Huang <eddie.huang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org> writes:
> >
> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >>> Hi Eddie,
> >>> 
> >>> [...]
> >>> 
> >>> > I check the log [0],
> >>> 
> >>> Thanks for checking into this boot failure.
> >>> 
> >>> > it seems first time mt8135-evbp1 boot to kernel
> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >>> > fastboot mode, waiting host send boot image, then timeout.
> >>> 
> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >>> line which says "finished booting, starting userspace"
> >>> 
> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >>> characters, but clearly it never got to a shell.
> >>> 
> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >>> > on my platform.
> >>> 
> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >>> one here:
> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >>> 
> >>
> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >>
> >
> > OK, good.   Thanks for looking into it.
> >
> >>> Please check my boot logs to see how I'm generating the boot.img file
> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >>> that the kernel image size with a ramdisk is breaking some of the
> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >>> 
> >>
> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> thus cause user space fail.
> >
> > Aha, I was right!  ;)
> 
> Also notice in kernelci.org that the mt8173 board has also been failing
> to boot in mainline[1].  I wonder if this same limitation exists in the
> mt8173 boot firmware?
> 

MT8173 is another case, the failure is due to following commit:
67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes

It is because this commit register MM subsystem clock, but kernel don't
use MM clock yet, then CCF disable it. (My internal platform kernel
command include clk_ignore_unused parameter, so don't have this
problem).I will do further checking and release solution later. Thanks
your testing.

Eddie
Thanks


--
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

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12 12:46                         ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-12 12:46 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> Hi Eddie,
> 
> Kevin Hilman <khilman@kernel.org> writes:
> 
> > Eddie Huang <eddie.huang@mediatek.com> writes:
> >
> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >>> Hi Eddie,
> >>> 
> >>> [...]
> >>> 
> >>> > I check the log [0],
> >>> 
> >>> Thanks for checking into this boot failure.
> >>> 
> >>> > it seems first time mt8135-evbp1 boot to kernel
> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >>> > fastboot mode, waiting host send boot image, then timeout.
> >>> 
> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >>> line which says "finished booting, starting userspace"
> >>> 
> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >>> characters, but clearly it never got to a shell.
> >>> 
> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >>> > on my platform.
> >>> 
> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >>> one here:
> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >>> 
> >>
> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >>
> >
> > OK, good.   Thanks for looking into it.
> >
> >>> Please check my boot logs to see how I'm generating the boot.img file
> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >>> that the kernel image size with a ramdisk is breaking some of the
> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >>> 
> >>
> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> thus cause user space fail.
> >
> > Aha, I was right!  ;)
> 
> Also notice in kernelci.org that the mt8173 board has also been failing
> to boot in mainline[1].  I wonder if this same limitation exists in the
> mt8173 boot firmware?
> 

MT8173 is another case, the failure is due to following commit:
67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes

It is because this commit register MM subsystem clock, but kernel don't
use MM clock yet, then CCF disable it. (My internal platform kernel
command include clk_ignore_unused parameter, so don't have this
problem).I will do further checking and release solution later. Thanks
your testing.

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-12 12:46                         ` Eddie Huang
  (?)
@ 2015-11-12 23:56                           ` Kevin Hilman
  -1 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12 23:56 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Eddie Huang <eddie.huang@mediatek.com> writes:

> On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> Kevin Hilman <khilman@kernel.org> writes:
>> 
>> > Eddie Huang <eddie.huang@mediatek.com> writes:
>> >
>> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> >>> Hi Eddie,
>> >>> 
>> >>> [...]
>> >>> 
>> >>> > I check the log [0],
>> >>> 
>> >>> Thanks for checking into this boot failure.
>> >>> 
>> >>> > it seems first time mt8135-evbp1 boot to kernel
>> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> >>> > fastboot mode, waiting host send boot image, then timeout.
>> >>> 
>> >>> Actually, it never gets to a shell the first time.  If you look closely,
>> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> >>> line which says "finished booting, starting userspace"
>> >>> 
>> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> >>> characters, but clearly it never got to a shell.
>> >>> 
>> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> >>> > on my platform.
>> >>> 
>> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> >>> one here:
>> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> >>> 
>> >>
>> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
>> >>
>> >
>> > OK, good.   Thanks for looking into it.
>> >
>> >>> Please check my boot logs to see how I'm generating the boot.img file
>> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> >>> that the kernel image size with a ramdisk is breaking some of the
>> >>> assumptions in the fastboot mode.  I've seen problems like this on other
>> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> >>> 
>> >>
>> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> >> thus cause user space fail.
>> >
>> > Aha, I was right!  ;)
>> 
>> Also notice in kernelci.org that the mt8173 board has also been failing
>> to boot in mainline[1].  I wonder if this same limitation exists in the
>> mt8173 boot firmware?
>> 
>
> MT8173 is another case, the failure is due to following commit:
> 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
>
> It is because this commit register MM subsystem clock, but kernel don't
> use MM clock yet, then CCF disable it. (My internal platform kernel
> command include clk_ignore_unused parameter, so don't have this
> problem).I will do further checking and release solution later. Thanks
> your testing.

OK, thanks for looking into it.

However, since the merge window is very close to closing, unless you can
git a fix out soon (and one that doesn't introduce other bugs),
probablly the right solution is to just revert the above patch so things
are fixed for mainline ASAP.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12 23:56                           ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12 23:56 UTC (permalink / raw)
  To: Eddie Huang
  Cc: Yingjoe Chen, devicetree, Russell King - ARM Linux,
	srv_heupstream, Arnd Bergmann, Tyler Baker, Stephen Boyd, lkml,
	Olof Johansson, Rob Herring, linux-mediatek, Sascha Hauer,
	Matthias Brugger, linux-arm-kernel

Eddie Huang <eddie.huang@mediatek.com> writes:

> On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> Kevin Hilman <khilman@kernel.org> writes:
>> 
>> > Eddie Huang <eddie.huang@mediatek.com> writes:
>> >
>> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> >>> Hi Eddie,
>> >>> 
>> >>> [...]
>> >>> 
>> >>> > I check the log [0],
>> >>> 
>> >>> Thanks for checking into this boot failure.
>> >>> 
>> >>> > it seems first time mt8135-evbp1 boot to kernel
>> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> >>> > fastboot mode, waiting host send boot image, then timeout.
>> >>> 
>> >>> Actually, it never gets to a shell the first time.  If you look closely,
>> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> >>> line which says "finished booting, starting userspace"
>> >>> 
>> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> >>> characters, but clearly it never got to a shell.
>> >>> 
>> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> >>> > on my platform.
>> >>> 
>> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> >>> one here:
>> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> >>> 
>> >>
>> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
>> >>
>> >
>> > OK, good.   Thanks for looking into it.
>> >
>> >>> Please check my boot logs to see how I'm generating the boot.img file
>> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> >>> that the kernel image size with a ramdisk is breaking some of the
>> >>> assumptions in the fastboot mode.  I've seen problems like this on other
>> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> >>> 
>> >>
>> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> >> thus cause user space fail.
>> >
>> > Aha, I was right!  ;)
>> 
>> Also notice in kernelci.org that the mt8173 board has also been failing
>> to boot in mainline[1].  I wonder if this same limitation exists in the
>> mt8173 boot firmware?
>> 
>
> MT8173 is another case, the failure is due to following commit:
> 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
>
> It is because this commit register MM subsystem clock, but kernel don't
> use MM clock yet, then CCF disable it. (My internal platform kernel
> command include clk_ignore_unused parameter, so don't have this
> problem).I will do further checking and release solution later. Thanks
> your testing.

OK, thanks for looking into it.

However, since the merge window is very close to closing, unless you can
git a fix out soon (and one that doesn't introduce other bugs),
probablly the right solution is to just revert the above patch so things
are fixed for mainline ASAP.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-12 23:56                           ` Kevin Hilman
  0 siblings, 0 replies; 66+ messages in thread
From: Kevin Hilman @ 2015-11-12 23:56 UTC (permalink / raw)
  To: linux-arm-kernel

Eddie Huang <eddie.huang@mediatek.com> writes:

> On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
>> Hi Eddie,
>> 
>> Kevin Hilman <khilman@kernel.org> writes:
>> 
>> > Eddie Huang <eddie.huang@mediatek.com> writes:
>> >
>> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
>> >>> Hi Eddie,
>> >>> 
>> >>> [...]
>> >>> 
>> >>> > I check the log [0],
>> >>> 
>> >>> Thanks for checking into this boot failure.
>> >>> 
>> >>> > it seems first time mt8135-evbp1 boot to kernel
>> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
>> >>> > fastboot mode, waiting host send boot image, then timeout.
>> >>> 
>> >>> Actually, it never gets to a shell the first time.  If you look closely,
>> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
>> >>> line which says "finished booting, starting userspace"
>> >>> 
>> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
>> >>> characters, but clearly it never got to a shell.
>> >>> 
>> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
>> >>> > on my platform.
>> >>> 
>> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
>> >>> one here:
>> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
>> >>> 
>> >>
>> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
>> >>
>> >
>> > OK, good.   Thanks for looking into it.
>> >
>> >>> Please check my boot logs to see how I'm generating the boot.img file
>> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
>> >>> that the kernel image size with a ramdisk is breaking some of the
>> >>> assumptions in the fastboot mode.  I've seen problems like this on other
>> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
>> >>> 
>> >>
>> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
>> >> thus cause user space fail.
>> >
>> > Aha, I was right!  ;)
>> 
>> Also notice in kernelci.org that the mt8173 board has also been failing
>> to boot in mainline[1].  I wonder if this same limitation exists in the
>> mt8173 boot firmware?
>> 
>
> MT8173 is another case, the failure is due to following commit:
> 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
>
> It is because this commit register MM subsystem clock, but kernel don't
> use MM clock yet, then CCF disable it. (My internal platform kernel
> command include clk_ignore_unused parameter, so don't have this
> problem).I will do further checking and release solution later. Thanks
> your testing.

OK, thanks for looking into it.

However, since the merge window is very close to closing, unless you can
git a fix out soon (and one that doesn't introduce other bugs),
probablly the right solution is to just revert the above patch so things
are fixed for mainline ASAP.

Kevin

^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
  2015-11-12 23:56                           ` Kevin Hilman
  (?)
@ 2015-11-13 10:56                             ` Eddie Huang
  -1 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-13 10:56 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: devicetree, Russell King - ARM Linux, srv_heupstream,
	Arnd Bergmann, Stephen Boyd, Tyler Baker, lkml, Matthias Brugger,
	Rob Herring, linux-mediatek, Sascha Hauer, Olof Johansson,
	Yingjoe Chen, linux-arm-kernel

On Thu, 2015-11-12 at 15:56 -0800, Kevin Hilman wrote:
> Eddie Huang <eddie.huang@mediatek.com> writes:
> 
> > On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> >> Hi Eddie,
> >> 
> >> Kevin Hilman <khilman@kernel.org> writes:
> >> 
> >> > Eddie Huang <eddie.huang@mediatek.com> writes:
> >> >
> >> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >> >>> Hi Eddie,
> >> >>> 
> >> >>> [...]
> >> >>> 
> >> >>> > I check the log [0],
> >> >>> 
> >> >>> Thanks for checking into this boot failure.
> >> >>> 
> >> >>> > it seems first time mt8135-evbp1 boot to kernel
> >> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >> >>> > fastboot mode, waiting host send boot image, then timeout.
> >> >>> 
> >> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >> >>> line which says "finished booting, starting userspace"
> >> >>> 
> >> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >> >>> characters, but clearly it never got to a shell.
> >> >>> 
> >> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >> >>> > on my platform.
> >> >>> 
> >> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >> >>> one here:
> >> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >> >>> 
> >> >>
> >> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >> >>
> >> >
> >> > OK, good.   Thanks for looking into it.
> >> >
> >> >>> Please check my boot logs to see how I'm generating the boot.img file
> >> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >> >>> that the kernel image size with a ramdisk is breaking some of the
> >> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >> >>> 
> >> >>
> >> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> >> thus cause user space fail.
> >> >
> >> > Aha, I was right!  ;)
> >> 
> >> Also notice in kernelci.org that the mt8173 board has also been failing
> >> to boot in mainline[1].  I wonder if this same limitation exists in the
> >> mt8173 boot firmware?
> >> 
> >
> > MT8173 is another case, the failure is due to following commit:
> > 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
> >
> > It is because this commit register MM subsystem clock, but kernel don't
> > use MM clock yet, then CCF disable it. (My internal platform kernel
> > command include clk_ignore_unused parameter, so don't have this
> > problem).I will do further checking and release solution later. Thanks
> > your testing.
> 
> OK, thanks for looking into it.
> 
> However, since the merge window is very close to closing, unless you can
> git a fix out soon (and one that doesn't introduce other bugs),
> probablly the right solution is to just revert the above patch so things
> are fixed for mainline ASAP.
> 

I send one patch to fix this problem. Hope this patch can apply to 4.4.

http://lists.infradead.org/pipermail/linux-arm-kernel/2015-November/384800.html

Eddie
Thanks



^ permalink raw reply	[flat|nested] 66+ messages in thread

* Re: [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-13 10:56                             ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-13 10:56 UTC (permalink / raw)
  To: Kevin Hilman
  Cc: devicetree, Russell King - ARM Linux, srv_heupstream,
	Arnd Bergmann, Stephen Boyd, Tyler Baker, lkml, Matthias Brugger,
	Rob Herring, linux-mediatek, Sascha Hauer, Olof Johansson,
	Yingjoe Chen, linux-arm-kernel

On Thu, 2015-11-12 at 15:56 -0800, Kevin Hilman wrote:
> Eddie Huang <eddie.huang@mediatek.com> writes:
> 
> > On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> >> Hi Eddie,
> >> 
> >> Kevin Hilman <khilman@kernel.org> writes:
> >> 
> >> > Eddie Huang <eddie.huang@mediatek.com> writes:
> >> >
> >> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >> >>> Hi Eddie,
> >> >>> 
> >> >>> [...]
> >> >>> 
> >> >>> > I check the log [0],
> >> >>> 
> >> >>> Thanks for checking into this boot failure.
> >> >>> 
> >> >>> > it seems first time mt8135-evbp1 boot to kernel
> >> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >> >>> > fastboot mode, waiting host send boot image, then timeout.
> >> >>> 
> >> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >> >>> line which says "finished booting, starting userspace"
> >> >>> 
> >> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >> >>> characters, but clearly it never got to a shell.
> >> >>> 
> >> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >> >>> > on my platform.
> >> >>> 
> >> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >> >>> one here:
> >> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >> >>> 
> >> >>
> >> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >> >>
> >> >
> >> > OK, good.   Thanks for looking into it.
> >> >
> >> >>> Please check my boot logs to see how I'm generating the boot.img file
> >> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >> >>> that the kernel image size with a ramdisk is breaking some of the
> >> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >> >>> 
> >> >>
> >> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> >> thus cause user space fail.
> >> >
> >> > Aha, I was right!  ;)
> >> 
> >> Also notice in kernelci.org that the mt8173 board has also been failing
> >> to boot in mainline[1].  I wonder if this same limitation exists in the
> >> mt8173 boot firmware?
> >> 
> >
> > MT8173 is another case, the failure is due to following commit:
> > 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
> >
> > It is because this commit register MM subsystem clock, but kernel don't
> > use MM clock yet, then CCF disable it. (My internal platform kernel
> > command include clk_ignore_unused parameter, so don't have this
> > problem).I will do further checking and release solution later. Thanks
> > your testing.
> 
> OK, thanks for looking into it.
> 
> However, since the merge window is very close to closing, unless you can
> git a fix out soon (and one that doesn't introduce other bugs),
> probablly the right solution is to just revert the above patch so things
> are fixed for mainline ASAP.
> 

I send one patch to fix this problem. Hope this patch can apply to 4.4.

http://lists.infradead.org/pipermail/linux-arm-kernel/2015-November/384800.html

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

* [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135
@ 2015-11-13 10:56                             ` Eddie Huang
  0 siblings, 0 replies; 66+ messages in thread
From: Eddie Huang @ 2015-11-13 10:56 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, 2015-11-12 at 15:56 -0800, Kevin Hilman wrote:
> Eddie Huang <eddie.huang@mediatek.com> writes:
> 
> > On Wed, 2015-11-11 at 20:54 -0800, Kevin Hilman wrote:
> >> Hi Eddie,
> >> 
> >> Kevin Hilman <khilman@kernel.org> writes:
> >> 
> >> > Eddie Huang <eddie.huang@mediatek.com> writes:
> >> >
> >> >> On Tue, 2015-11-10 at 17:16 -0800, Kevin Hilman wrote:
> >> >>> Hi Eddie,
> >> >>> 
> >> >>> [...]
> >> >>> 
> >> >>> > I check the log [0],
> >> >>> 
> >> >>> Thanks for checking into this boot failure.
> >> >>> 
> >> >>> > it seems first time mt8135-evbp1 boot to kernel
> >> >>> > shell successfully, then boot again. In the second time, mt8135 stay in
> >> >>> > fastboot mode, waiting host send boot image, then timeout.
> >> >>> 
> >> >>> Actually, it never gets to a shell the first time.  If you look closely,
> >> >>> the target reboots as soon as userspace starts.   Look for the PYBOOT
> >> >>> line which says "finished booting, starting userspace"
> >> >>> 
> >> >>> Later on, pyboot thinks it finds a root shell due to finding '#'
> >> >>> characters, but clearly it never got to a shell.
> >> >>> 
> >> >>> > I download zImage and dtb in [1], and kernel run to shell successfully
> >> >>> > on my platform.
> >> >>> 
> >> >>> Are you can you try using a ramdisk as well?  You can use the pre-built
> >> >>> one here:
> >> >>> http://storage.kernelci.org/images/rootfs/buildroot/armel/rootfs.cpio.gz
> >> >>> 
> >> >>
> >> >> Yes, I tried this ramdisk, and I can reproduce fail issue.
> >> >>
> >> >
> >> > OK, good.   Thanks for looking into it.
> >> >
> >> >>> Please check my boot logs to see how I'm generating the boot.img file
> >> >>> (search for mkbootimg) with a kernel/dtb/ramdisk.  It may be possible
> >> >>> that the kernel image size with a ramdisk is breaking some of the
> >> >>> assumptions in the fastboot mode.  I've seen problems like this on other
> >> >>> platforms due to hard-coded sizes/addresses in the boot firmware.
> >> >>> 
> >> >>
> >> >> MT8135 allocate 10MB for BOOT partition, but the test boot.img is 11MB,
> >> >> thus cause user space fail.
> >> >
> >> > Aha, I was right!  ;)
> >> 
> >> Also notice in kernelci.org that the mt8173 board has also been failing
> >> to boot in mainline[1].  I wonder if this same limitation exists in the
> >> mt8173 boot firmware?
> >> 
> >
> > MT8173 is another case, the failure is due to following commit:
> > 67e56c5 arm64: dts: mt8173: Add subsystem clock controller device nodes
> >
> > It is because this commit register MM subsystem clock, but kernel don't
> > use MM clock yet, then CCF disable it. (My internal platform kernel
> > command include clk_ignore_unused parameter, so don't have this
> > problem).I will do further checking and release solution later. Thanks
> > your testing.
> 
> OK, thanks for looking into it.
> 
> However, since the merge window is very close to closing, unless you can
> git a fix out soon (and one that doesn't introduce other bugs),
> probablly the right solution is to just revert the above patch so things
> are fixed for mainline ASAP.
> 

I send one patch to fix this problem. Hope this patch can apply to 4.4.

http://lists.infradead.org/pipermail/linux-arm-kernel/2015-November/384800.html

Eddie
Thanks

^ permalink raw reply	[flat|nested] 66+ messages in thread

end of thread, other threads:[~2015-11-13 10:56 UTC | newest]

Thread overview: 66+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-02 15:19 [PATCH v5 0/5] Add SMP bringup support for mt65xx socs Yingjoe Chen
2015-10-02 15:19 ` Yingjoe Chen
2015-10-02 15:19 ` Yingjoe Chen
2015-10-02 15:19 ` [PATCH v5 1/5] ARM: mediatek: enable gpt6 on boot up to make arch timer working Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19 ` [PATCH v5 2/5] devicetree: bindings: add new SMP enable method Mediatek SoC Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19 ` [PATCH v5 3/5] ARM: mediatek: add smp bringup code Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19 ` [PATCH v5 4/5] ARM: dts: mt8135: enable basic SMP bringup for mt8135 Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-26  0:56   ` Kevin Hilman
2015-10-26  0:56     ` Kevin Hilman
2015-10-26  0:56     ` Kevin Hilman
2015-10-26  7:15     ` Yingjoe Chen
2015-10-26  7:15       ` Yingjoe Chen
2015-10-26  7:15       ` Yingjoe Chen
2015-10-26  8:06       ` Kevin Hilman
2015-10-26  8:06         ` Kevin Hilman
2015-10-26  8:06         ` Kevin Hilman
2015-10-26 11:40         ` Eddie Huang
2015-10-26 11:40           ` Eddie Huang
2015-10-26 11:40           ` Eddie Huang
2015-10-29  9:12           ` Kevin Hilman
2015-10-29  9:12             ` Kevin Hilman
2015-10-29  9:12             ` Kevin Hilman
2015-10-29 12:03             ` Eddie Huang
2015-10-29 12:03               ` Eddie Huang
2015-10-29 12:03               ` Eddie Huang
2015-11-09 17:59           ` Kevin Hilman
2015-11-09 17:59             ` Kevin Hilman
2015-11-09 17:59             ` Kevin Hilman
2015-11-10  6:11             ` Eddie Huang
2015-11-10  6:11               ` Eddie Huang
2015-11-10  6:11               ` Eddie Huang
2015-11-11  1:16               ` Kevin Hilman
2015-11-11  1:16                 ` Kevin Hilman
2015-11-11  1:16                 ` Kevin Hilman
2015-11-11  7:55                 ` Eddie Huang
2015-11-11  7:55                   ` Eddie Huang
2015-11-11  7:55                   ` Eddie Huang
2015-11-11 23:50                   ` Kevin Hilman
2015-11-11 23:50                     ` Kevin Hilman
2015-11-11 23:50                     ` Kevin Hilman
2015-11-12  4:54                     ` Kevin Hilman
2015-11-12  4:54                       ` Kevin Hilman
2015-11-12  4:54                       ` Kevin Hilman
2015-11-12 12:46                       ` Eddie Huang
2015-11-12 12:46                         ` Eddie Huang
2015-11-12 12:46                         ` Eddie Huang
2015-11-12 23:56                         ` Kevin Hilman
2015-11-12 23:56                           ` Kevin Hilman
2015-11-12 23:56                           ` Kevin Hilman
2015-11-13 10:56                           ` Eddie Huang
2015-11-13 10:56                             ` Eddie Huang
2015-11-13 10:56                             ` Eddie Huang
2015-10-02 15:19 ` [PATCH v5 5/5] ARM: dts: mt8127: enable basic SMP bringup for mt8127 Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-02 15:19   ` Yingjoe Chen
2015-10-12 17:30 ` [PATCH v5 0/5] Add SMP bringup support for mt65xx socs Matthias Brugger
2015-10-12 17:30   ` Matthias Brugger
2015-10-12 17:30   ` Matthias Brugger

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.