mips: dts: Fix PIC32MZDA GPIO register definitions
PATCH v2 2/2 mips: dts: Fix PIC32MZDA GPIO register definitions
The GPIO bank name for banks J and K are not correct when using the 'gpio' command from the console.
The driver derives the bank name from the device tree instance string by using the instance value and adding 'A': gpio0 at xxaddrxx is Bank A, gpio1 at yyaddryy is Bank B and so on.
On the PIC32, there is no Bank I so instances 8 and 9 need to be incremented as a minimum change.
An alternative (less opaque) implementation would be to use a bank-name property instead but this would require modifying the driver code too.
---
arch/mips/dts/pic32mzda.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/mips/dts/pic32mzda.dtsi +2 -2
@@ -134,14 +134,14 @@ #gpio-cells = <2>; }; - gpioJ: gpio8 at 1f860800 { + gpioJ: gpio9 at 1f860800 { compatible = "microchip,pic32mzda-gpio"; reg = <0x1f860800 0xe0>; gpio-controller; #gpio-cells = <2>; }; - gpioK: gpio9 at 1f860900 { + gpioK: gpio10 at 1f860900 { compatible = "microchip,pic32mzda-gpio"; reg = <0x1f860900 0xe0>; gpio-controller;
Signature · 1 line
2.28.0
PATCH v2 2/2 mips: dts: Fix PIC32MZDA GPIO register definitions
Am Dienstag, den 01.09.2020, 18:02 +0000 schrieb John Robertson:
Quoted 10 lines
The GPIO bank name for banks J and K are not correct when using the 'gpio' command from the console.
The driver derives the bank name from the device tree instance string by using the instance value and adding 'A': gpio0 at xxaddrxx is Bank A, gpio1 at yyaddryy is Bank B and so on.
On the PIC32, there is no Bank I so instances 8 and 9 need to be incremented as a minimum change.
Quoted 9 lines
An alternative (less opaque) implementation would be to use a bank-name property instead but this would require modifying the driver code too.
Signed-off-by John Robertson <[email protected]>---
arch/mips/dts/pic32mzda.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
applied to u-boot-mips/fixes, thanks.
Signature · 1 line
- Daniel