Skip to contentSkip to conversation

arm64: tegra: fix compatible string for Tegra132 fuse node

PATCH In review Wei Ni 2 participants 4 messages May 3, 2016 – May 4, 2016

Subsystems (2)
lore
Share & tools
lore

Wei Ni

author
#0 lore raw

PATCH 1/1 arm64: tegra: fix compatible string for Tegra132 fuse node

This patch changes the compatible of Tegra132 fuse node to "nvidia,tegra132-efuse", instead of "nvidia,tegra1124-efuse". Because the CONFIG_ARCH_TEGRA_124_SOC will not be enabled for Tegra132, the fuse driver can't find the corresponding node.

---
 arch/arm64/boot/dts/nvidia/tegra132.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/nvidia/tegra132.dtsi +1 -1
index 5d013809448b..ee101cb52f70 100644
@@ -582,7 +582,7 @@
 	};
 
 	fuse@7000f800 {
-		compatible = "nvidia,tegra124-efuse";
+		compatible = "nvidia,tegra132-efuse";
 		reg = <0x0 0x7000f800 0x0 0x400>;
 		clocks = <&tegra_car TEGRA124_CLK_FUSE>;
 		clock-names = "fuse";
Signature · 1 line
1.9.1
#1 lore raw
Quoted 4 lines · Wei Ni

This patch changes the compatible of Tegra132 fuse node to "nvidia,tegra132-efuse", instead of "nvidia,tegra1124-efuse". Because the CONFIG_ARCH_TEGRA_124_SOC will not be enabled for Tegra132, the fuse driver can't find the corresponding node.

Okay, that's not really a good reason to modify the DTS. What we should do instead is make sure that the OF table contains the entry on Tegra132 builds. Unless the IP block really is different and Tegra124 and Tegra132 aren't compatible in this regard after all.

In the latter case the commit message should reflect the real reason.

Thierry

author
#2 lore raw
Quoted 8 lines · Thierry Reding

* PGP Signed by an unknown key

Quoted 4 lines · Wei Ni

This patch changes the compatible of Tegra132 fuse node to "nvidia,tegra132-efuse", instead of "nvidia,tegra1124-efuse". Because the CONFIG_ARCH_TEGRA_124_SOC will not be enabled for Tegra132, the fuse driver can't find the corresponding node.

Quoted 6 lines

Okay, that's not really a good reason to modify the DTS. What we should do instead is make sure that the OF table contains the entry on Tegra132 builds. Unless the IP block really is different and Tegra124 and Tegra132 aren't compatible in this regard after all.

In the latter case the commit message should reflect the real reason.

Hi Thierry,

The fuse driver fuse-tegra.c has following OF table:

#ifdef CONFIG_ARCH_TEGRA_132_SOC
        { .compatible = "nvidia,tegra132-efuse", .data = &tegra124_fuse_soc },
#endif
#ifdef CONFIG_ARCH_TEGRA_124_SOC
        { .compatible = "nvidia,tegra124-efuse", .data = &tegra124_fuse_soc },

#endif

It defined "nvidia,tegra124-efuse" under CONFIG_ARCH_TEGRA_124_SOC, so if we don't change the DTS file, we should change it as:
-#ifdef CONFIG_ARCH_TEGRA_132_SOC
- { .compatible = "nvidia,tegra132-efuse", .data = &tegra124_fuse_soc },
-#endif
-#ifdef CONFIG_ARCH_TEGRA_124_SOC
+#if defined CONFIG_ARCH_TEGRA_124_SOC || defined CONFIG_ARCH_TEGRA_132_SOC

        { .compatible = "nvidia,tegra124-efuse", .data = &tegra124_fuse_soc },

#endif
#ifdef CONFIG_ARCH_TEGRA_114_SOC

I will send it out.

Quoted 6 lines

Thierry

* Unknown Key
* 0x7F3EB3A1

author
#3 lore raw
Quoted 11 lines · Wei Ni
Quoted 8 lines · Thierry Reding

* PGP Signed by an unknown key

Quoted 4 lines · Wei Ni

This patch changes the compatible of Tegra132 fuse node to "nvidia,tegra132-efuse", instead of "nvidia,tegra1124-efuse". Because the CONFIG_ARCH_TEGRA_124_SOC will not be enabled for Tegra132, the fuse driver can't find the corresponding node.

Quoted 6 lines
Quoted 6 lines

Okay, that's not really a good reason to modify the DTS. What we should do instead is make sure that the OF table contains the entry on Tegra132 builds. Unless the IP block really is different and Tegra124 and Tegra132 aren't compatible in this regard after all.

In the latter case the commit message should reflect the real reason.

Hi Thierry,
I read the Documentation/devicetree/bindings/fuse/nvidia,tegra20-fuse.txt, it has description:
- compatible : For Tegra20, must contain "nvidia,tegra20-efuse". For Tegra30, must contain "nvidia,tegra30-efuse". For Tegra114, must contain "nvidia,tegra114-efuse". For Tegra124, must contain "nvidia,tegra124-efuse". Otherwise, must contain "nvidia,<chip>-efuse", plus one of the above, where <chip> is tegra132.

It mean for Tegra132, it should use "nvidia,tegra132-efuse".

So if we don't change the DTS file, I need to fix the OF table in the driver and update the of-bindings, is it right?

Wei.

Quoted 35 lines

Hi Thierry,

The fuse driver fuse-tegra.c has following OF table:

#ifdef CONFIG_ARCH_TEGRA_132_SOC
        { .compatible = "nvidia,tegra132-efuse", .data = &tegra124_fuse_soc },
#endif
#ifdef CONFIG_ARCH_TEGRA_124_SOC
        { .compatible = "nvidia,tegra124-efuse", .data = &tegra124_fuse_soc },

#endif

It defined "nvidia,tegra124-efuse" under CONFIG_ARCH_TEGRA_124_SOC, so if we don't change the DTS file, we should change it as:

(quoted diff) +1 -4
-#ifdef CONFIG_ARCH_TEGRA_132_SOC
-       { .compatible = "nvidia,tegra132-efuse", .data = &tegra124_fuse_soc },
-#endif
-#ifdef CONFIG_ARCH_TEGRA_124_SOC
+#if defined CONFIG_ARCH_TEGRA_124_SOC || defined CONFIG_ARCH_TEGRA_132_SOC
        { .compatible = "nvidia,tegra124-efuse", .data = &tegra124_fuse_soc },
 #endif
 #ifdef CONFIG_ARCH_TEGRA_114_SOC

I will send it out.

Quoted 6 lines

Thierry

* Unknown Key
* 0x7F3EB3A1

--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html