* [PATCH 0/2] Neutis N5H3 support
@ 2019-11-06 14:03 Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 1/2] arm: dts: allwinner: Split out non-SoC specific parts of Neutis N5 Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support Georgii Staroselskii
0 siblings, 2 replies; 5+ messages in thread
From: Georgii Staroselskii @ 2019-11-06 14:03 UTC (permalink / raw)
To: mripard, wens, robh+dt, mark.rutland
Cc: devicetree, linux-sunxi, linux-arm-kernel, Georgii Staroselskii
Emlid Neutis board has another variant with H3 instead of H5. This patchset
adds support for this board by moving common bits to
sunxi-h3-h5-emlid-neutis.dtsi and then including it in processor-specific DTS.
Georgii Staroselskii (2):
arm: dts: allwinner: Split out non-SoC specific parts of Neutis N5
arm: dts: sunxi: Add Neutis N5H3 support
arch/arm/boot/dts/Makefile | 1 +
.../dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts | 61 +++++++
arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi | 11 ++
arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi | 181 +++++++++++++++++++++
.../sun50i-h5-emlid-neutis-n5-devboard.dts | 95 +----------
.../dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi | 64 +-------
6 files changed, 259 insertions(+), 154 deletions(-)
create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
create mode 100644 arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi
--
2.7.4
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 1/2] arm: dts: allwinner: Split out non-SoC specific parts of Neutis N5
2019-11-06 14:03 [PATCH 0/2] Neutis N5H3 support Georgii Staroselskii
@ 2019-11-06 14:03 ` Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support Georgii Staroselskii
1 sibling, 0 replies; 5+ messages in thread
From: Georgii Staroselskii @ 2019-11-06 14:03 UTC (permalink / raw)
To: mripard, wens, robh+dt, mark.rutland
Cc: devicetree, linux-sunxi, linux-arm-kernel, Georgii Staroselskii
A new variant of Emlid Neutis has been inroduced. This one uses H3
instead of H5. The boards are essentially the same. This commit moves
non-SoC-specific parts out so that the common parts could be reused with
ease.
Signed-off-by: Georgii Staroselskii <georgii.staroselskii@emlid.com>
---
arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi | 181 +++++++++++++++++++++
.../sun50i-h5-emlid-neutis-n5-devboard.dts | 95 +----------
.../dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi | 64 +-------
3 files changed, 186 insertions(+), 154 deletions(-)
create mode 100644 arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi
diff --git a/arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi b/arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi
new file mode 100644
index 00000000..ecce01a
--- /dev/null
+++ b/arch/arm/boot/dts/sunxi-h3-h5-emlid-neutis.dtsi
@@ -0,0 +1,181 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/*
+ * DTSI for Emlid Neutis SoMs.
+ *
+ * Copyright (C) 2019 Georgii Staroselskii <georgii.staroselskii@emlid.com>
+ */
+
+#include "sunxi-common-regulators.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+
+/ {
+ aliases {
+ serial0 = &uart0;
+ };
+
+ chosen {
+ stdout-path = "serial0:115200n8";
+ };
+
+ connector {
+ compatible = "hdmi-connector";
+ type = "a";
+
+ port {
+ hdmi_con_in: endpoint {
+ remote-endpoint = <&hdmi_out_con>;
+ };
+ };
+ };
+
+ wifi_pwrseq: wifi_pwrseq {
+ compatible = "mmc-pwrseq-simple";
+ reset-gpios = <&pio 2 7 GPIO_ACTIVE_LOW>; /* PC7 */
+ post-power-on-delay-ms = <200>;
+ clocks = <&rtc 1>;
+ clock-names = "ext_clock";
+ };
+};
+
+&cpu0 {
+ cpu-supply = <&vdd_cpux>;
+};
+
+®_usb0_vbus {
+ gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */
+ status = "okay";
+};
+
+
+&de {
+ status = "okay";
+};
+
+&ohci0 {
+ status = "okay";
+};
+
+&ohci1 {
+ status = "okay";
+};
+
+&ohci2 {
+ status = "okay";
+};
+
+&ohci3 {
+ status = "okay";
+};
+
+
+&ehci0 {
+ status = "okay";
+};
+
+&ehci1 {
+ status = "okay";
+};
+
+&ehci2 {
+ status = "okay";
+};
+
+&ehci3 {
+ status = "okay";
+};
+
+&mmc0 {
+ vmmc-supply = <®_vcc3v3>;
+ bus-width = <4>;
+ cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
+ status = "okay";
+};
+
+
+&mmc1 {
+ vmmc-supply = <®_vcc3v3>;
+ vqmmc-supply = <®_vcc3v3>;
+ mmc-pwrseq = <&wifi_pwrseq>;
+ bus-width = <4>;
+ non-removable;
+ status = "okay";
+
+ brcmf: wifi@1 {
+ reg = <1>;
+ compatible = "brcm,bcm4329-fmac";
+ interrupt-parent = <&r_pio>;
+ interrupts = <0 5 IRQ_TYPE_LEVEL_LOW>; /* PL5 */
+ interrupt-names = "host-wake";
+ };
+};
+
+&mmc2 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&mmc2_8bit_pins>;
+ vmmc-supply = <®_vcc3v3>;
+ bus-width = <8>;
+ non-removable;
+ cap-mmc-hw-reset;
+ status = "okay";
+};
+
+&uart0 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart0_pa_pins>;
+ status = "okay";
+};
+
+
+&uart1 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart1_pins>, <&uart1_rts_cts_pins>;
+ uart-has-rtscts;
+ status = "okay";
+
+ bluetooth {
+ compatible = "brcm,bcm43438-bt";
+ clocks = <&rtc 1>;
+ clock-names = "lpo";
+ vbat-supply = <®_vcc3v3>;
+ vddio-supply = <®_vcc3v3>;
+ shutdown-gpios = <&pio 2 4 GPIO_ACTIVE_HIGH>; /* PC4 */
+ device-wakeup-gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */
+ };
+};
+
+&uart2 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart2_pins>;
+ status = "okay";
+};
+
+&uart3 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart3_pins>;
+ status = "okay";
+};
+
+&usbphy {
+ usb0_id_det-gpios = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
+ usb0_vbus-supply = <®_usb0_vbus>;
+ status = "okay";
+};
+
+&usb_otg {
+ dr_mode = "otg";
+ status = "okay";
+};
+
+&codec {
+ allwinner,audio-routing =
+ "Line Out", "LINEOUT",
+ "LINEIN", "Line In",
+ "MIC1", "Mic",
+ "MIC2", "Mic",
+ "Mic", "MBIAS";
+};
+
+&i2c0 {
+ status = "okay";
+};
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5-devboard.dts b/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5-devboard.dts
index c924090..fb96d35 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5-devboard.dts
+++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5-devboard.dts
@@ -15,35 +15,6 @@
"emlid,neutis-n5",
"allwinner,sun50i-h5";
- aliases {
- serial0 = &uart0;
- };
-
- chosen {
- stdout-path = "serial0:115200n8";
- };
-
- connector {
- compatible = "hdmi-connector";
- type = "a";
-
- port {
- hdmi_con_in: endpoint {
- remote-endpoint = <&hdmi_out_con>;
- };
- };
- };
-
- reg_usb0_vbus: usb0-vbus {
- compatible = "regulator-fixed";
- regulator-name = "usb0-vbus";
- regulator-min-microvolt = <5000000>;
- regulator-max-microvolt = <5000000>;
- enable-active-high;
- gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; /* PL9 */
- status = "okay";
- };
-
vdd_cpux: gpio-regulator {
compatible = "regulator-gpio";
regulator-name = "vdd-cpux";
@@ -59,33 +30,11 @@
};
};
-&codec {
- allwinner,audio-routing =
- "Line Out", "LINEOUT",
- "LINEIN", "Line In",
- "MIC1", "Mic",
- "MIC2", "Mic",
- "Mic", "MBIAS";
- status = "okay";
-};
-
-&de {
- status = "okay";
-};
-
-&ehci0 {
- status = "okay";
-};
-
-&ehci1 {
- status = "okay";
-};
-
-&ehci2 {
- status = "okay";
+&cpu0 {
+ cpu-supply = <&vdd_cpux>;
};
-&ehci3 {
+&codec {
status = "okay";
};
@@ -106,42 +55,6 @@
};
};
-&mmc0 {
- vmmc-supply = <®_vcc3v3>;
- bus-width = <4>;
- cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
- status = "okay";
-};
-
-&ohci0 {
- status = "okay";
-};
-
-&ohci1 {
- status = "okay";
-};
-
-&ohci2 {
- status = "okay";
-};
-
-&ohci3 {
- status = "okay";
-};
-
-&uart0 {
- pinctrl-names = "default";
- pinctrl-0 = <&uart0_pa_pins>;
- status = "okay";
-};
-
-&usb_otg {
- dr_mode = "otg";
- status = "okay";
-};
-
-&usbphy {
- usb0_id_det-gpios = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */
- usb0_vbus-supply = <®_usb0_vbus>;
+&i2c1 {
status = "okay";
};
diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi
index 5bec574..7df7308 100644
--- a/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi
+++ b/arch/arm64/boot/dts/allwinner/sun50i-h5-emlid-neutis-n5.dtsi
@@ -8,66 +8,4 @@
/dts-v1/;
#include "sun50i-h5.dtsi"
-
-#include <dt-bindings/gpio/gpio.h>
-
-/ {
- reg_vcc3v3: vcc3v3 {
- compatible = "regulator-fixed";
- regulator-name = "vcc3v3";
- regulator-min-microvolt = <3300000>;
- regulator-max-microvolt = <3300000>;
- };
-
- wifi_pwrseq: wifi_pwrseq {
- compatible = "mmc-pwrseq-simple";
- reset-gpios = <&pio 2 7 GPIO_ACTIVE_LOW>; /* PC7 */
- post-power-on-delay-ms = <200>;
- clocks = <&rtc 1>;
- clock-names = "ext_clock";
- };
-};
-
-&mmc1 {
- vmmc-supply = <®_vcc3v3>;
- vqmmc-supply = <®_vcc3v3>;
- mmc-pwrseq = <&wifi_pwrseq>;
- bus-width = <4>;
- non-removable;
- status = "okay";
-
- brcmf: wifi@1 {
- reg = <1>;
- compatible = "brcm,bcm4329-fmac";
- interrupt-parent = <&r_pio>;
- interrupts = <0 5 IRQ_TYPE_LEVEL_LOW>; /* PL5 */
- interrupt-names = "host-wake";
- };
-};
-
-&mmc2 {
- pinctrl-names = "default";
- pinctrl-0 = <&mmc2_8bit_pins>;
- vmmc-supply = <®_vcc3v3>;
- bus-width = <8>;
- non-removable;
- cap-mmc-hw-reset;
- status = "okay";
-};
-
-&uart1 {
- pinctrl-names = "default";
- pinctrl-0 = <&uart1_pins>, <&uart1_rts_cts_pins>;
- uart-has-rtscts;
- status = "okay";
-
- bluetooth {
- compatible = "brcm,bcm43438-bt";
- clocks = <&rtc 1>;
- clock-names = "lpo";
- vbat-supply = <®_vcc3v3>;
- vddio-supply = <®_vcc3v3>;
- shutdown-gpios = <&pio 2 4 GPIO_ACTIVE_HIGH>; /* PC4 */
- device-wakeup-gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */
- };
-};
+#include <arm/sunxi-h3-h5-emlid-neutis.dtsi>
--
2.7.4
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support
2019-11-06 14:03 [PATCH 0/2] Neutis N5H3 support Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 1/2] arm: dts: allwinner: Split out non-SoC specific parts of Neutis N5 Georgii Staroselskii
@ 2019-11-06 14:03 ` Georgii Staroselskii
2019-11-12 12:15 ` Maxime Ripard
1 sibling, 1 reply; 5+ messages in thread
From: Georgii Staroselskii @ 2019-11-06 14:03 UTC (permalink / raw)
To: mripard, wens, robh+dt, mark.rutland
Cc: devicetree, linux-sunxi, linux-arm-kernel, Georgii Staroselskii
Emlid Neutis N5H3 is a version of Emlid Neutis SoM with H3 instead of H5
inside.
6eeb4180d4b9 ("ARM: dts: sunxi: h3-h5: Add Bananapi M2+ v1.2 device")
was used as reference.
Signed-off-by: Georgii Staroselskii <georgii.staroselskii@emlid.com>
---
arch/arm/boot/dts/Makefile | 1 +
.../dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts | 61 ++++++++++++++++++++++
arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi | 11 ++++
3 files changed, 73 insertions(+)
create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 3f13b88..c997b0c 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -1119,6 +1119,7 @@ dtb-$(CONFIG_MACH_SUN8I) += \
sun8i-h3-orangepi-plus2e.dtb \
sun8i-h3-orangepi-zero-plus2.dtb \
sun8i-h3-rervision-dvk.dtb \
+ sun8i-h3-emlid-neutis-n5h3-devboard.dtb \
sun8i-r16-bananapi-m2m.dtb \
sun8i-r16-nintendo-nes-classic.dtb \
sun8i-r16-nintendo-super-nes-classic.dtb \
diff --git a/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
new file mode 100644
index 00000000..3b68750
--- /dev/null
+++ b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
@@ -0,0 +1,61 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/*
+ * DTS for Emlid Neutis N5 Dev board.
+ *
+ * Copyright (C) 2019 Georgii Staroselskii <georgiii.staroselskii@emlid.com>
+ */
+
+/dts-v1/;
+
+#include "sun8i-h3-emlid-neutis-n5h3.dtsi"
+
+/ {
+ model = "Emlid Neutis N5H3 Developer board";
+ compatible = "emlid,neutis-n5h3-devboard",
+ "emlid,neutis-n5h3",
+ "allwinner,sun8i-h3";
+
+ vdd_cpux: gpio-regulator {
+ compatible = "regulator-gpio";
+ regulator-name = "vdd-cpux";
+ regulator-type = "voltage";
+ regulator-boot-on;
+ regulator-always-on;
+ regulator-min-microvolt = <1100000>;
+ regulator-max-microvolt = <1300000>;
+ regulator-ramp-delay = <50>; /* 4ms */
+ gpios = <&r_pio 0 6 GPIO_ACTIVE_HIGH>; /* PL6 */
+ gpios-states = <0x1>;
+ states = <1100000 0x0
+ 1300000 0x1>;
+ };
+};
+
+&cpu0 {
+ cpu-supply = <&vdd_cpux>;
+};
+
+&codec {
+ status = "okay";
+};
+
+&emac {
+ phy-handle = <&int_mii_phy>;
+ phy-mode = "mii";
+ allwinner,leds-active-low;
+ status = "okay";
+};
+
+&hdmi {
+ status = "okay";
+};
+
+&hdmi_out {
+ hdmi_out_con: endpoint {
+ remote-endpoint = <&hdmi_con_in>;
+ };
+};
+
+&i2c1 {
+ status = "okay";
+};
diff --git a/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
new file mode 100644
index 00000000..eedd5da
--- /dev/null
+++ b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
@@ -0,0 +1,11 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+/*
+ * DTSI for Emlid Neutis N5 SoM.
+ *
+ * Copyright (C) 2019 Georgii Staroselskii <georgii.staroselskii@emlid.com>
+ */
+
+/dts-v1/;
+
+#include "sun8i-h3.dtsi"
+#include <arm/sunxi-h3-h5-emlid-neutis.dtsi>
--
2.7.4
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support
2019-11-06 14:03 ` [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support Georgii Staroselskii
@ 2019-11-12 12:15 ` Maxime Ripard
2019-11-12 14:52 ` Georgii Staroselskii
0 siblings, 1 reply; 5+ messages in thread
From: Maxime Ripard @ 2019-11-12 12:15 UTC (permalink / raw)
To: Georgii Staroselskii
Cc: mark.rutland, devicetree, linux-sunxi, wens, robh+dt, linux-arm-kernel
[-- Attachment #1.1: Type: text/plain, Size: 3087 bytes --]
Hi,
On Wed, Nov 06, 2019 at 05:03:18PM +0300, Georgii Staroselskii wrote:
> Emlid Neutis N5H3 is a version of Emlid Neutis SoM with H3 instead of H5
> inside.
>
> 6eeb4180d4b9 ("ARM: dts: sunxi: h3-h5: Add Bananapi M2+ v1.2 device")
> was used as reference.
>
> Signed-off-by: Georgii Staroselskii <georgii.staroselskii@emlid.com>
> ---
> arch/arm/boot/dts/Makefile | 1 +
> .../dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts | 61 ++++++++++++++++++++++
> arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi | 11 ++++
> 3 files changed, 73 insertions(+)
> create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
>
> diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> index 3f13b88..c997b0c 100644
> --- a/arch/arm/boot/dts/Makefile
> +++ b/arch/arm/boot/dts/Makefile
> @@ -1119,6 +1119,7 @@ dtb-$(CONFIG_MACH_SUN8I) += \
> sun8i-h3-orangepi-plus2e.dtb \
> sun8i-h3-orangepi-zero-plus2.dtb \
> sun8i-h3-rervision-dvk.dtb \
> + sun8i-h3-emlid-neutis-n5h3-devboard.dtb \
There's no need to duplicate the H3 in the name, we can just call it
sun8i-h3-emlid-neutis-n5-devboard.dts
Unless you expect some other boards named in a similar matter?
> sun8i-r16-bananapi-m2m.dtb \
> sun8i-r16-nintendo-nes-classic.dtb \
> sun8i-r16-nintendo-super-nes-classic.dtb \
> diff --git a/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> new file mode 100644
> index 00000000..3b68750
> --- /dev/null
> +++ b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> @@ -0,0 +1,61 @@
> +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
> +/*
> + * DTS for Emlid Neutis N5 Dev board.
> + *
> + * Copyright (C) 2019 Georgii Staroselskii <georgiii.staroselskii@emlid.com>
> + */
> +
> +/dts-v1/;
> +
> +#include "sun8i-h3-emlid-neutis-n5h3.dtsi"
> +
> +/ {
> + model = "Emlid Neutis N5H3 Developer board";
> + compatible = "emlid,neutis-n5h3-devboard",
> + "emlid,neutis-n5h3",
> + "allwinner,sun8i-h3";
Same remarks for the compatible, we have the h3 compatible here to
differentiate between the two.
You should also document this combination to
Documentation/devicetree/bindings/arm/sunxi.yaml.
> +
> + vdd_cpux: gpio-regulator {
> + compatible = "regulator-gpio";
> + regulator-name = "vdd-cpux";
> + regulator-type = "voltage";
> + regulator-boot-on;
> + regulator-always-on;
> + regulator-min-microvolt = <1100000>;
> + regulator-max-microvolt = <1300000>;
> + regulator-ramp-delay = <50>; /* 4ms */
> + gpios = <&r_pio 0 6 GPIO_ACTIVE_HIGH>; /* PL6 */
> + gpios-states = <0x1>;
> + states = <1100000 0x0
> + 1300000 0x1>;
While DTC outputs the same thing, and it works, you should make this
an array of 2 items of 2 cells, instead of a array of 1 item of 4
cells.
Like this: states = <1100000 0x0>, <1300000 0x1>;
While this doesn't change anything with DTC, other cases (like DT
validation) care about this.
Look good otherwise.
Maxime
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support
2019-11-12 12:15 ` Maxime Ripard
@ 2019-11-12 14:52 ` Georgii Staroselskii
0 siblings, 0 replies; 5+ messages in thread
From: Georgii Staroselskii @ 2019-11-12 14:52 UTC (permalink / raw)
To: Maxime Ripard
Cc: mark.rutland, linux-sunxi, georgii.staroselskii, wens, robh+dt,
linux-arm-kernel
On Tue, Nov 12, 2019 at 01:15:58PM +0100, Maxime Ripard wrote:
> Hi,
>
Hi!
> On Wed, Nov 06, 2019 at 05:03:18PM +0300, Georgii Staroselskii wrote:
> > Emlid Neutis N5H3 is a version of Emlid Neutis SoM with H3 instead of H5
> > inside.
> >
> > 6eeb4180d4b9 ("ARM: dts: sunxi: h3-h5: Add Bananapi M2+ v1.2 device")
> > was used as reference.
> >
> > Signed-off-by: Georgii Staroselskii <georgii.staroselskii@emlid.com>
> > ---
> > arch/arm/boot/dts/Makefile | 1 +
> > .../dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts | 61 ++++++++++++++++++++++
> > arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi | 11 ++++
> > 3 files changed, 73 insertions(+)
> > create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> > create mode 100644 arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3.dtsi
> >
> > diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
> > index 3f13b88..c997b0c 100644
> > --- a/arch/arm/boot/dts/Makefile
> > +++ b/arch/arm/boot/dts/Makefile
> > @@ -1119,6 +1119,7 @@ dtb-$(CONFIG_MACH_SUN8I) += \
> > sun8i-h3-orangepi-plus2e.dtb \
> > sun8i-h3-orangepi-zero-plus2.dtb \
> > sun8i-h3-rervision-dvk.dtb \
> > + sun8i-h3-emlid-neutis-n5h3-devboard.dtb \
>
> There's no need to duplicate the H3 in the name, we can just call it
>
> sun8i-h3-emlid-neutis-n5-devboard.dts
>
> Unless you expect some other boards named in a similar matter?
>
The thing is that Neutis N5H3 is the name of the board. So I guess it
makes sense to let this name be the part of the dts as well.
> > sun8i-r16-bananapi-m2m.dtb \
> > sun8i-r16-nintendo-nes-classic.dtb \
> > sun8i-r16-nintendo-super-nes-classic.dtb \
> > diff --git a/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> > new file mode 100644
> > index 00000000..3b68750
> > --- /dev/null
> > +++ b/arch/arm/boot/dts/sun8i-h3-emlid-neutis-n5h3-devboard.dts
> > @@ -0,0 +1,61 @@
> > +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
> > +/*
> > + * DTS for Emlid Neutis N5 Dev board.
> > + *
> > + * Copyright (C) 2019 Georgii Staroselskii <georgiii.staroselskii@emlid.com>
> > + */
> > +
> > +/dts-v1/;
> > +
> > +#include "sun8i-h3-emlid-neutis-n5h3.dtsi"
> > +
> > +/ {
> > + model = "Emlid Neutis N5H3 Developer board";
> > + compatible = "emlid,neutis-n5h3-devboard",
> > + "emlid,neutis-n5h3",
> > + "allwinner,sun8i-h3";
>
> Same remarks for the compatible, we have the h3 compatible here to
> differentiate between the two.
>
> You should also document this combination to
> Documentation/devicetree/bindings/arm/sunxi.yaml.
>
Thanks, will do.
> > +
> > + vdd_cpux: gpio-regulator {
> > + compatible = "regulator-gpio";
> > + regulator-name = "vdd-cpux";
> > + regulator-type = "voltage";
> > + regulator-boot-on;
> > + regulator-always-on;
> > + regulator-min-microvolt = <1100000>;
> > + regulator-max-microvolt = <1300000>;
> > + regulator-ramp-delay = <50>; /* 4ms */
> > + gpios = <&r_pio 0 6 GPIO_ACTIVE_HIGH>; /* PL6 */
> > + gpios-states = <0x1>;
> > + states = <1100000 0x0
> > + 1300000 0x1>;
>
> While DTC outputs the same thing, and it works, you should make this
> an array of 2 items of 2 cells, instead of a array of 1 item of 4
> cells.
>
> Like this: states = <1100000 0x0>, <1300000 0x1>;
>
> While this doesn't change anything with DTC, other cases (like DT
> validation) care about this.
>
Thank you!
> Look good otherwise.
I have spotted a couple of issues with the DTSI that I'm going to
address in V2.
Thanks for the review.
> Maxime
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-11-12 14:53 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-06 14:03 [PATCH 0/2] Neutis N5H3 support Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 1/2] arm: dts: allwinner: Split out non-SoC specific parts of Neutis N5 Georgii Staroselskii
2019-11-06 14:03 ` [PATCH 2/2] arm: dts: sunxi: Add Neutis N5H3 support Georgii Staroselskii
2019-11-12 12:15 ` Maxime Ripard
2019-11-12 14:52 ` Georgii Staroselskii
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).