arm: dts: sun7i-a20-bananapi: name the GPIO lines
Subsystems (2)
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
This names the GPIO lines on the Banana Pi board in accordance with the A20_Banana_Pi v1.4 Specification.
This will make these line names reflect through to user space so that they can easily be identified and used with the new character device ABI.
--- arch/arm/boot/dts/sun7i-a20-bananapi.dts | 51 ++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+)
arch/arm/boot/dts/sun7i-a20-bananapi.dts +51 -0
@@ -178,6 +178,57 @@ }; &pio { + gpio-line-names = + /* PA */ + "ERXD3", "ERXD2", "ERXD1", "ERXD0", "ETXD3", + "ETXD2", "ETXD1", "ETXD0", + "ERXCK", "ERXERR", "ERXDV", "EMDC", "EMDIO", + "ETXEN", "ETXCK", "ECRS", + "ECOL", "ETXERR", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PB */ + "PMU-SCK", "PMU-SDA", "", "", "", "", "", "", + "", "USB0-DRV", "", "", "", "", "", "", + "", "", "", "", "SCL", "SDA", "", "", + "", "", "", "", "", "", "", "", + /* PC */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PD */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PE */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PF */ + "SD0-D1", "SD0-D0", "SD0-CLK", "SD0-CMD", "SD0-D3", + "SD0-D2", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PG */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PH */ + "TXD0", "RXD0", "IO-1", "PH3", "USB0-IDDET", "PH5", "", "", + "", "", "SD0-DET", "", "", "", "", "", + "", "", "", "", "IO-4", "IO-5", "", "EMAC-PWR-EN", + "LED1", "", "", "", "", "", "", "", + /* PI */ + "", "", "", "IO-GCLK", "", "", "", "", + "", "", "SPI-CE0", "SPI-CLK", "SPI-MOSI", + "SPI-MISO", "SPI-CE1", "", + "IO-6", "IO-3", "IO-2", "IO-0", "", "", "", "", + "", "", "", "", "", "", "", ""; + usb0_id_detect_pin: usb0_id_detect_pin at 0 { pins = "PH4"; function = "gpio_in";
Signature · 1 line
2.7.4
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
Quoted 7 lines · Oleksij Rempel
This names the GPIO lines on the Banana Pi board in accordance with the
A20_Banana_Piv1.4 Specification.This will make these line names reflect through to user space so that they can easily be identified and used with the new character device ABI.
Quoted 6 lines
Signed-off-by Oleksij Rempel <[email protected]>Cc Linus Walleij <[email protected]>Cc devicetree at vger.kernel.orgCc linux-arm-kernel at lists.infradead.orgCc Chen-Yu Tsai <[email protected]>Cc Maxime Ripard <[email protected]>
Yours,
Linus Walleij
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
In reply to Oleksij RempelHi Oleksij,
It looks much better, thanks!
Quoted 7 lines · Oleksij Rempel
This names the GPIO lines on the Banana Pi board in accordance with the
A20_Banana_Piv1.4 Specification.This will make these line names reflect through to user space so that they can easily be identified and used with the new character device ABI.
Quoted 7 lines
Signed-off-by Oleksij Rempel <[email protected]>Cc Linus Walleij <[email protected]>Cc devicetree at vger.kernel.orgCc linux-arm-kernel at lists.infradead.orgCc Chen-Yu Tsai <[email protected]>Cc Maxime Ripard <[email protected]>---
Usually, it's better here if you put a change log with the things that changed from one version to another.
You probably remember all of the comments that were made on the previous version of that patch, but I don't ;)
Quoted 13 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts | 51 ++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+)arch/arm/boot/dts/sun7i-a20-bananapi.dts +2
-0@@ -178,6 +178,57 @@ }; &pio { + gpio-line-names = + /* PA */
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 192
Quoted 10 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +10
-0+ "ERXD3", "ERXD2", "ERXD1", "ERXD0", "ETXD3", + "ETXD2", "ETXD1", "ETXD0", + "ERXCK", "ERXERR", "ERXDV", "EMDC", "EMDIO", + "ETXEN", "ETXCK", "ECRS", + "ECOL", "ETXERR", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PB */ + "PMU-SCK", "PMU-SDA", "", "", "", "", "", "", + "", "USB0-DRV", "", "", "", "", "", "", + "", "", "", "", "SCL", "SDA", "", "",
I'm not sure how it's called in the schematics / documentation, but having a way to get which bus it's from would be helpful (like you did for the PMIC I2C bus).
Quoted 9 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +9
-0+ "", "", "", "", "", "", "", "", + /* PC */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PD */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "",
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 211
Quoted 10 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +10
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PE */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PF */ + "SD0-D1", "SD0-D0", "SD0-CLK", "SD0-CMD", "SD0-D3", + "SD0-D2", "", "",
Why did you change the wrapping and indentation on those two lines?
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 221
Quoted 10 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +10
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PG */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PH */ + "TXD0", "RXD0", "IO-1", "PH3", "USB0-IDDET", "PH5", "", "",
What are PH3 and PH5 used for on the board? Can't we provide a more explicit name?
Thanks!
Maxime
Signature · 10 lines
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: 801 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170509/5105599d/attachment-0001.sig>
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
Am 09.05.2017 um 22:27 schrieb Maxime Ripard:
Quoted 20 lines
Hi Oleksij,
It looks much better, thanks!
Quoted 7 lines · Oleksij Rempel
This names the GPIO lines on the Banana Pi board in accordance with the
A20_Banana_Piv1.4 Specification.This will make these line names reflect through to user space so that they can easily be identified and used with the new character device ABI.
Quoted 7 lines
Signed-off-by Oleksij Rempel <[email protected]>Cc Linus Walleij <[email protected]>Cc devicetree at vger.kernel.orgCc linux-arm-kernel at lists.infradead.orgCc Chen-Yu Tsai <[email protected]>Cc Maxime Ripard <[email protected]>---
Quoted 5 lines
Usually, it's better here if you put a change log with the things that changed from one version to another.
You probably remember all of the comments that were made on the previous version of that patch, but I don't ;)
ok.
Quoted 20 lines
Quoted 20 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts | 51 ++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+)arch/arm/boot/dts/sun7i-a20-bananapi.dts +8
-0@@ -178,6 +178,57 @@ }; &pio { + gpio-line-names = + /* PA */ + "ERXD3", "ERXD2", "ERXD1", "ERXD0", "ETXD3", + "ETXD2", "ETXD1", "ETXD0", + "ERXCK", "ERXERR", "ERXDV", "EMDC", "EMDIO", + "ETXEN", "ETXCK", "ECRS", + "ECOL", "ETXERR", "", "", "", "", "", "", + "", "", "", "", "", "", "", "",
Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 192
Quoted 4 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +4
-0+ /* PB */ + "PMU-SCK", "PMU-SDA", "", "", "", "", "", "", + "", "USB0-DRV", "", "", "", "", "", "", + "", "", "", "", "SCL", "SDA", "", "",I'm not sure how it's called in the schematics / documentation, but having a way to get which bus it's from would be helpful (like you did for the PMIC I2C bus).
I use only names provided by schematics. Using something different IMO makes no sense and confusing.
Quoted 13 lines
Quoted 13 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +13
-0+ "", "", "", "", "", "", "", "", + /* PC */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PD */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PE */ + "", "", "", "", "", "", "", "",
Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 211
Quoted 6 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +6
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PF */ + "SD0-D1", "SD0-D0", "SD0-CLK", "SD0-CMD", "SD0-D3", + "SD0-D2", "", "",Why did you change the wrapping and indentation on those two lines?
i use 8 entry per line to keep counting easier. If line is too wide, i wrap it with changed indentation.
Quoted 5 lines
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PG */ + "", "", "", "", "", "", "", "",
Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 221
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PH */ + "TXD0", "RXD0", "IO-1", "PH3", "USB0-IDDET", "PH5", "", "",What are PH3 and PH5 used for on the board? Can't we provide a more explicit name?
Only names used by schematic :) If we will use something different users will hate us even more.
I can image to use some kind of combination of connector name and pin name. For example: "JP1-RXD0", or some thing like this.
Quoted 3 lines
Thanks!
Maxime
Signature · 10 lines
Regards, Oleksij -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 195 bytes Desc: OpenPGP digital signature URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170510/ef46205f/attachment.sig>
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
Quoted 8 lines · Oleksij Rempel
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 192
Quoted 1 line
arch/arm/boot/dts/sun7i-a20-bananapi.dts +1
-0+ "", "", "", "", "SCL", "SDA", "", "",I'm not sure how it's called in the schematics / documentation, but having a way to get which bus it's from would be helpful (like you did for the PMIC I2C bus).
I use only names provided by schematics. Using something different IMO makes no sense and confusing.
Indeed.
Quoted 22 lines
Quoted 13 lines
Quoted 13 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +13
-0+ "", "", "", "", "", "", "", "", + /* PC */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PD */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PE */ + "", "", "", "", "", "", "", "",Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 211
Quoted 6 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +6
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PF */ + "SD0-D1", "SD0-D0", "SD0-CLK", "SD0-CMD", "SD0-D3", + "SD0-D2", "", "",Why did you change the wrapping and indentation on those two lines?
Quoted 2 lines
i use 8 entry per line to keep counting easier. If line is too wide, i wrap it with changed indentation.
Ack.
Quoted 14 lines
Quoted 5 lines
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PG */ + "", "", "", "", "", "", "", "",Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 221
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PH */ + "TXD0", "RXD0", "IO-1", "PH3", "USB0-IDDET", "PH5", "", "",What are PH3 and PH5 used for on the board? Can't we provide a more explicit name?
Quoted 2 lines
Only names used by schematic :) If we will use something different users will hate us even more.
Those schematics suck then :)
Quoted 2 lines
I can image to use some kind of combination of connector name and pin name. For example: "JP1-RXD0", or some thing like this.
There's no mark on the PCB either? RXD0 and the other are fine, the only ones that concern me are PH3 and PH5, which are basically only the SoC pin name, and nothing else.
I guess we don't really have the choice if the schematic uses that, and there's nothing on the PCB..
Maxime
Signature · 10 lines
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: 801 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170510/beb3fdb2/attachment.sig>
PATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
Am 10.05.2017 um 14:47 schrieb Maxime Ripard:
Quoted 56 lines · Oleksij Rempel
Quoted 8 lines
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 192
Quoted 1 line
arch/arm/boot/dts/sun7i-a20-bananapi.dts +1
-0+ "", "", "", "", "SCL", "SDA", "", "",I'm not sure how it's called in the schematics / documentation, but having a way to get which bus it's from would be helpful (like you did for the PMIC I2C bus).
I use only names provided by schematics. Using something different IMO makes no sense and confusing.
Indeed.
Quoted 22 lines
Quoted 13 lines
Quoted 13 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +13
-0+ "", "", "", "", "", "", "", "", + /* PC */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PD */ + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PE */ + "", "", "", "", "", "", "", "",Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 211
Quoted 6 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +6
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PF */ + "SD0-D1", "SD0-D0", "SD0-CLK", "SD0-CMD", "SD0-D3", + "SD0-D2", "", "",Why did you change the wrapping and indentation on those two lines?
Quoted 2 lines
i use 8 entry per line to keep counting easier. If line is too wide, i wrap it with changed indentation.
Ack.
Quoted 14 lines
Quoted 5 lines
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PG */ + "", "", "", "", "", "", "", "",Quoted 8 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts line 221
Quoted 5 lines
arch/arm/boot/dts/sun7i-a20-bananapi.dts +5
-0+ "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + "", "", "", "", "", "", "", "", + /* PH */ + "TXD0", "RXD0", "IO-1", "PH3", "USB0-IDDET", "PH5", "", "",What are PH3 and PH5 used for on the board? Can't we provide a more explicit name?
Quoted 2 lines
Only names used by schematic :) If we will use something different users will hate us even more.
Quoted 6 lines
Those schematics suck then :)
Quoted 2 lines
I can image to use some kind of combination of connector name and pin name. For example: "JP1-RXD0", or some thing like this.
There's no mark on the PCB either?
correct, no mark on the PCB.
Quoted 6 lines
RXD0 and the other are fine, the
only ones that concern me are PH3 and PH5, which are basically only the SoC pin name, and nothing else.I guess we don't really have the choice if the schematic uses that, and there's nothing on the PCB..
ack.
Signature · 10 lines
Regards, Oleksij -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 213 bytes Desc: OpenPGP digital signature URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170510/8e922cbf/attachment.sig>
Maxime Ripard
AppliedPATCH v3 1/1 arm: dts: sun7i-a20-bananapi: name the GPIO lines
In reply to Oleksij RempelQuoted 6 lines · Oleksij Rempel
This names the GPIO lines on the Banana Pi board in accordance with the
A20_Banana_Piv1.4 Specification.This will make these line names reflect through to user space so that they can easily be identified and used with the new character device ABI.
Merged, thanks!
Maxime
Signature · 10 lines
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: 801 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20170510/1c927dc8/attachment.sig>