Skip to contentSkip to conversation

Remove the pins-are-numbered DT property

PATCH In review Bernhard Rosenkränzer 2 participants 5 messages Dec 5, 2022 – Jan 9, 2023

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

v4 cover Remove the pins-are-numbered DT property

During the review of my MT8365 support patchset
(https://lore.kernel.org/linux-mediatek/[email protected]/),
the issue of the "pins-are-numbered" DeviceTree property has come up.

This property is unique to Mediatek MT65xx and STM32 pinctrls, and doesn't seem to serve any purpose (both the Mediatek and STM32 drivers simply refuse to deal with a device unless pins-are-numbered is set to true).

There is no other use of this property in the kernel or in other projects using DeviceTrees (checked u-boot and FreeBSD -- in both of those, the flag is present in Mediatek and STM devicetrees, but not used anywhere).

There is also no known use in userspace (in fact, a userland application relying on the property would be broken because it would get true on any Mediatek or STM chipset and false on all others, even though other chipsets use numbered pins).

This patchset removes all uses of pins-are-numbered and marks the property as deprecated.

v4:
- The generic pinctrl related patches are now in the pinctrl tree for v6.2 - remove them and repost the remaining bits of the patch set. No other changes.

v3:
- No functional changes; add recent Reviewed-Bys and Acked-Bys, add linux-gpio to Cc

v2:
- Deprecate the property instead of removing it completely from schemas
- squash some related commits

Bernhard Rosenkränzer (3):
arm64: dts: mediatek: Remove pins-are-numbered property
ARM: dts: mediatek: Remove pins-are-numbered property
ARM: dts: stm32: Remove the pins-are-numbered property

 arch/arm/boot/dts/mt2701.dtsi                | 1 -
 arch/arm/boot/dts/mt7623.dtsi                | 1 -
 arch/arm/boot/dts/mt8135.dtsi                | 1 -
 arch/arm/boot/dts/stm32f4-pinctrl.dtsi       | 1 -
 arch/arm/boot/dts/stm32f7-pinctrl.dtsi       | 1 -
 arch/arm/boot/dts/stm32h743.dtsi             | 1 -
 arch/arm/boot/dts/stm32mp131.dtsi            | 1 -
 arch/arm/boot/dts/stm32mp151.dtsi            | 2 --
 arch/arm64/boot/dts/mediatek/mt2712e.dtsi    | 1 -
 arch/arm64/boot/dts/mediatek/mt8167.dtsi     | 1 -
 arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi | 1 -
 arch/arm64/boot/dts/mediatek/mt8173.dtsi     | 1 -
 arch/arm64/boot/dts/mediatek/mt8516.dtsi     | 1 -
 13 files changed, 14 deletions(-)
Signature · 1 line
2.38.1
#1 lore raw

PATCH v4 1/3 arm64: dts: mediatek: Remove pins-are-numbered property

Remove the unnecessary pins-are-numbered property from arm64 Mediatek DeviceTrees

---
 arch/arm64/boot/dts/mediatek/mt2712e.dtsi    | 1 -
 arch/arm64/boot/dts/mediatek/mt8167.dtsi     | 1 -
 arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi | 1 -
 arch/arm64/boot/dts/mediatek/mt8173.dtsi     | 1 -
 arch/arm64/boot/dts/mediatek/mt8516.dtsi     | 1 -
 5 files changed, 5 deletions(-)
arch/arm64/boot/dts/mediatek/mt2712e.dtsi +0 -1
index 92212cddd37e6..879dff24dcd3b 100644
@@ -270,7 +270,6 @@ pio: pinctrl@1000b000 {
 		compatible = "mediatek,mt2712-pinctrl";
 		reg = <0 0x1000b000 0 0x1000>;
 		mediatek,pctl-regmap = <&syscfg_pctl_a>;
-		pins-are-numbered;
 		gpio-controller;
 		#gpio-cells = <2>;
 		interrupt-controller;
arch/arm64/boot/dts/mediatek/mt8167.dtsi +0 -1
index fbe1a1128cc6a..6a54315cf6502 100644
@@ -117,7 +117,6 @@ pio: pinctrl@1000b000 {
 			compatible = "mediatek,mt8167-pinctrl";
 			reg = <0 0x1000b000 0 0x1000>;
 			mediatek,pctl-regmap = <&syscfg_pctl>;
-			pins-are-numbered;
 			gpio-controller;
 			#gpio-cells = <2>;
 			interrupt-controller;
arch/arm64/boot/dts/mediatek/mt8173-elm.dtsi +0 -1
index e21feb85d822b..18e214464a2d3 100644
@@ -929,7 +929,6 @@ clock: mt6397clock {
 
 		pio6397: pinctrl {
 			compatible = "mediatek,mt6397-pinctrl";
-			pins-are-numbered;
 			gpio-controller;
 			#gpio-cells = <2>;
 		};
arch/arm64/boot/dts/mediatek/mt8173.dtsi +0 -1
index 7640b5158ff9d..c47d7d900f283 100644
@@ -375,7 +375,6 @@ pio: pinctrl@1000b000 {
 			compatible = "mediatek,mt8173-pinctrl";
 			reg = <0 0x1000b000 0 0x1000>;
 			mediatek,pctl-regmap = <&syscfg_pctl_a>;
-			pins-are-numbered;
 			gpio-controller;
 			#gpio-cells = <2>;
 			interrupt-controller;
arch/arm64/boot/dts/mediatek/mt8516.dtsi +0 -1
index d1b67c82d7617..118025263a29b 100644
@@ -229,7 +229,6 @@ pio: pinctrl@1000b000 {
 			compatible = "mediatek,mt8516-pinctrl";
 			reg = <0 0x1000b000 0 0x1000>;
 			mediatek,pctl-regmap = <&syscfg_pctl>;
-			pins-are-numbered;
 			gpio-controller;
 			#gpio-cells = <2>;
 			interrupt-controller;
Signature · 1 line
2.38.1
#2 lore raw

PATCH v4 2/3 ARM: dts: mediatek: Remove pins-are-numbered property

In reply to Bernhard Rosenkränzer

Remove the unnecessary pins-are-numbered property from Mediatek ARM DeviceTrees

---
 arch/arm/boot/dts/mt2701.dtsi | 1 -
 arch/arm/boot/dts/mt7623.dtsi | 1 -
 arch/arm/boot/dts/mt8135.dtsi | 1 -
 3 files changed, 3 deletions(-)
arch/arm/boot/dts/mt2701.dtsi +0 -1
index b8eba3ba153c2..0a0fe8c5a4059 100644
@@ -178,7 +178,6 @@ pio: pinctrl@1000b000 {
 		compatible = "mediatek,mt2701-pinctrl";
 		reg = <0 0x1000b000 0 0x1000>;
 		mediatek,pctl-regmap = <&syscfg_pctl_a>;
-		pins-are-numbered;
 		gpio-controller;
 		#gpio-cells = <2>;
 		interrupt-controller;
arch/arm/boot/dts/mt7623.dtsi +0 -1
index 25d31e40a5535..11379c3e6b4ca 100644
@@ -253,7 +253,6 @@ pio: pinctrl@10005000 {
 		compatible = "mediatek,mt7623-pinctrl";
 		reg = <0 0x1000b000 0 0x1000>;
 		mediatek,pctl-regmap = <&syscfg_pctl_a>;
-		pins-are-numbered;
 		gpio-controller;
 		#gpio-cells = <2>;
 		interrupt-controller;
arch/arm/boot/dts/mt8135.dtsi +0 -1
index a031b36363187..0f291ad22d3af 100644
@@ -152,7 +152,6 @@ pio: pinctrl@10005000 {
 			compatible = "mediatek,mt8135-pinctrl";
 			reg = <0 0x1000b000 0 0x1000>;
 			mediatek,pctl-regmap = <&syscfg_pctl_a &syscfg_pctl_b>;
-			pins-are-numbered;
 			gpio-controller;
 			#gpio-cells = <2>;
 			interrupt-controller;
Signature · 1 line
2.38.1
#3 lore raw

PATCH v4 3/3 ARM: dts: stm32: Remove the pins-are-numbered property

In reply to Bernhard Rosenkränzer

Remove the pins-are-numbered property from STM32 DeviceTrees

---
 arch/arm/boot/dts/stm32f4-pinctrl.dtsi | 1 -
 arch/arm/boot/dts/stm32f7-pinctrl.dtsi | 1 -
 arch/arm/boot/dts/stm32h743.dtsi       | 1 -
 arch/arm/boot/dts/stm32mp131.dtsi      | 1 -
 arch/arm/boot/dts/stm32mp151.dtsi      | 2 --
 5 files changed, 6 deletions(-)
arch/arm/boot/dts/stm32f4-pinctrl.dtsi +0 -1
index 500bcc302d422..4523c63475e4c 100644
@@ -51,7 +51,6 @@ pinctrl: pinctrl@40020000 {
 			ranges = <0 0x40020000 0x3000>;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&syscfg 0x8>;
-			pins-are-numbered;
 
 			gpioa: gpio@40020000 {
 				gpio-controller;
arch/arm/boot/dts/stm32f7-pinctrl.dtsi +0 -1
index 8f37aefa73150..c8e6c52fb248e 100644
@@ -15,7 +15,6 @@ pinctrl: pinctrl@40020000 {
 			ranges = <0 0x40020000 0x3000>;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&syscfg 0x8>;
-			pins-are-numbered;
 
 			gpioa: gpio@40020000 {
 				gpio-controller;
arch/arm/boot/dts/stm32h743.dtsi +0 -1
index 28e3deb20e1e1..f30796f7adf36 100644
@@ -588,7 +588,6 @@ pinctrl: pinctrl@58020000 {
 			ranges = <0 0x58020000 0x3000>;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&syscfg 0x8>;
-			pins-are-numbered;
 
 			gpioa: gpio@58020000 {
 				gpio-controller;
arch/arm/boot/dts/stm32mp131.dtsi +0 -1
index accc3824f7e98..6b86e031f60e6 100644
@@ -547,7 +547,6 @@ pinctrl: pinctrl@50002000 {
 			ranges = <0 0x50002000 0x8400>;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&exti 0x60 0xff>;
-			pins-are-numbered;
 
 			gpioa: gpio@50002000 {
 				gpio-controller;
arch/arm/boot/dts/stm32mp151.dtsi +0 -2
index 5491b6c4dec20..4e437d3f2ed66 100644
@@ -1660,7 +1660,6 @@ pinctrl: pinctrl@50002000 {
 			ranges = <0 0x50002000 0xa400>;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&exti 0x60 0xff>;
-			pins-are-numbered;
 
 			gpioa: gpio@50002000 {
 				gpio-controller;
@@ -1789,7 +1788,6 @@ pinctrl_z: pinctrl@54004000 {
 			#size-cells = <1>;
 			compatible = "st,stm32mp157-z-pinctrl";
 			ranges = <0 0x54004000 0x400>;
-			pins-are-numbered;
 			interrupt-parent = <&exti>;
 			st,syscfg = <&exti 0x60 0xff>;
 
Signature · 1 line
2.38.1