diff mbox

[v5,12/12] ARM: dts: sun6i: hummingbird: Enable the onboard WiFi module

Message ID 1425988764-23618-14-git-send-email-wens@csie.org (mailing list archive)
State New, archived
Headers show

Commit Message

Chen-Yu Tsai March 10, 2015, 11:59 a.m. UTC
The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
The IC also takes a power enable signal via GPIO. This is supported
with the new power sequencing bindings.

The WiFi module supports out-of-band interrupt signaling via GPIO,
but this is buggy and not enabled yet.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
---
 arch/arm/boot/dts/sun6i-a31-hummingbird.dts | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

Comments

Maxime Ripard March 10, 2015, 9:32 p.m. UTC | #1
On Tue, Mar 10, 2015 at 07:59:24PM +0800, Chen-Yu Tsai wrote:
> The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
> WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
> The IC also takes a power enable signal via GPIO. This is supported
> with the new power sequencing bindings.
> 
> The WiFi module supports out-of-band interrupt signaling via GPIO,
> but this is buggy and not enabled yet.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>

There's two almost identical patches 12/12. Which one am I suppose to
apply?

Thanks!
Maxime
Chen-Yu Tsai March 11, 2015, 3:11 a.m. UTC | #2
On Wed, Mar 11, 2015 at 5:32 AM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> On Tue, Mar 10, 2015 at 07:59:24PM +0800, Chen-Yu Tsai wrote:
>> The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
>> WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
>> The IC also takes a power enable signal via GPIO. This is supported
>> with the new power sequencing bindings.
>>
>> The WiFi module supports out-of-band interrupt signaling via GPIO,
>> but this is buggy and not enabled yet.
>>
>> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
>
> There's two almost identical patches 12/12. Which one am I suppose to
> apply?

This one is the right one. I forgot to clear the patches after changing
the description. The "buggy" part in the description is probably not
needed. Hans explained that the SD resets have nothing to do with
interrupt handling.


ChenYu
Maxime Ripard March 11, 2015, 8:52 a.m. UTC | #3
On Wed, Mar 11, 2015 at 11:11:49AM +0800, Chen-Yu Tsai wrote:
> On Wed, Mar 11, 2015 at 5:32 AM, Maxime Ripard
> <maxime.ripard@free-electrons.com> wrote:
> > On Tue, Mar 10, 2015 at 07:59:24PM +0800, Chen-Yu Tsai wrote:
> >> The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
> >> WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
> >> The IC also takes a power enable signal via GPIO. This is supported
> >> with the new power sequencing bindings.
> >>
> >> The WiFi module supports out-of-band interrupt signaling via GPIO,
> >> but this is buggy and not enabled yet.
> >>
> >> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
> >
> > There's two almost identical patches 12/12. Which one am I suppose to
> > apply?
> 
> This one is the right one. I forgot to clear the patches after changing
> the description. The "buggy" part in the description is probably not
> needed. Hans explained that the SD resets have nothing to do with
> interrupt handling.

Just to be clear, you want the last sentence to be:

The WiFi module supports out-of-band interrupt signaling via GPIO, but
this is not enabled yet.

Right?

Maxime
Chen-Yu Tsai March 11, 2015, 9:08 a.m. UTC | #4
On Wed, Mar 11, 2015 at 4:52 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> On Wed, Mar 11, 2015 at 11:11:49AM +0800, Chen-Yu Tsai wrote:
>> On Wed, Mar 11, 2015 at 5:32 AM, Maxime Ripard
>> <maxime.ripard@free-electrons.com> wrote:
>> > On Tue, Mar 10, 2015 at 07:59:24PM +0800, Chen-Yu Tsai wrote:
>> >> The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
>> >> WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
>> >> The IC also takes a power enable signal via GPIO. This is supported
>> >> with the new power sequencing bindings.
>> >>
>> >> The WiFi module supports out-of-band interrupt signaling via GPIO,
>> >> but this is buggy and not enabled yet.
>> >>
>> >> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
>> >
>> > There's two almost identical patches 12/12. Which one am I suppose to
>> > apply?
>>
>> This one is the right one. I forgot to clear the patches after changing
>> the description. The "buggy" part in the description is probably not
>> needed. Hans explained that the SD resets have nothing to do with
>> interrupt handling.
>
> Just to be clear, you want the last sentence to be:
>
> The WiFi module supports out-of-band interrupt signaling via GPIO, but
> this is not enabled yet.
>
> Right?

