diff mbox series

[v4,5/7] ARM: dts: sun8i: v40: bananapi-m2-berry: Add Bluetooth device node

Message ID 1555600282-9405-6-git-send-email-pgreco@centosproject.org (mailing list archive)
State New, archived
Headers show
Series ARM: dts: sun8i: v40 Rewrite BPi M2 Berry DTS based on BPi M2 Ultra | expand

Commit Message

Pablo Sebastián Greco April 18, 2019, 3:11 p.m. UTC
Since the bananapi-m2-ultra and the bananapi-m2-berry have the same
WiFi/Bluetooth, add the required nodes to the bananapi-m2-berry.

Signed-off-by: Pablo Greco <pgreco@centosproject.org>
---
 arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts | 26 +++++++++++++++++++++++
 1 file changed, 26 insertions(+)

Comments

Maxime Ripard April 18, 2019, 3:56 p.m. UTC | #1
On Thu, Apr 18, 2019 at 12:11:20PM -0300, Pablo Greco wrote:
> Since the bananapi-m2-ultra and the bananapi-m2-berry have the same
> WiFi/Bluetooth, add the required nodes to the bananapi-m2-berry.
>
> Signed-off-by: Pablo Greco <pgreco@centosproject.org>
> ---
>  arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts | 26 +++++++++++++++++++++++
>  1 file changed, 26 insertions(+)
>
> diff --git a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> index 78f4a1a..3d0bb7e 100644
> --- a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> +++ b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> @@ -96,6 +96,8 @@
>  	wifi_pwrseq: wifi_pwrseq {
>  		compatible = "mmc-pwrseq-simple";
>  		reset-gpios = <&pio 6 10 GPIO_ACTIVE_LOW>; /* PG10 WIFI_EN */
> +		clocks = <&ccu CLK_OUTA>;
> +		clock-names = "ext_clock";
>  	};
>  };
>
> @@ -171,6 +173,11 @@
>  	status = "okay";
>  };
>
> +&pio {
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&clk_out_a_pin>;
> +};
> +

I'm not sure you answered my question about why that is needed?

Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Pablo Sebastián Greco April 18, 2019, 4:14 p.m. UTC | #2
El 18/4/19 a las 12:56, Maxime Ripard escribió:
> On Thu, Apr 18, 2019 at 12:11:20PM -0300, Pablo Greco wrote:
>> Since the bananapi-m2-ultra and the bananapi-m2-berry have the same
>> WiFi/Bluetooth, add the required nodes to the bananapi-m2-berry.
>>
>> Signed-off-by: Pablo Greco <pgreco@centosproject.org>
>> ---
>>   arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts | 26 +++++++++++++++++++++++
>>   1 file changed, 26 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
>> index 78f4a1a..3d0bb7e 100644
>> --- a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
>> +++ b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
>> @@ -96,6 +96,8 @@
>>   	wifi_pwrseq: wifi_pwrseq {
>>   		compatible = "mmc-pwrseq-simple";
>>   		reset-gpios = <&pio 6 10 GPIO_ACTIVE_LOW>; /* PG10 WIFI_EN */
>> +		clocks = <&ccu CLK_OUTA>;
>> +		clock-names = "ext_clock";
>>   	};
>>   };
>>
>> @@ -171,6 +173,11 @@
>>   	status = "okay";
>>   };
>>
>> +&pio {
>> +	pinctrl-names = "default";
>> +	pinctrl-0 = <&clk_out_a_pin>;
>> +};
>> +
> I'm not sure you answered my question about why that is needed?
Because it is the same case as 
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/arch/arm/boot/dts/sun8i-r40-bananapi-m2-ultra.dts?id=1e5f1db4ccd8348a21da55bff82f4263000879ef
I can repeat that info in this commit log
> Maxime
>
> --
> Maxime Ripard, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com
>
>
Pablo.
Maxime Ripard April 23, 2019, 4:12 p.m. UTC | #3
On Thu, Apr 18, 2019 at 01:14:35PM -0300, Pablo Sebastián Greco wrote:
>
> El 18/4/19 a las 12:56, Maxime Ripard escribió:
> > On Thu, Apr 18, 2019 at 12:11:20PM -0300, Pablo Greco wrote:
> > > Since the bananapi-m2-ultra and the bananapi-m2-berry have the same
> > > WiFi/Bluetooth, add the required nodes to the bananapi-m2-berry.
> > >
> > > Signed-off-by: Pablo Greco <pgreco@centosproject.org>
> > > ---
> > >   arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts | 26 +++++++++++++++++++++++
> > >   1 file changed, 26 insertions(+)
> > >
> > > diff --git a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> > > index 78f4a1a..3d0bb7e 100644
> > > --- a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> > > +++ b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
> > > @@ -96,6 +96,8 @@
> > >   	wifi_pwrseq: wifi_pwrseq {
> > >   		compatible = "mmc-pwrseq-simple";
> > >   		reset-gpios = <&pio 6 10 GPIO_ACTIVE_LOW>; /* PG10 WIFI_EN */
> > > +		clocks = <&ccu CLK_OUTA>;
> > > +		clock-names = "ext_clock";
> > >   	};
> > >   };
> > >
> > > @@ -171,6 +173,11 @@
> > >   	status = "okay";
> > >   };
> > >
> > > +&pio {
> > > +	pinctrl-names = "default";
> > > +	pinctrl-0 = <&clk_out_a_pin>;
> > > +};
> > > +
> > I'm not sure you answered my question about why that is needed?
> Because it is the same case as https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/arch/arm/boot/dts/sun8i-r40-bananapi-m2-ultra.dts?id=1e5f1db4ccd8348a21da55bff82f4263000879ef
> I can repeat that info in this commit log

Yes, please.

Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
index 78f4a1a..3d0bb7e 100644
--- a/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
+++ b/arch/arm/boot/dts/sun8i-v40-bananapi-m2-berry.dts
@@ -96,6 +96,8 @@ 
 	wifi_pwrseq: wifi_pwrseq {
 		compatible = "mmc-pwrseq-simple";
 		reset-gpios = <&pio 6 10 GPIO_ACTIVE_LOW>; /* PG10 WIFI_EN */
+		clocks = <&ccu CLK_OUTA>;
+		clock-names = "ext_clock";
 	};
 };
 
@@ -171,6 +173,11 @@ 
 	status = "okay";
 };
 
+&pio {
+	pinctrl-names = "default";
+	pinctrl-0 = <&clk_out_a_pin>;
+};
+
 &reg_aldo2 {
 	regulator-always-on;
 	regulator-min-microvolt = <2500000>;
@@ -268,6 +275,25 @@ 
 	status = "okay";
 };
 
+&uart3 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&uart3_pg_pins>, <&uart3_rts_cts_pg_pins>;
+	uart-has-rtscts;
+	status = "okay";
+
+	bluetooth {
+		compatible = "brcm,bcm43438-bt";
+		clocks = <&ccu CLK_OUTA>;
+		clock-names = "lpo";
+		vbat-supply = <&reg_dldo2>;
+		vddio-supply = <&reg_dldo1>;
+		device-wakeup-gpios = <&pio 6 11 GPIO_ACTIVE_HIGH>; /* PG11 */
+		/* TODO host wake line connected to PMIC GPIO pins */
+		shutdown-gpios = <&pio 7 12 GPIO_ACTIVE_HIGH>; /* PH12 */
+		max-speed = <1500000>;
+	};
+};
+
 &usbphy {
 	usb1_vbus-supply = <&reg_vcc5v0>;
 	status = "okay";