linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
@ 2016-07-09 20:21 Hans de Goede
  2016-07-09 20:21 ` [PATCH 2/4] ARM: dts: sun8i: Extend Orange Pi Plus dt to also handle the Plus 2E Hans de Goede
                   ` (3 more replies)
  0 siblings, 4 replies; 17+ messages in thread
From: Hans de Goede @ 2016-07-09 20:21 UTC (permalink / raw)
  To: linux-arm-kernel

There is a new Orange Pi PC Plus available now, rather then adding
yet another dts file for this variant, extend the existing
Orange Pi PC to support the sdio wifi and emmc found on this variant.

Downside of this approach is the following messages in dmesg when run
on the non Plus Orange Pi PC:

sunxi-mmc 1c10000.mmc: fatal err update clk timeout
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!

Note these are completely harmless and there is no adverse effect
to the functioning of the non Plus Orange Pi PC.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
 1 file changed, 39 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
index b8340f7..f9bf260 100644
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
@@ -49,11 +49,13 @@
 #include <dt-bindings/pinctrl/sun4i-a10.h>
 
 / {
-	model = "Xunlong Orange Pi PC";
+	model = "Xunlong Orange Pi PC / PC Plus";
 	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
 
 	aliases {
 		serial0 = &uart0;
+		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
+		ethernet1 = &rtl8189ftv;
 	};
 
 	chosen {
@@ -118,6 +120,42 @@
 	status = "okay";
 };
 
+/* Note only present on orangepi pc *plus* */
+&mmc1 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&mmc1_pins_a>;
+	vmmc-supply = <&reg_vcc3v3>;
+	bus-width = <4>;
+	non-removable;
+	status = "okay";
+
+	/*
+	 * Explicitly define the sdio device, so that we can add an ethernet
+	 * alias for it (which e.g. makes u-boot set a mac-address).
+	 */
+	rtl8189ftv: sdio_wifi at 1 {
+		reg = <1>;
+	};
+};
+
+/* Note only present on orangepi pc *plus* */
+&mmc2 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&mmc2_8bit_pins>;
+	vmmc-supply = <&reg_vcc3v3>;
+	bus-width = <8>;
+	non-removable;
+	cap-mmc-hw-reset;
+	status = "okay";
+};
+
+&mmc2_8bit_pins {
+	/* Increase drive strength for DDR modes */
+	allwinner,drive = <SUN4I_PINCTRL_40_MA>;
+	/* eMMC is missing pull-ups */
+	allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
+};
+
 &ohci1 {
 	status = "okay";
 };
-- 
2.7.4

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

