From c158e3ee74ee6d37df0dd982feb5bc0acdc66853 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrzej=20G=C5=82=C4=85bek?= Date: Thu, 2 Apr 2020 09:49:15 +0000 Subject: [PATCH] dts: nrf: Correct the number of pins available in gpio1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Currently supported nRF SoCs featuring the second GPIO port (P1) do not have all 32 pins implemented in that port. Add the "ngpios" property in gpio1 nodes for these SoCs, so that they don't take the default value of 32 to indicate the number of available pins but use instead: - 10 for nRF52833 - 16 for nRF52840 - 16 for nRF5340 (both application and network core) Signed-off-by: Andrzej Głąbek --- dts/arm/nordic/nrf52833.dtsi | 1 + dts/arm/nordic/nrf52840.dtsi | 1 + dts/arm/nordic/nrf5340_cpuapp_common.dtsi | 1 + dts/arm/nordic/nrf5340_cpunet.dtsi | 1 + 4 files changed, 4 insertions(+) diff --git a/dts/arm/nordic/nrf52833.dtsi b/dts/arm/nordic/nrf52833.dtsi index 0c6029bd304..851967c29ca 100644 --- a/dts/arm/nordic/nrf52833.dtsi +++ b/dts/arm/nordic/nrf52833.dtsi @@ -132,6 +132,7 @@ reg = <0x50000300 0x200 0x50000800 0x300>; #gpio-cells = <2>; + ngpios = <10>; label = "GPIO_1"; status = "disabled"; }; diff --git a/dts/arm/nordic/nrf52840.dtsi b/dts/arm/nordic/nrf52840.dtsi index 770c9081376..ea9632149d5 100644 --- a/dts/arm/nordic/nrf52840.dtsi +++ b/dts/arm/nordic/nrf52840.dtsi @@ -131,6 +131,7 @@ reg = <0x50000300 0x200 0x50000800 0x300>; #gpio-cells = <2>; + ngpios = <16>; label = "GPIO_1"; status = "disabled"; }; diff --git a/dts/arm/nordic/nrf5340_cpuapp_common.dtsi b/dts/arm/nordic/nrf5340_cpuapp_common.dtsi index eaa35f8904d..0c760226366 100644 --- a/dts/arm/nordic/nrf5340_cpuapp_common.dtsi +++ b/dts/arm/nordic/nrf5340_cpuapp_common.dtsi @@ -339,6 +339,7 @@ gpio1: gpio@842800 { gpio-controller; reg = <0x842800 0x300>; #gpio-cells = <2>; + ngpios = <16>; label = "GPIO_1"; status = "disabled"; }; diff --git a/dts/arm/nordic/nrf5340_cpunet.dtsi b/dts/arm/nordic/nrf5340_cpunet.dtsi index 01b49b1a159..02367acf5fc 100644 --- a/dts/arm/nordic/nrf5340_cpunet.dtsi +++ b/dts/arm/nordic/nrf5340_cpunet.dtsi @@ -111,6 +111,7 @@ gpio-controller; reg = <0x418c0800 0x300>; #gpio-cells = <2>; + ngpios = <16>; label = "GPIO_1"; status = "disabled"; };