Skip to contentSkip to conversation

ARM: dts: bcm63138: drop invalid "nand" interrupt name

PATCH In review Rafał Miłecki 3 participants 6 messages Nov 3, 2022

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

PATCH 1/1 ARM: dts: bcm63138: drop invalid "nand" interrupt name

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

The whole "interrupt-names" property is optional and can be skipped.

Fixes b5762cacc411 ("ARM: bcm63138: add NAND DT support")
---
 arch/arm/boot/dts/bcm63138.dtsi | 1 -
 1 file changed, 1 deletion(-)
arch/arm/boot/dts/bcm63138.dtsi +0 -1
index b774a8d63813..7c1f656e3278 100644
@@ -211,7 +211,6 @@ nand_controller: nand-controller@2000 {
 			reg-names = "nand", "nand-int-base";
 			status = "disabled";
 			interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>;
-			interrupt-names = "nand";
 		};
 
 		bootlut: bootlut@8000 {
Signature · 1 line
2.34.1
#1 lore raw
Quoted 7 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

The whole "interrupt-names" property is optional and can be skipped.

How about we just fix the binding document instead? Deciding the fate of a property based upon client programs of the DTS using it is a weak argument IMHO.

Signature · 1 line
Florian
#2 lore raw
Quoted 9 lines · Florian Fainelli
Quoted 6 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

Quoted 5 lines
Quoted 1 line

The whole "interrupt-names" property is optional and can be skipped.

How about we just fix the binding document instead? Deciding the fate of a property based upon client programs of the DTS using it is a weak argument IMHO.

Having a "names" property with only one item and the name matching the device name is also not useful.

For new bindings the recommendation would be: drop the interrupt-names. For existing bindings - choose something reasonable, e.g. less changes needed.

Best regards,
Krzysztof

#3 lore raw
In reply to Florian Fainelli
Quoted 10 lines · Florian Fainelli
Quoted 7 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

The whole "interrupt-names" property is optional and can be skipped.

How about we just fix the binding document instead? Deciding the fate of a property based upon client programs of the DTS using it is a weak argument IMHO.

It's not a matter of client programs.

Binding clearly says that the first interrupt is "NAND CTLRDY interrupt". Please check: Documentation/devicetree/bindings/mtd/brcm,brcmnand.yaml

Other interrupts are described as well. It's just "interrupts-names" that are optional.

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

#4 lore raw
Quoted 10 lines · Rafał Miłecki
Quoted 9 lines · Florian Fainelli
Quoted 7 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

The whole "interrupt-names" property is optional and can be skipped.

Quoted 7 lines
Quoted 1 line

How about we just fix the binding document instead? Deciding the fate of a property based upon client programs of the DTS using it is a weak argument IMHO.

It's not a matter of client programs.

Binding clearly says that the first interrupt is "NAND CTLRDY interrupt". Please check: Documentation/devicetree/bindings/mtd/brcm,brcmnand.yaml

The binding is trying to capture all of the existing conditions that are present in Linux's tree but it is not actually specific enough for instance flash_dma_done and flash_edu_done are mutually exclusive and depend upon the controller's generation. Something that ought to be fixed as a separate patch.

Quoted 3 lines

Other interrupts are described as well. It's just "interrupts-names" that are optional.

How about we just rename the interrupt-names to "nand_ctlrdy" then, and also drop the Fixes: tag because we are not fixing anything functional here.

Signature · 1 line
Florian
#5 lore raw
Quoted 13 lines · Florian Fainelli
Quoted 12 lines · Rafał Miłecki
Quoted 10 lines · Florian Fainelli
Quoted 7 lines · Rafał Miłecki

From: Rafał Miłecki <[email protected]>

String "nand" was never a valid interrupt name. It was never documented and never used in Linux or U-Boot driver. It most likely comes from a copy & paste mistake ("nand" is used in "reg-names").

The whole "interrupt-names" property is optional and can be skipped.

How about we just fix the binding document instead? Deciding the fate of a property based upon client programs of the DTS using it is a weak argument IMHO.

Quoted 7 lines
Quoted 5 lines

It's not a matter of client programs.

Binding clearly says that the first interrupt is "NAND CTLRDY interrupt". Please check: Documentation/devicetree/bindings/mtd/brcm,brcmnand.yaml

The binding is trying to capture all of the existing conditions that are present in Linux's tree but it is not actually specific enough for instance flash_dma_done and flash_edu_done are mutually exclusive and depend upon the controller's generation. Something that ought to be fixed as a separate patch.

In that case binding it wrong and has to be fixed first.

In this case I'll work on the binding first before cleaning DTS files.

Please drop this patch for now.