That's right. Thanks.

ChenYu
Maxime Ripard March 11, 2015, 2:28 p.m. UTC | #5
On Wed, Mar 11, 2015 at 05:08:08PM +0800, Chen-Yu Tsai wrote:
> On Wed, Mar 11, 2015 at 4:52 PM, Maxime Ripard
> <maxime.ripard@free-electrons.com> wrote:
> > On Wed, Mar 11, 2015 at 11:11:49AM +0800, Chen-Yu Tsai wrote:
> >> On Wed, Mar 11, 2015 at 5:32 AM, Maxime Ripard
> >> <maxime.ripard@free-electrons.com> wrote:
> >> > On Tue, Mar 10, 2015 at 07:59:24PM +0800, Chen-Yu Tsai wrote:
> >> >> The Hummingbird A31 has an AMPAK AP6210 WiFi+Bluetooth module. The
> >> >> WiFi part is a BCM43362 IC connected to MMC1 in the A31 SoC via SDIO.
> >> >> The IC also takes a power enable signal via GPIO. This is supported
> >> >> with the new power sequencing bindings.
> >> >>
> >> >> The WiFi module supports out-of-band interrupt signaling via GPIO,
> >> >> but this is buggy and not enabled yet.
> >> >>
> >> >> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
> >> >
> >> > There's two almost identical patches 12/12. Which one am I suppose to
> >> > apply?
> >>
> >> This one is the right one. I forgot to clear the patches after changing
> >> the description. The "buggy" part in the description is probably not
> >> needed. Hans explained that the SD resets have nothing to do with
> >> interrupt handling.
> >
> > Just to be clear, you want the last sentence to be:
> >
> > The WiFi module supports out-of-band interrupt signaling via GPIO, but
> > this is not enabled yet.
> >
> > Right?
> 
> That's right. Thanks.

Ack. I just applied it without the buggy mention.

Thanks!
Maxime
diff mbox

Patch

diff --git a/arch/arm/boot/dts/sun6i-a31-hummingbird.dts b/arch/arm/boot/dts/sun6i-a31-hummingbird.dts
index d13c88c6509a..25a3ef49bb71 100644
--- a/arch/arm/boot/dts/sun6i-a31-hummingbird.dts
+++ b/arch/arm/boot/dts/sun6i-a31-hummingbird.dts
@@ -61,6 +61,11 @@ 
 	chosen {
 		bootargs = "earlyprintk console=ttyS0,115200";
 	};
+
+	wifi_pwrseq: wifi_pwrseq {
+		compatible = "mmc-pwrseq-simple";
+		reset-gpios = <&pio 6 10 GPIO_ACTIVE_LOW>; /* PG10 */
+	};
 };
 
 &ehci0 {
@@ -127,6 +132,16 @@ 
 	allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
 };
 
+&mmc1 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&mmc1_pins_a>, <&wifi_reset_pin_hummingbird>;
+	vmmc-supply = <&vcc_wifi>;
+	mmc-pwrseq = <&wifi_pwrseq>;
+	bus-width = <4>;
+	non-removable;
+	status = "okay";
+};
+
 &ohci0 {
 	status = "okay";
 };
@@ -138,6 +153,13 @@ 
 		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
 		allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
 	};
+
+	wifi_reset_pin_hummingbird: wifi_reset_pin@0 {
+		allwinner,pins = "PG10";
+		allwinner,function = "gpio_out";
+		allwinner,drive = <SUN4I_PINCTRL_10_MA>;
+		allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
+	};
 };
 
 &p2wi {