[v3,4/4] ARM: dts: bcm2837-rpi-3-b: add GPIO expander
diff mbox

Message ID 8ba2147dc08bb50a65b49ca2142f7710e1635d20.1516105893.git.baruch@tkos.co.il
State New, archived
Headers show

Commit Message

Baruch Siach Jan. 16, 2018, 12:45 p.m. UTC
Add a description of the RPi3 GPIO expander that the VC4 firmware controls.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
---
v3:
  * List GPIO names one per line.

v2:
  * Move GPIO expander node out of the soc container
  * Rename compatible string
  * Add gpio-line-names property
---
 arch/arm/boot/dts/bcm2837-rpi-3-b.dts | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

Comments

Stefan Wahren Jan. 17, 2018, 8:30 a.m. UTC | #1
Hi Linus,
hi Eric,


Am 16.01.2018 um 13:45 schrieb Baruch Siach:
> Add a description of the RPi3 GPIO expander that the VC4 firmware controls.
>
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> ---
> v3:
>    * List GPIO names one per line.
>
> v2:
>    * Move GPIO expander node out of the soc container
>    * Rename compatible string
>    * Add gpio-line-names property
> ---
>   arch/arm/boot/dts/bcm2837-rpi-3-b.dts | 16 ++++++++++++++++
>   1 file changed, 16 insertions(+)
>
> diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
> index b44b3b5af00d..8cd93425ffe3 100644
> --- a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
> +++ b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
> @@ -23,6 +23,22 @@
>   			gpios = <&gpio 47 0>;
>   		};
>   	};

i noticed that this patch conflicts with my patch ("ARM: dts: bcm283x: 
Use GPIO polarity defines consistently") in linux-next.

How should we proceed?

> +
> +	expgpio: gpio-expander {
> +		compatible = "raspberrypi,firmware-gpio";
> +		gpio-controller;
> +		#gpio-cells = <2>;
> +		firmware = <&firmware>;
> +		gpio-line-names = "BT_ON",
> +				  "WL_ON",
> +				  "STATUS_LED",
> +				  "LAN_RUN",
> +				  "HPD_N",
> +				  "CAM_GPIO0",
> +				  "CAM_GPIO1",
> +				  "PWR_LOW_N";
> +		status = "okay";
> +	};
>   };
>   
>   /* uart0 communicates with the BT module */
Linus Walleij Jan. 17, 2018, 9:39 a.m. UTC | #2
On Wed, Jan 17, 2018 at 9:30 AM, Stefan Wahren <stefan.wahren@i2se.com> wrote:

> Hi Linus,
> hi Eric,
>
>
> Am 16.01.2018 um 13:45 schrieb Baruch Siach:
>>
>> Add a description of the RPi3 GPIO expander that the VC4 firmware
>> controls.
>>
>> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>> ---
>> v3:
>>    * List GPIO names one per line.
>>
>> v2:
>>    * Move GPIO expander node out of the soc container
>>    * Rename compatible string
>>    * Add gpio-line-names property
>> ---
>>   arch/arm/boot/dts/bcm2837-rpi-3-b.dts | 16 ++++++++++++++++
>>   1 file changed, 16 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
>> b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
>> index b44b3b5af00d..8cd93425ffe3 100644
>> --- a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
>> +++ b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
>> @@ -23,6 +23,22 @@
>>                         gpios = <&gpio 47 0>;
>>                 };
>>         };
>
>
> i noticed that this patch conflicts with my patch ("ARM: dts: bcm283x: Use
> GPIO polarity defines consistently") in linux-next.
>
> How should we proceed?

All DTS patches shall be merged through ARM SoC so the conflict should
be resolved by whoever sends the pull requests to ARM SoC before
sending the pull request.

I think these patches will be for the next kernel anyways, unless Torvalds
think we should have an -rc9 this time (because of all the meltdowns and
spectres etc you know).

Yours,
Linus Walleij
Stefan Wahren Jan. 19, 2018, 6:52 p.m. UTC | #3
> Baruch Siach <baruch@tkos.co.il> hat am 16. Januar 2018 um 13:45 geschrieben:
> 
> 
> Add a description of the RPi3 GPIO expander that the VC4 firmware controls.
> 
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>

Acked-by: Stefan Wahren <stefan.wahren@i2se.com>

Patch
diff mbox

diff --git a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
index b44b3b5af00d..8cd93425ffe3 100644
--- a/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
+++ b/arch/arm/boot/dts/bcm2837-rpi-3-b.dts
@@ -23,6 +23,22 @@ 
 			gpios = <&gpio 47 0>;
 		};
 	};
+
+	expgpio: gpio-expander {
+		compatible = "raspberrypi,firmware-gpio";
+		gpio-controller;
+		#gpio-cells = <2>;
+		firmware = <&firmware>;
+		gpio-line-names = "BT_ON",
+				  "WL_ON",
+				  "STATUS_LED",
+				  "LAN_RUN",
+				  "HPD_N",
+				  "CAM_GPIO0",
+				  "CAM_GPIO1",
+				  "PWR_LOW_N";
+		status = "okay";
+	};
 };
 
 /* uart0 communicates with the BT module */