* [PATCH 2/4] ARM: dts: sun8i: Extend Orange Pi Plus dt to also handle the Plus 2E
  2016-07-09 20:21 [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Hans de Goede
@ 2016-07-09 20:21 ` Hans de Goede
  2016-07-09 20:21 ` [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts Hans de Goede
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2016-07-09 20:21 UTC (permalink / raw)
  To: linux-arm-kernel

There is a new Orange Pi Plus 2E available now, rather then adding yet
another dts file for this variant, extend the existing Plus / Plus2 dt
to also support this variant.

The 2E goes from 4 to 3 USB ports and drops the sata connector, so it
no longer has a USB hub or an USB <-> sata bridge on the board.

This commit enables all 3 ehci and ohci controllers to support the 3
USB connectors which are now directly connected to the SoC.

Downside of this approach is 4 unused USB busses now showing up on
the original Plus / Plus 2.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts | 18 +++++++++++++++++-
 1 file changed, 17 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts
index b0cb417..28f74f6 100644
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-plus.dts
@@ -44,7 +44,7 @@
 #include "sun8i-h3-orangepi-2.dts"
 
 / {
-	model = "Xunlong Orange Pi Plus";
+	model = "Xunlong Orange Pi Plus / Plus 2 / Plus 2E";
 	compatible = "xunlong,orangepi-plus", "allwinner,sun8i-h3";
 
 	reg_usb3_vbus: usb3-vbus {
@@ -60,6 +60,10 @@
 	};
 };
 
+&ehci2 {
+	status = "okay";
+};
+
 &ehci3 {
 	status = "okay";
 };
@@ -81,6 +85,18 @@
 	allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
 };
 
+&ohci1 {
+	status = "okay";
+};
+
+&ohci2 {
+	status = "okay";
+};
+
+&ohci3 {
+	status = "okay";
+};
+
 &pio {
 	usb3_vbus_pin_a: usb3_vbus_pin at 0 {
 		allwinner,pins = "PG11";
-- 
2.7.4

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

* [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts
  2016-07-09 20:21 [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Hans de Goede
  2016-07-09 20:21 ` [PATCH 2/4] ARM: dts: sun8i: Extend Orange Pi Plus dt to also handle the Plus 2E Hans de Goede
@ 2016-07-09 20:21 ` Hans de Goede
  2016-07-28 18:20   ` Maxime Ripard
  2016-07-09 20:21 ` [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC Hans de Goede
  2016-07-13  8:45 ` [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Maxime Ripard
  3 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2016-07-09 20:21 UTC (permalink / raw)
  To: linux-arm-kernel

This will allow u-boot to fill in a mac-address for Orange Pi 2
variants which use an sdio wifi without an eeprom for the mac.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 arch/arm/boot/dts/sun8i-h3-orangepi-2.dts | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
index f93f5d1..f89fe00 100644
--- a/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-2.dts
@@ -54,6 +54,8 @@
 
 	aliases {
 		serial0 = &uart0;
+		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
+		ethernet1 = &rtl8189;
 	};
 
 	chosen {
@@ -131,6 +133,14 @@
 	bus-width = <4>;
 	non-removable;
 	status = "okay";
+
+	/*
+	 * Explicitly define the sdio device, so that we can add an ethernet
+	 * alias for it (which e.g. makes u-boot set a mac-address).
+	 */
+	rtl8189: sdio_wifi at 1 {
+		reg = <1>;
+	};
 };
 
 &pio {
-- 
2.7.4

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

* [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC
  2016-07-09 20:21 [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Hans de Goede
  2016-07-09 20:21 ` [PATCH 2/4] ARM: dts: sun8i: Extend Orange Pi Plus dt to also handle the Plus 2E Hans de Goede
  2016-07-09 20:21 ` [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts Hans de Goede
@ 2016-07-09 20:21 ` Hans de Goede
  2016-07-28 18:21   ` Maxime Ripard
  2016-07-13  8:45 ` [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Maxime Ripard
  3 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2016-07-09 20:21 UTC (permalink / raw)
  To: linux-arm-kernel

The Orange Pi Lite SBC is a small H3 based SBC, with 512MB RAM,
micro-sd slot, HDMI out, 2 USB-A connectors, 1 micro-USB connector,
sdio attached rtl8189ftv wifi and an ir receiver.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 arch/arm/boot/dts/Makefile                   |   1 +
 arch/arm/boot/dts/sun8i-h3-orangepi-lite.dts | 178 +++++++++++++++++++++++++++
 2 files changed, 179 insertions(+)
 create mode 100644 arch/arm/boot/dts/sun8i-h3-orangepi-lite.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 92eb004..0d60794 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -767,6 +767,7 @@ dtb-$(CONFIG_MACH_SUN8I) += \
 	sun8i-a83t-allwinner-h8homlet-v2.dtb \
 	sun8i-a83t-cubietruck-plus.dtb \
 	sun8i-h3-orangepi-2.dtb \
+	sun8i-h3-orangepi-lite.dtb \
 	sun8i-h3-orangepi-one.dtb \
 	sun8i-h3-orangepi-pc.dtb \
 	sun8i-h3-orangepi-plus.dtb \
diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-lite.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-lite.dts
new file mode 100644
index 0000000..ac71749
--- /dev/null
+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-lite.dts
@@ -0,0 +1,178 @@
+/*
+ * Copyright (C) 2016 Hans de Goede <hdegoede@redhat.com>
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License, or (at your option) any later version.
+ *
+ *     This file 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.
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use,
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+#include "sun8i-h3.dtsi"
+#include "sunxi-common-regulators.dtsi"
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/pinctrl/sun4i-a10.h>
+
+/ {
+	model = "Xunlong Orange Pi Lite";
+	compatible = "xunlong,orangepi-lite", "allwinner,sun8i-h3";
+
+	aliases {
+		/* The H3 emac is not used so the wifi is ethernet0 */
+		ethernet1 = &rtl8189ftv;
+		serial0 = &uart0;
+	};
+
+	chosen {
+		stdout-path = "serial0:115200n8";
+	};
+
+	leds {
+		compatible = "gpio-leds";
+		pinctrl-names = "default";
+		pinctrl-0 = <&leds_opc>, <&leds_r_opc>;
+
+		pwr_led {
+			label = "orangepi:green:pwr";
+			gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>;
+			default-state = "on";
+		};
+
+		status_led {
+			label = "orangepi:red:status";
+			gpios = <&pio 0 15 GPIO_ACTIVE_HIGH>;
+		};
+	};
+
+	r_gpio_keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&sw_r_opc>;
+
+		sw4 {
+			label = "sw4";
+			linux,code = <BTN_0>;
+			gpios = <&r_pio 0 3 GPIO_ACTIVE_LOW>;
+		};
+	};
+};
+
+&ehci1 {
+	status = "okay";
+};
+
+&ehci2 {
+	status = "okay";
+};
+
+&ir {
+	pinctrl-names = "default";
+	pinctrl-0 = <&ir_pins_a>;
+	status = "okay";
+};
+
+&mmc0 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin>;
+	vmmc-supply = <&reg_vcc3v3>;
+	bus-width = <4>;
+	cd-gpios = <&pio 5 6 GPIO_ACTIVE_HIGH>; /* PF6 */
+	cd-inverted;
+	status = "okay";
+};
+
+&mmc1 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&mmc1_pins_a>;
+	vmmc-supply = <&reg_vcc3v3>;
+	bus-width = <4>;
+	non-removable;
+	status = "okay";
+
+	/*
+	 * Explicitly define the sdio device, so that we can add an ethernet
+	 * alias for it (which e.g. makes u-boot set a mac-address).
+	 */
+	rtl8189ftv: sdio_wifi at 1 {
+		reg = <1>;
+	};
+};
+
+&ohci1 {
+	status = "okay";
+};
+
+&ohci2 {
+	status = "okay";
+};
+
+&pio {
+	leds_opc: led_pins at 0 {
+		allwinner,pins = "PA15";
+		allwinner,function = "gpio_out";
+		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+	};
+};
+
+&r_pio {
+	leds_r_opc: led_pins at 0 {
+		allwinner,pins = "PL10";
+		allwinner,function = "gpio_out";
+		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+	};
+
+	sw_r_opc: key_pins at 0 {
+		allwinner,pins = "PL3";
+		allwinner,function = "gpio_in";
+		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+	};
+};
+
+&uart0 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&uart0_pins_a>;
+	status = "okay";
+};
+
+&usbphy {
+	/* USB VBUS is always on */
+	status = "okay";
+};
-- 
2.7.4

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-09 20:21 [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Hans de Goede
                   ` (2 preceding siblings ...)
  2016-07-09 20:21 ` [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC Hans de Goede
@ 2016-07-13  8:45 ` Maxime Ripard
  2016-07-13 10:01   ` Hans de Goede
  3 siblings, 1 reply; 17+ messages in thread
From: Maxime Ripard @ 2016-07-13  8:45 UTC (permalink / raw)
  To: linux-arm-kernel

On Sat, Jul 09, 2016 at 10:21:55PM +0200, Hans de Goede wrote:
> There is a new Orange Pi PC Plus available now, rather then adding
> yet another dts file for this variant, extend the existing
> Orange Pi PC to support the sdio wifi and emmc found on this variant.
> 
> Downside of this approach is the following messages in dmesg when run
> on the non Plus Orange Pi PC:
> 
> sunxi-mmc 1c10000.mmc: fatal err update clk timeout
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!
> 
> Note these are completely harmless and there is no adverse effect
> to the functioning of the non Plus Orange Pi PC.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
>  1 file changed, 39 insertions(+), 1 deletion(-)
> 
> diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> index b8340f7..f9bf260 100644
> --- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> @@ -49,11 +49,13 @@
>  #include <dt-bindings/pinctrl/sun4i-a10.h>
>  
>  / {
> -	model = "Xunlong Orange Pi PC";
> +	model = "Xunlong Orange Pi PC / PC Plus";
>  	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
>  
>  	aliases {
>  		serial0 = &uart0;
> +		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
> +		ethernet1 = &rtl8189ftv;
>  	};
>  
>  	chosen {
> @@ -118,6 +120,42 @@
>  	status = "okay";
>  };
>  
> +/* Note only present on orangepi pc *plus* */
> +&mmc1 {
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&mmc1_pins_a>;
> +	vmmc-supply = <&reg_vcc3v3>;
> +	bus-width = <4>;
> +	non-removable;
> +	status = "okay";
> +
> +	/*
> +	 * Explicitly define the sdio device, so that we can add an ethernet
> +	 * alias for it (which e.g. makes u-boot set a mac-address).
> +	 */
> +	rtl8189ftv: sdio_wifi at 1 {
> +		reg = <1>;
> +	};
> +};

Nothing prevents you from including the orange pi pc dts, from the
orange pi plus dts.

It prevents the duplication you were trying to avoid, and it doesn't
create all those spurious errors and devices.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160713/eb497b96/attachment.sig>

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-13  8:45 ` [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Maxime Ripard
@ 2016-07-13 10:01   ` Hans de Goede
  2016-07-25  6:40     ` Maxime Ripard
  0 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2016-07-13 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 13-07-16 10:45, Maxime Ripard wrote:
> On Sat, Jul 09, 2016 at 10:21:55PM +0200, Hans de Goede wrote:
>> There is a new Orange Pi PC Plus available now, rather then adding
>> yet another dts file for this variant, extend the existing
>> Orange Pi PC to support the sdio wifi and emmc found on this variant.
>>
>> Downside of this approach is the following messages in dmesg when run
>> on the non Plus Orange Pi PC:
>>
>> sunxi-mmc 1c10000.mmc: fatal err update clk timeout
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!
>>
>> Note these are completely harmless and there is no adverse effect
>> to the functioning of the non Plus Orange Pi PC.
>>
>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>> ---
>>  arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
>>  1 file changed, 39 insertions(+), 1 deletion(-)
>>
>> diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>> index b8340f7..f9bf260 100644
>> --- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>> +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>> @@ -49,11 +49,13 @@
>>  #include <dt-bindings/pinctrl/sun4i-a10.h>
>>
>>  / {
>> -	model = "Xunlong Orange Pi PC";
>> +	model = "Xunlong Orange Pi PC / PC Plus";
>>  	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
>>
>>  	aliases {
>>  		serial0 = &uart0;
>> +		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
>> +		ethernet1 = &rtl8189ftv;
>>  	};
>>
>>  	chosen {
>> @@ -118,6 +120,42 @@
>>  	status = "okay";
>>  };
>>
>> +/* Note only present on orangepi pc *plus* */
>> +&mmc1 {
>> +	pinctrl-names = "default";
>> +	pinctrl-0 = <&mmc1_pins_a>;
>> +	vmmc-supply = <&reg_vcc3v3>;
>> +	bus-width = <4>;
>> +	non-removable;
>> +	status = "okay";
>> +
>> +	/*
>> +	 * Explicitly define the sdio device, so that we can add an ethernet
>> +	 * alias for it (which e.g. makes u-boot set a mac-address).
>> +	 */
>> +	rtl8189ftv: sdio_wifi at 1 {
>> +		reg = <1>;
>> +	};
>> +};
>
> Nothing prevents you from including the orange pi pc dts, from the
> orange pi plus dts.
>
> It prevents the duplication you were trying to avoid, and it doesn't
> create all those spurious errors and devices.

That would solve the copy paste problem on the kernel side, but that
would still mean adding a new u-boot defconfig for this, which means that
all the distro's which ship with prebuild u-boot binaries need to build
for yet another board, something which I would like to avoid.

Regards,

Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-13 10:01   ` Hans de Goede
@ 2016-07-25  6:40     ` Maxime Ripard
  2016-07-26 21:00       ` Hans de Goede
  2016-07-26 21:07       ` Hans de Goede
  0 siblings, 2 replies; 17+ messages in thread
From: Maxime Ripard @ 2016-07-25  6:40 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Wed, Jul 13, 2016 at 12:01:41PM +0200, Hans de Goede wrote:
> Hi,
> 
> On 13-07-16 10:45, Maxime Ripard wrote:
> >On Sat, Jul 09, 2016 at 10:21:55PM +0200, Hans de Goede wrote:
> >>There is a new Orange Pi PC Plus available now, rather then adding
> >>yet another dts file for this variant, extend the existing
> >>Orange Pi PC to support the sdio wifi and emmc found on this variant.
> >>
> >>Downside of this approach is the following messages in dmesg when run
> >>on the non Plus Orange Pi PC:
> >>
> >>sunxi-mmc 1c10000.mmc: fatal err update clk timeout
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
> >>sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!
> >>
> >>Note these are completely harmless and there is no adverse effect
> >>to the functioning of the non Plus Orange Pi PC.
> >>
> >>Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> >>---
> >> arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
> >> 1 file changed, 39 insertions(+), 1 deletion(-)
> >>
> >>diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> >>index b8340f7..f9bf260 100644
> >>--- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> >>+++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
> >>@@ -49,11 +49,13 @@
> >> #include <dt-bindings/pinctrl/sun4i-a10.h>
> >>
> >> / {
> >>-	model = "Xunlong Orange Pi PC";
> >>+	model = "Xunlong Orange Pi PC / PC Plus";
> >> 	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
> >>
> >> 	aliases {
> >> 		serial0 = &uart0;
> >>+		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
> >>+		ethernet1 = &rtl8189ftv;
> >> 	};
> >>
> >> 	chosen {
> >>@@ -118,6 +120,42 @@
> >> 	status = "okay";
> >> };
> >>
> >>+/* Note only present on orangepi pc *plus* */
> >>+&mmc1 {
> >>+	pinctrl-names = "default";
> >>+	pinctrl-0 = <&mmc1_pins_a>;
> >>+	vmmc-supply = <&reg_vcc3v3>;
> >>+	bus-width = <4>;
> >>+	non-removable;
> >>+	status = "okay";
> >>+
> >>+	/*
> >>+	 * Explicitly define the sdio device, so that we can add an ethernet
> >>+	 * alias for it (which e.g. makes u-boot set a mac-address).
> >>+	 */
> >>+	rtl8189ftv: sdio_wifi at 1 {
> >>+		reg = <1>;
> >>+	};
> >>+};
> >
> >Nothing prevents you from including the orange pi pc dts, from the
> >orange pi plus dts.
> >
> >It prevents the duplication you were trying to avoid, and it doesn't
> >create all those spurious errors and devices.
> 
> That would solve the copy paste problem on the kernel side, but that
> would still mean adding a new u-boot defconfig for this, which means that
> all the distro's which ship with prebuild u-boot binaries need to build
> for yet another board, something which I would like to avoid.

Still, registering devices that are not present on the board is not an
option.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160725/b9319e9a/attachment.sig>

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-25  6:40     ` Maxime Ripard
@ 2016-07-26 21:00       ` Hans de Goede
  2016-07-26 21:07       ` Hans de Goede
  1 sibling, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2016-07-26 21:00 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 07/25/2016 08:40 AM, Maxime Ripard wrote:
> Hi,
>
> On Wed, Jul 13, 2016 at 12:01:41PM +0200, Hans de Goede wrote:
>> Hi,
>>
>> On 13-07-16 10:45, Maxime Ripard wrote:
>>> On Sat, Jul 09, 2016 at 10:21:55PM +0200, Hans de Goede wrote:
>>>> There is a new Orange Pi PC Plus available now, rather then adding
>>>> yet another dts file for this variant, extend the existing
>>>> Orange Pi PC to support the sdio wifi and emmc found on this variant.
>>>>
>>>> Downside of this approach is the following messages in dmesg when run
>>>> on the non Plus Orange Pi PC:
>>>>
>>>> sunxi-mmc 1c10000.mmc: fatal err update clk timeout
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!
>>>>
>>>> Note these are completely harmless and there is no adverse effect
>>>> to the functioning of the non Plus Orange Pi PC.
>>>>
>>>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>>>> ---
>>>> arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
>>>> 1 file changed, 39 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> index b8340f7..f9bf260 100644
>>>> --- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> @@ -49,11 +49,13 @@
>>>> #include <dt-bindings/pinctrl/sun4i-a10.h>
>>>>
>>>> / {
>>>> -	model = "Xunlong Orange Pi PC";
>>>> +	model = "Xunlong Orange Pi PC / PC Plus";
>>>> 	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
>>>>
>>>> 	aliases {
>>>> 		serial0 = &uart0;
>>>> +		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
>>>> +		ethernet1 = &rtl8189ftv;
>>>> 	};
>>>>
>>>> 	chosen {
>>>> @@ -118,6 +120,42 @@
>>>> 	status = "okay";
>>>> };
>>>>
>>>> +/* Note only present on orangepi pc *plus* */
>>>> +&mmc1 {
>>>> +	pinctrl-names = "default";
>>>> +	pinctrl-0 = <&mmc1_pins_a>;
>>>> +	vmmc-supply = <&reg_vcc3v3>;
>>>> +	bus-width = <4>;
>>>> +	non-removable;
>>>> +	status = "okay";
>>>> +
>>>> +	/*
>>>> +	 * Explicitly define the sdio device, so that we can add an ethernet
>>>> +	 * alias for it (which e.g. makes u-boot set a mac-address).
>>>> +	 */
>>>> +	rtl8189ftv: sdio_wifi at 1 {
>>>> +		reg = <1>;
>>>> +	};
>>>> +};
>>>
>>> Nothing prevents you from including the orange pi pc dts, from the
>>> orange pi plus dts.
>>>
>>> It prevents the duplication you were trying to avoid, and it doesn't
>>> create all those spurious errors and devices.
>>
>> That would solve the copy paste problem on the kernel side, but that
>> would still mean adding a new u-boot defconfig for this, which means that
>> all the distro's which ship with prebuild u-boot binaries need to build
>> for yet another board, something which I would like to avoid.
>
> Still, registering devices that are not present on the board is not an
> option.

Ok, I'll send a new patch which adds a separate dts file for the Orange Pi
PC Plus.

Regards,

Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-25  6:40     ` Maxime Ripard
  2016-07-26 21:00       ` Hans de Goede
@ 2016-07-26 21:07       ` Hans de Goede
  2016-07-28 18:17         ` Maxime Ripard
  1 sibling, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2016-07-26 21:07 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 07/25/2016 08:40 AM, Maxime Ripard wrote:
> Hi,
>
> On Wed, Jul 13, 2016 at 12:01:41PM +0200, Hans de Goede wrote:
>> Hi,
>>
>> On 13-07-16 10:45, Maxime Ripard wrote:
>>> On Sat, Jul 09, 2016 at 10:21:55PM +0200, Hans de Goede wrote:
>>>> There is a new Orange Pi PC Plus available now, rather then adding
>>>> yet another dts file for this variant, extend the existing
>>>> Orange Pi PC to support the sdio wifi and emmc found on this variant.
>>>>
>>>> Downside of this approach is the following messages in dmesg when run
>>>> on the non Plus Orange Pi PC:
>>>>
>>>> sunxi-mmc 1c10000.mmc: fatal err update clk timeout
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 8, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 55, RTO !!
>>>> sunxi-mmc 1c11000.mmc: smc 2 err, cmd 1, RTO !!
>>>>
>>>> Note these are completely harmless and there is no adverse effect
>>>> to the functioning of the non Plus Orange Pi PC.
>>>>
>>>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>>>> ---
>>>> arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts | 40 +++++++++++++++++++++++++++++-
>>>> 1 file changed, 39 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> index b8340f7..f9bf260 100644
>>>> --- a/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> +++ b/arch/arm/boot/dts/sun8i-h3-orangepi-pc.dts
>>>> @@ -49,11 +49,13 @@
>>>> #include <dt-bindings/pinctrl/sun4i-a10.h>
>>>>
>>>> / {
>>>> -	model = "Xunlong Orange Pi PC";
>>>> +	model = "Xunlong Orange Pi PC / PC Plus";
>>>> 	compatible = "xunlong,orangepi-pc", "allwinner,sun8i-h3";
>>>>
>>>> 	aliases {
>>>> 		serial0 = &uart0;
>>>> +		/* ethernet0 is the H3 emac, defined in sun8i-h3.dtsi */
>>>> +		ethernet1 = &rtl8189ftv;
>>>> 	};
>>>>
>>>> 	chosen {
>>>> @@ -118,6 +120,42 @@
>>>> 	status = "okay";
>>>> };
>>>>
>>>> +/* Note only present on orangepi pc *plus* */
>>>> +&mmc1 {
>>>> +	pinctrl-names = "default";
>>>> +	pinctrl-0 = <&mmc1_pins_a>;
>>>> +	vmmc-supply = <&reg_vcc3v3>;
>>>> +	bus-width = <4>;
>>>> +	non-removable;
>>>> +	status = "okay";
>>>> +
>>>> +	/*
>>>> +	 * Explicitly define the sdio device, so that we can add an ethernet
>>>> +	 * alias for it (which e.g. makes u-boot set a mac-address).
>>>> +	 */
>>>> +	rtl8189ftv: sdio_wifi at 1 {
>>>> +		reg = <1>;
>>>> +	};
>>>> +};
>>>
>>> Nothing prevents you from including the orange pi pc dts, from the
>>> orange pi plus dts.
>>>
>>> It prevents the duplication you were trying to avoid, and it doesn't
>>> create all those spurious errors and devices.
>>
>> That would solve the copy paste problem on the kernel side, but that
>> would still mean adding a new u-boot defconfig for this, which means that
>> all the distro's which ship with prebuild u-boot binaries need to build
>> for yet another board, something which I would like to avoid.
>
> Still, registering devices that are not present on the board is not an
> option.

Ok, new version send.

What about the other 3 patches in this series ?

Regards,

Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-26 21:07       ` Hans de Goede
@ 2016-07-28 18:17         ` Maxime Ripard
  2016-07-28 20:36           ` Hans de Goede
  0 siblings, 1 reply; 17+ messages in thread
From: Maxime Ripard @ 2016-07-28 18:17 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Hans,

On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
> >>>Nothing prevents you from including the orange pi pc dts, from the
> >>>orange pi plus dts.
> >>>
> >>>It prevents the duplication you were trying to avoid, and it doesn't
> >>>create all those spurious errors and devices.
> >>
> >>That would solve the copy paste problem on the kernel side, but that
> >>would still mean adding a new u-boot defconfig for this, which means that
> >>all the distro's which ship with prebuild u-boot binaries need to build
> >>for yet another board, something which I would like to avoid.
> >
> >Still, registering devices that are not present on the board is not an
> >option.
> 
> Ok, new version send.
> 
> What about the other 3 patches in this series ?

I guess the same comment applies for patch 2.

I'll look at the two others.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160728/24e766f1/attachment.sig>

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

* [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts
  2016-07-09 20:21 ` [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts Hans de Goede
@ 2016-07-28 18:20   ` Maxime Ripard
  0 siblings, 0 replies; 17+ messages in thread
From: Maxime Ripard @ 2016-07-28 18:20 UTC (permalink / raw)
  To: linux-arm-kernel

On Sat, Jul 09, 2016 at 10:21:57PM +0200, Hans de Goede wrote:
> This will allow u-boot to fill in a mac-address for Orange Pi 2
> variants which use an sdio wifi without an eeprom for the mac.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Applied, thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160728/8d58c907/attachment.sig>

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

* [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC
  2016-07-09 20:21 ` [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC Hans de Goede
@ 2016-07-28 18:21   ` Maxime Ripard
  0 siblings, 0 replies; 17+ messages in thread
From: Maxime Ripard @ 2016-07-28 18:21 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Sat, Jul 09, 2016 at 10:21:58PM +0200, Hans de Goede wrote:
> +	aliases {
> +		/* The H3 emac is not used so the wifi is ethernet0 */
> +		ethernet1 = &rtl8189ftv;

There's a mismatch between your comment and what you did here.

The rest is fine though.

Thanks!
Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160728/94f42fe9/attachment.sig>

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-28 18:17         ` Maxime Ripard
@ 2016-07-28 20:36           ` Hans de Goede
  2016-08-07 14:25             ` Hans de Goede
  0 siblings, 1 reply; 17+ messages in thread
From: Hans de Goede @ 2016-07-28 20:36 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 28-07-16 20:17, Maxime Ripard wrote:
> Hi Hans,
>
> On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
>>>>> Nothing prevents you from including the orange pi pc dts, from the
>>>>> orange pi plus dts.
>>>>>
>>>>> It prevents the duplication you were trying to avoid, and it doesn't
>>>>> create all those spurious errors and devices.
>>>>
>>>> That would solve the copy paste problem on the kernel side, but that
>>>> would still mean adding a new u-boot defconfig for this, which means that
>>>> all the distro's which ship with prebuild u-boot binaries need to build
>>>> for yet another board, something which I would like to avoid.
>>>
>>> Still, registering devices that are not present on the board is not an
>>> option.
>>
>> Ok, new version send.
>>
>> What about the other 3 patches in this series ?
>
> I guess the same comment applies for patch 2.

The difference is that there really is no harm at all from
enabling the extra usb controllers used on the plus 2e
on the plus and plus 2 as well, no errors, no nothing, they
just sit their as usb controllers without an usb device plugged
in. But if you insist I can do a separate dts + u-boot defconfig
for the plus 2e as well (but I would rather not).

Regards,

Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-07-28 20:36           ` Hans de Goede
@ 2016-08-07 14:25             ` Hans de Goede
  2016-08-26 18:45               ` Hans de Goede
  2016-08-31 16:28               ` Maxime Ripard
  0 siblings, 2 replies; 17+ messages in thread
From: Hans de Goede @ 2016-08-07 14:25 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 28-07-16 22:36, Hans de Goede wrote:
> Hi,
>
> On 28-07-16 20:17, Maxime Ripard wrote:
>> Hi Hans,
>>
>> On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
>>>>>> Nothing prevents you from including the orange pi pc dts, from the
>>>>>> orange pi plus dts.
>>>>>>
>>>>>> It prevents the duplication you were trying to avoid, and it doesn't
>>>>>> create all those spurious errors and devices.
>>>>>
>>>>> That would solve the copy paste problem on the kernel side, but that
>>>>> would still mean adding a new u-boot defconfig for this, which means that
>>>>> all the distro's which ship with prebuild u-boot binaries need to build
>>>>> for yet another board, something which I would like to avoid.
>>>>
>>>> Still, registering devices that are not present on the board is not an
>>>> option.
>>>
>>> Ok, new version send.
>>>
>>> What about the other 3 patches in this series ?
>>
>> I guess the same comment applies for patch 2.
>
> The difference is that there really is no harm at all from
> enabling the extra usb controllers used on the plus 2e
> on the plus and plus 2 as well, no errors, no nothing, they
> just sit their as usb controllers without an usb device plugged
> in. But if you insist I can do a separate dts + u-boot defconfig
> for the plus 2e as well (but I would rather not).

Ping, what is the verdict on this, are you ok with the patch or
do you want me to create a separate dts file for the Orange Pi
Plus 2E, note that doing so is going to be highly confusing to
users, there are 3 plus boards:

Orange Pi Plus
Orange Pi Plus 2   (same as the original plus but with 2G RAM, uses same u-boot defconfig / dts file)
Orange Pi Plus 2E  (drops the USB-hub instead using all 3 host controllers)

So if you insist on a separate dts for the 2E, we get a case where
the user with the "2" needs to guess which config to use, sure we
can document this, but who is going to read the docs ?

Regards,

Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-08-07 14:25             ` Hans de Goede
@ 2016-08-26 18:45               ` Hans de Goede
  2016-08-31 16:28               ` Maxime Ripard
  1 sibling, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2016-08-26 18:45 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 07-08-16 16:25, Hans de Goede wrote:
> Hi,
>
> On 28-07-16 22:36, Hans de Goede wrote:
>> Hi,
>>
>> On 28-07-16 20:17, Maxime Ripard wrote:
>>> Hi Hans,
>>>
>>> On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
>>>>>>> Nothing prevents you from including the orange pi pc dts, from the
>>>>>>> orange pi plus dts.
>>>>>>>
>>>>>>> It prevents the duplication you were trying to avoid, and it doesn't
>>>>>>> create all those spurious errors and devices.
>>>>>>
>>>>>> That would solve the copy paste problem on the kernel side, but that
>>>>>> would still mean adding a new u-boot defconfig for this, which means that
>>>>>> all the distro's which ship with prebuild u-boot binaries need to build
>>>>>> for yet another board, something which I would like to avoid.
>>>>>
>>>>> Still, registering devices that are not present on the board is not an
>>>>> option.
>>>>
>>>> Ok, new version send.
>>>>
>>>> What about the other 3 patches in this series ?
>>>
>>> I guess the same comment applies for patch 2.
>>
>> The difference is that there really is no harm at all from
>> enabling the extra usb controllers used on the plus 2e
>> on the plus and plus 2 as well, no errors, no nothing, they
>> just sit their as usb controllers without an usb device plugged
>> in. But if you insist I can do a separate dts + u-boot defconfig
>> for the plus 2e as well (but I would rather not).
>
> Ping, what is the verdict on this, are you ok with the patch or
> do you want me to create a separate dts file for the Orange Pi
> Plus 2E, note that doing so is going to be highly confusing to
> users, there are 3 plus boards:
>
> Orange Pi Plus
> Orange Pi Plus 2   (same as the original plus but with 2G RAM, uses same u-boot defconfig / dts file)
> Orange Pi Plus 2E  (drops the USB-hub instead using all 3 host controllers)
>
> So if you insist on a separate dts for the 2E, we get a case where
> the user with the "2" needs to guess which config to use, sure we
> can document this, but who is going to read the docs ?

Ping can you please make a call on this, I'm ok with doing this
either way (*), but please lets just make a call and move forward.

Regards,

Hans


*) With a preference for a single dts file for all plus boards as explained
in my previous email
>
> Regards,
>
> Hans

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-08-07 14:25             ` Hans de Goede
  2016-08-26 18:45               ` Hans de Goede
@ 2016-08-31 16:28               ` Maxime Ripard
  2016-09-03 11:05                 ` Hans de Goede
  1 sibling, 1 reply; 17+ messages in thread
From: Maxime Ripard @ 2016-08-31 16:28 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Hans,

Sorry for the slow response, it was burried in my inbox.

On Sun, Aug 07, 2016 at 04:25:20PM +0200, Hans de Goede wrote:
> Hi,
> 
> On 28-07-16 22:36, Hans de Goede wrote:
> >Hi,
> >
> >On 28-07-16 20:17, Maxime Ripard wrote:
> >>Hi Hans,
> >>
> >>On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
> >>>>>>Nothing prevents you from including the orange pi pc dts, from the
> >>>>>>orange pi plus dts.
> >>>>>>
> >>>>>>It prevents the duplication you were trying to avoid, and it doesn't
> >>>>>>create all those spurious errors and devices.
> >>>>>
> >>>>>That would solve the copy paste problem on the kernel side, but that
> >>>>>would still mean adding a new u-boot defconfig for this, which means that
> >>>>>all the distro's which ship with prebuild u-boot binaries need to build
> >>>>>for yet another board, something which I would like to avoid.
> >>>>
> >>>>Still, registering devices that are not present on the board is not an
> >>>>option.
> >>>
> >>>Ok, new version send.
> >>>
> >>>What about the other 3 patches in this series ?
> >>
> >>I guess the same comment applies for patch 2.
> >
> >The difference is that there really is no harm at all from
> >enabling the extra usb controllers used on the plus 2e
> >on the plus and plus 2 as well, no errors, no nothing, they
> >just sit their as usb controllers without an usb device plugged
> >in. But if you insist I can do a separate dts + u-boot defconfig
> >for the plus 2e as well (but I would rather not).
> 
> Ping, what is the verdict on this, are you ok with the patch or
> do you want me to create a separate dts file for the Orange Pi
> Plus 2E, note that doing so is going to be highly confusing to
> users, there are 3 plus boards:

I still believe that enabling clocks, regulators, claiming pins for
device that are entirely unused on the board is not ok.

> Orange Pi Plus
> Orange Pi Plus 2   (same as the original plus but with 2G RAM, uses same u-boot defconfig / dts file)

Yes, that makes sense.

> Orange Pi Plus 2E  (drops the USB-hub instead using all 3 host controllers)

However, I'm really worried about this one. If we go this way, there's
essentially no going back. If for some reason we want to have a
separate DT in the future (some unforeseen quirk to apply, pin to
setup that conflicts on another board, etc.), we will be completely
screwed because our users will be expecting to use the common DT,
while it wouldn't be wise anymore.

The other way around is much easier to deal with.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20160831/88e23c44/attachment.sig>

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

* [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus
  2016-08-31 16:28               ` Maxime Ripard
@ 2016-09-03 11:05                 ` Hans de Goede
  0 siblings, 0 replies; 17+ messages in thread
From: Hans de Goede @ 2016-09-03 11:05 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On 31-08-16 18:28, Maxime Ripard wrote:
> Hi Hans,
>
> Sorry for the slow response, it was burried in my inbox.
>
> On Sun, Aug 07, 2016 at 04:25:20PM +0200, Hans de Goede wrote:
>> Hi,
>>
>> On 28-07-16 22:36, Hans de Goede wrote:
>>> Hi,
>>>
>>> On 28-07-16 20:17, Maxime Ripard wrote:
>>>> Hi Hans,
>>>>
>>>> On Tue, Jul 26, 2016 at 11:07:23PM +0200, Hans de Goede wrote:
>>>>>>>> Nothing prevents you from including the orange pi pc dts, from the
>>>>>>>> orange pi plus dts.
>>>>>>>>
>>>>>>>> It prevents the duplication you were trying to avoid, and it doesn't
>>>>>>>> create all those spurious errors and devices.
>>>>>>>
>>>>>>> That would solve the copy paste problem on the kernel side, but that
>>>>>>> would still mean adding a new u-boot defconfig for this, which means that
>>>>>>> all the distro's which ship with prebuild u-boot binaries need to build
>>>>>>> for yet another board, something which I would like to avoid.
>>>>>>
>>>>>> Still, registering devices that are not present on the board is not an
>>>>>> option.
>>>>>
>>>>> Ok, new version send.
>>>>>
>>>>> What about the other 3 patches in this series ?
>>>>
>>>> I guess the same comment applies for patch 2.
>>>
>>> The difference is that there really is no harm at all from
>>> enabling the extra usb controllers used on the plus 2e
>>> on the plus and plus 2 as well, no errors, no nothing, they
>>> just sit their as usb controllers without an usb device plugged
>>> in. But if you insist I can do a separate dts + u-boot defconfig
>>> for the plus 2e as well (but I would rather not).
>>
>> Ping, what is the verdict on this, are you ok with the patch or
>> do you want me to create a separate dts file for the Orange Pi
>> Plus 2E, note that doing so is going to be highly confusing to
>> users, there are 3 plus boards:
>
> I still believe that enabling clocks, regulators, claiming pins for
> device that are entirely unused on the board is not ok.
>
>> Orange Pi Plus
>> Orange Pi Plus 2   (same as the original plus but with 2G RAM, uses same u-boot defconfig / dts file)
>
> Yes, that makes sense.
>
>> Orange Pi Plus 2E  (drops the USB-hub instead using all 3 host controllers)
>
> However, I'm really worried about this one. If we go this way, there's
> essentially no going back. If for some reason we want to have a
> separate DT in the future (some unforeseen quirk to apply, pin to
> setup that conflicts on another board, etc.), we will be completely
> screwed because our users will be expecting to use the common DT,
> while it wouldn't be wise anymore.
>
> The other way around is much easier to deal with.

OK, fair enough, one patch to add a separate dts file for
the plus 2e coming up.

Regards,

Hans

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

end of thread, other threads:[~2016-09-03 11:05 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-09 20:21 [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Hans de Goede
2016-07-09 20:21 ` [PATCH 2/4] ARM: dts: sun8i: Extend Orange Pi Plus dt to also handle the Plus 2E Hans de Goede
2016-07-09 20:21 ` [PATCH 3/4] ARM: dts: sun8i: Add ethernet1 alias to Orange Pi 2 dts Hans de Goede
2016-07-28 18:20   ` Maxime Ripard
2016-07-09 20:21 ` [PATCH 4/4] ARM: dts: sun8i: Add dts file for the Orange Pi Lite SBC Hans de Goede
2016-07-28 18:21   ` Maxime Ripard
2016-07-13  8:45 ` [PATCH 1/4] ARM: dts: sun8i: Extend Orange Pi PC dt to also handle the PC Plus Maxime Ripard
2016-07-13 10:01   ` Hans de Goede
2016-07-25  6:40     ` Maxime Ripard
2016-07-26 21:00       ` Hans de Goede
2016-07-26 21:07       ` Hans de Goede
2016-07-28 18:17         ` Maxime Ripard
2016-07-28 20:36           ` Hans de Goede
2016-08-07 14:25             ` Hans de Goede
2016-08-26 18:45               ` Hans de Goede
2016-08-31 16:28               ` Maxime Ripard
2016-09-03 11:05                 ` Hans de Goede

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