linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/9] nvmem: sfp: binding updates and additions
@ 2022-04-28 18:16 Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 1/9] dt-bindings: nvmem: sfp: Fix typo Sean Anderson
                   ` (9 more replies)
  0 siblings, 10 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

This adds several properties to the Layerscape Security Fuse Processor
(SFP) necessary for writing. Although the Linux driver does not use
these bindings, I plan to use them in U-Boot [1]. It also adds a new
compatibles for Trust Architecture (TA) 2.1 devices. In addition, it
also adds an SFP binding for all TA 2.1 and 3.0 devices.

I would like to get this series merged for 5.18. As noted in patch 2,
making the clock property mandatory is not an ABI break, but if this is
not applied then it would become an ABI break. The absolute minimum
patches to apply for this would be patches 2 and 5. The rest (including
the regmap changes) could be deferred if necessary.

[1] https://lore.kernel.org/u-boot/7c8e206a-cd40-2a77-6282-7f4bead2b13a@seco.com/T/#m591f8425b6f096ab3d54e6f7bd258e41cfa4c43b

Changes in v3:
- Update commit message to note that this binding has not yet been
  present in a relase, so it is OK to make otherwise breaking changes.

Changes in v2:
- Mention "regulator" in the description for ta-prog-sfp-supply
- Convert sfp driver to use regmap
- Fix various typos in commit messages

Sean Anderson (9):
  dt-bindings: nvmem: sfp: Fix typo
  dt-bindings: nvmem: sfp: Add clock properties
  dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply
  dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs
  arm64: dts: ls1028a: Update SFP binding to include clock
  ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
  ARM: dts: Add SFP binding for TA 3.0 devices
  nvmem: sfp: Use regmap
  nvmem: sfp: Add support for TA 2.1 devices

 .../bindings/nvmem/fsl,layerscape-sfp.yaml    | 30 ++++++++++++++--
 arch/arm/boot/dts/ls1021a.dtsi                |  7 ++++
 .../arm64/boot/dts/freescale/fsl-ls1012a.dtsi |  8 +++++
 .../arm64/boot/dts/freescale/fsl-ls1028a.dtsi |  5 ++-
 .../arm64/boot/dts/freescale/fsl-ls1043a.dtsi |  8 +++++
 .../arm64/boot/dts/freescale/fsl-ls1046a.dtsi |  8 +++++
 .../arm64/boot/dts/freescale/fsl-ls1088a.dtsi |  8 +++++
 .../arm64/boot/dts/freescale/fsl-ls208xa.dtsi |  8 +++++
 .../arm64/boot/dts/freescale/fsl-lx2160a.dtsi |  8 +++++
 drivers/nvmem/Kconfig                         |  1 +
 drivers/nvmem/layerscape-sfp.c                | 36 ++++++++++++++-----
 11 files changed, 115 insertions(+), 12 deletions(-)

-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply	[flat|nested] 16+ messages in thread

* [PATCH v3 1/9] dt-bindings: nvmem: sfp: Fix typo
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
@ 2022-04-28 18:16 ` Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 2/9] dt-bindings: nvmem: sfp: Add clock properties Sean Anderson
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

There is a small grammatical error in the description. Fix it.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
Reviewed-by: Michael Walle <michael@walle.cc>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
---

(no changes since v1)

 Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
index 80914b93638e..b7798e903191 100644
--- a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
+++ b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
@@ -10,7 +10,7 @@ maintainers:
   - Michael Walle <michael@walle.cc>
 
 description: |
-  SFP is the security fuse processor which among other things provide a
+  SFP is the security fuse processor which among other things provides a
   unique identifier per part.
 
 allOf:
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 2/9] dt-bindings: nvmem: sfp: Add clock properties
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 1/9] dt-bindings: nvmem: sfp: Fix typo Sean Anderson
@ 2022-04-28 18:16 ` Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 3/9] dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply Sean Anderson
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

To program fuses, it is necessary to set the fuse programming time. This
is determined based on the value of the platform clock. Add a clock
property.

Because this property is necessary for programming, it is made
mandatory. Since these bindings have not yet been present in a stable
release (though they are on track for 5.18), it is not an ABI break to
change them in this manner.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---
This patch causes CI to fail. It will be fixed by patch 5.

Changes in v3:
- Update commit message to note that this binding has not yet been
  present in a relase, so it is OK to make otherwise breaking changes.

 .../bindings/nvmem/fsl,layerscape-sfp.yaml         | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
index b7798e903191..54086f50157d 100644
--- a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
+++ b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
@@ -24,15 +24,29 @@ properties:
   reg:
     maxItems: 1
 
+  clocks:
+    maxItems: 1
+    description:
+      The SFP clock. Typically, this is the platform clock divided by 4.
+
+  clock-names:
+    const: sfp
+
 required:
   - compatible
   - reg
+  - clock-names
+  - clocks
 
 unevaluatedProperties: false
 
 examples:
   - |
+    #include <dt-bindings/clock/fsl,qoriq-clockgen.h>
     efuse@1e80000 {
         compatible = "fsl,ls1028a-sfp";
         reg = <0x1e80000 0x8000>;
+        clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+                            QORIQ_CLK_PLL_DIV(4)>;
+        clock-names = "sfp";
     };
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 3/9] dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 1/9] dt-bindings: nvmem: sfp: Fix typo Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 2/9] dt-bindings: nvmem: sfp: Add clock properties Sean Anderson
@ 2022-04-28 18:16 ` Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 4/9] dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs Sean Anderson
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

The TA_PROG_SFP supply must be enabled to program the fuses, and
disabled to read the fuses (such as at power-on-reset). On many boards,
this supply is controlled by a jumper. The user must manually insert or
remove it at the appropriate time in the programming process. However,
on other boards this supply is controlled by an FPGA or a GPIO. In
these cases, the driver can automatically enable and disable it as
necessary.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
---

(no changes since v2)

Changes in v2:
- Mention "regulator" in the description for ta-prog-sfp-supply

 .../devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml        | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
index 54086f50157d..c5d7375b840a 100644
--- a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
+++ b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
@@ -32,6 +32,11 @@ properties:
   clock-names:
     const: sfp
 
+  ta-prog-sfp-supply:
+    description:
+      The regulator for the TA_PROG_SFP pin. It will be enabled for programming
+      and disabled for reading.
+
 required:
   - compatible
   - reg
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 4/9] dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (2 preceding siblings ...)
  2022-04-28 18:16 ` [PATCH v3 3/9] dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply Sean Anderson
@ 2022-04-28 18:16 ` Sean Anderson
  2022-04-28 18:16 ` [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock Sean Anderson
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

Trust Architecture (TA) 2.1 devices include the LS1012A, LS1021A,
LS1043A, and LS1046A. The SFP device on TA 2.1 devices is very similar
to the SFP on TA 3.0 devices. The primary difference is a few fields in
the control register. Add a compatible string.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---

(no changes since v1)

 .../devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml    | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
index c5d7375b840a..3b4e6e94cb81 100644
--- a/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
+++ b/Documentation/devicetree/bindings/nvmem/fsl,layerscape-sfp.yaml
@@ -18,8 +18,13 @@ allOf:
 
 properties:
   compatible:
-    enum:
-      - fsl,ls1028a-sfp
+    oneOf:
+      - description: Trust architecture 2.1 SFP
+        items:
+          - const: fsl,ls1021a-sfp
+      - description: Trust architecture 3.0 SFP
+        items:
+          - const: fsl,ls1028a-sfp
 
   reg:
     maxItems: 1
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (3 preceding siblings ...)
  2022-04-28 18:16 ` [PATCH v3 4/9] dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs Sean Anderson
@ 2022-04-28 18:16 ` Sean Anderson
  2022-05-03 13:47   ` Michael Walle
  2022-04-28 18:17 ` [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices Sean Anderson
                   ` (4 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:16 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

The clocks property is now mandatory. Add it.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
Reviewed-by: Michael Walle <michael@walle.cc>
---

(no changes since v1)

 arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
index 088271d49139..59b289b52a28 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1028a.dtsi
@@ -224,9 +224,12 @@ rst: syscon@1e60000 {
 			little-endian;
 		};
 
-		efuse@1e80000 {
+		sfp: efuse@1e80000 {
 			compatible = "fsl,ls1028a-sfp";
 			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
 			#address-cells = <1>;
 			#size-cells = <1>;
 
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (4 preceding siblings ...)
  2022-04-28 18:16 ` [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock Sean Anderson
@ 2022-04-28 18:17 ` Sean Anderson
  2022-06-29 13:34   ` Shawn Guo
  2022-04-28 18:17 ` [PATCH v3 7/9] ARM: dts: Add SFP binding for TA 3.0 devices Sean Anderson
                   ` (3 subsequent siblings)
  9 siblings, 1 reply; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:17 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

This adds an appropriate SFP binding for Trust Architecture 2.1 devices.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---

(no changes since v1)

 arch/arm/boot/dts/ls1021a.dtsi                 | 7 +++++++
 arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi | 8 ++++++++
 arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi | 8 ++++++++
 arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi | 8 ++++++++
 4 files changed, 31 insertions(+)

diff --git a/arch/arm/boot/dts/ls1021a.dtsi b/arch/arm/boot/dts/ls1021a.dtsi
index 2e69d6eab4d1..c1e94a317cba 100644
--- a/arch/arm/boot/dts/ls1021a.dtsi
+++ b/arch/arm/boot/dts/ls1021a.dtsi
@@ -129,6 +129,13 @@ ifc: ifc@1530000 {
 			status = "disabled";
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1021a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen 4 3>;
+			clock-names = "sfp";
+		};
+
 		dcfg: dcfg@1ee0000 {
 			compatible = "fsl,ls1021a-dcfg", "syscon";
 			reg = <0x0 0x1ee0000 0x0 0x1000>;
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
index 50a72cda4727..47ce525e0a72 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
@@ -271,6 +271,14 @@ rtic_d: rtic-d@60 {
 			};
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1021a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		sec_mon: sec_mon@1e90000 {
 			compatible = "fsl,sec-v5.4-mon", "fsl,sec-v5.0-mon",
 				     "fsl,sec-v4.0-mon";
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
index 35d1939e690b..b0ab0b19de7e 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
@@ -383,6 +383,14 @@ sec_jr3: jr@40000 {
 			};
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1021a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		dcfg: dcfg@1ee0000 {
 			compatible = "fsl,ls1043a-dcfg", "syscon";
 			reg = <0x0 0x1ee0000 0x0 0x10000>;
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
index 4e7bd04d9798..c30056afc02a 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
@@ -413,6 +413,14 @@ bportals: bman-portals@508000000 {
 			ranges = <0x0 0x5 0x08000000 0x8000000>;
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1021a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		dcfg: dcfg@1ee0000 {
 			compatible = "fsl,ls1046a-dcfg", "syscon";
 			reg = <0x0 0x1ee0000 0x0 0x1000>;
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 7/9] ARM: dts: Add SFP binding for TA 3.0 devices
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (5 preceding siblings ...)
  2022-04-28 18:17 ` [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices Sean Anderson
@ 2022-04-28 18:17 ` Sean Anderson
  2022-04-28 18:17 ` [PATCH v3 8/9] nvmem: sfp: Use regmap Sean Anderson
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:17 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

This adds an SFP binding for Trust Architecture 3.0 devices.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---

(no changes since v1)

 arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi | 8 ++++++++
 arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi | 8 ++++++++
 arch/arm64/boot/dts/freescale/fsl-lx2160a.dtsi | 8 ++++++++
 3 files changed, 24 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi
index 18e529118476..1a58e8671047 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls1088a.dtsi
@@ -269,6 +269,14 @@ extirq: interrupt-controller@14 {
 			};
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1028a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		tmu: tmu@1f80000 {
 			compatible = "fsl,qoriq-tmu";
 			reg = <0x0 0x1f80000 0x0 0x10000>;
diff --git a/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi
index 1282b61da8a5..5705ec554bf9 100644
--- a/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-ls208xa.dtsi
@@ -278,6 +278,14 @@ dcfg: dcfg@1e00000 {
 			little-endian;
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1028a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		isc: syscon@1f70000 {
 			compatible = "fsl,ls2080a-isc", "syscon";
 			reg = <0x0 0x1f70000 0x0 0x10000>;
diff --git a/arch/arm64/boot/dts/freescale/fsl-lx2160a.dtsi b/arch/arm64/boot/dts/freescale/fsl-lx2160a.dtsi
index c5daa15b020d..53dd8c7dc048 100644
--- a/arch/arm64/boot/dts/freescale/fsl-lx2160a.dtsi
+++ b/arch/arm64/boot/dts/freescale/fsl-lx2160a.dtsi
@@ -671,6 +671,14 @@ dcfg: syscon@1e00000 {
 			little-endian;
 		};
 
+		sfp: efuse@1e80000 {
+			compatible = "fsl,ls1028a-sfp";
+			reg = <0x0 0x1e80000 0x0 0x10000>;
+			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+					    QORIQ_CLK_PLL_DIV(4)>;
+			clock-names = "sfp";
+		};
+
 		isc: syscon@1f70000 {
 			compatible = "fsl,lx2160a-isc", "syscon";
 			reg = <0x0 0x1f70000 0x0 0x10000>;
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 8/9] nvmem: sfp: Use regmap
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (6 preceding siblings ...)
  2022-04-28 18:17 ` [PATCH v3 7/9] ARM: dts: Add SFP binding for TA 3.0 devices Sean Anderson
@ 2022-04-28 18:17 ` Sean Anderson
  2022-04-28 18:17 ` [PATCH v3 9/9] nvmem: sfp: Add support for TA 2.1 devices Sean Anderson
  2022-04-29 15:56 ` [PATCH v3 0/9] nvmem: sfp: binding updates and additions Srinivas Kandagatla
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:17 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

This converts the SFP driver to use regmap. This will allow easily
supporting devices with different endians. We disallow byte-level
access, as regmap_bulk_read doesn't support it (and it's unclear what
the correct result would be when we have an endianness difference).

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---

(no changes since v2)

Changes in v2:
- New

 drivers/nvmem/Kconfig          |  1 +
 drivers/nvmem/layerscape-sfp.c | 30 ++++++++++++++++++++++--------
 2 files changed, 23 insertions(+), 8 deletions(-)

diff --git a/drivers/nvmem/Kconfig b/drivers/nvmem/Kconfig
index 555aa77a574d..403ed5257592 100644
--- a/drivers/nvmem/Kconfig
+++ b/drivers/nvmem/Kconfig
@@ -304,6 +304,7 @@ config NVMEM_LAYERSCAPE_SFP
 	tristate "Layerscape SFP (Security Fuse Processor) support"
 	depends on ARCH_LAYERSCAPE || COMPILE_TEST
 	depends on HAS_IOMEM
+	select REGMAP_MMIO
 	help
 	  This driver provides support to read the eFuses on Freescale
 	  Layerscape SoC's. For example, the vendor provides a per part
diff --git a/drivers/nvmem/layerscape-sfp.c b/drivers/nvmem/layerscape-sfp.c
index e591c1511e33..59083f048921 100644
--- a/drivers/nvmem/layerscape-sfp.c
+++ b/drivers/nvmem/layerscape-sfp.c
@@ -13,15 +13,17 @@
 #include <linux/nvmem-provider.h>
 #include <linux/platform_device.h>
 #include <linux/property.h>
+#include <linux/regmap.h>
 
 #define LAYERSCAPE_SFP_OTP_OFFSET	0x0200
 
 struct layerscape_sfp_priv {
-	void __iomem *base;
+	struct regmap *regmap;
 };
 
 struct layerscape_sfp_data {
 	int size;
+	enum regmap_endian endian;
 };
 
 static int layerscape_sfp_read(void *context, unsigned int offset, void *val,
@@ -29,15 +31,16 @@ static int layerscape_sfp_read(void *context, unsigned int offset, void *val,
 {
 	struct layerscape_sfp_priv *priv = context;
 
-	memcpy_fromio(val, priv->base + LAYERSCAPE_SFP_OTP_OFFSET + offset,
-		      bytes);
-
-	return 0;
+	return regmap_bulk_read(priv->regmap,
+				LAYERSCAPE_SFP_OTP_OFFSET + offset, val,
+				bytes / 4);
 }
 
 static struct nvmem_config layerscape_sfp_nvmem_config = {
 	.name = "fsl-sfp",
 	.reg_read = layerscape_sfp_read,
+	.word_size = 4,
+	.stride = 4,
 };
 
 static int layerscape_sfp_probe(struct platform_device *pdev)
@@ -45,16 +48,26 @@ static int layerscape_sfp_probe(struct platform_device *pdev)
 	const struct layerscape_sfp_data *data;
 	struct layerscape_sfp_priv *priv;
 	struct nvmem_device *nvmem;
+	struct regmap_config config = { 0 };
+	void __iomem *base;
 
 	priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL);
 	if (!priv)
 		return -ENOMEM;
 
-	priv->base = devm_platform_ioremap_resource(pdev, 0);
-	if (IS_ERR(priv->base))
-		return PTR_ERR(priv->base);
+	base = devm_platform_ioremap_resource(pdev, 0);
+	if (IS_ERR(base))
+		return PTR_ERR(base);
 
 	data = device_get_match_data(&pdev->dev);
+	config.reg_bits = 32;
+	config.reg_stride = 4;
+	config.val_bits = 32;
+	config.val_format_endian = data->endian;
+	config.max_register = LAYERSCAPE_SFP_OTP_OFFSET + data->size - 4;
+	priv->regmap = devm_regmap_init_mmio(&pdev->dev, base, &config);
+	if (IS_ERR(priv->regmap))
+		return PTR_ERR(priv->regmap);
 
 	layerscape_sfp_nvmem_config.size = data->size;
 	layerscape_sfp_nvmem_config.dev = &pdev->dev;
@@ -67,6 +80,7 @@ static int layerscape_sfp_probe(struct platform_device *pdev)
 
 static const struct layerscape_sfp_data ls1028a_data = {
 	.size = 0x88,
+	.endian = REGMAP_ENDIAN_LITTLE,
 };
 
 static const struct of_device_id layerscape_sfp_dt_ids[] = {
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [PATCH v3 9/9] nvmem: sfp: Add support for TA 2.1 devices
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (7 preceding siblings ...)
  2022-04-28 18:17 ` [PATCH v3 8/9] nvmem: sfp: Use regmap Sean Anderson
@ 2022-04-28 18:17 ` Sean Anderson
  2022-04-29 15:56 ` [PATCH v3 0/9] nvmem: sfp: binding updates and additions Srinivas Kandagatla
  9 siblings, 0 replies; 16+ messages in thread
From: Sean Anderson @ 2022-04-28 18:17 UTC (permalink / raw)
  To: linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Srinivas Kandagatla, Rob Herring,
	Shawn Guo, Krzysztof Kozlowski, Michael Walle, Andrew Lunn,
	Sean Anderson

This adds support for Trust Architecture (TA) 2.1 devices to the SFP driver.
There are few differences between TA 2.1 and TA 3.0, especially for
read-only support, so just re-use the existing data.

Signed-off-by: Sean Anderson <sean.anderson@seco.com>
---

(no changes since v1)

 drivers/nvmem/layerscape-sfp.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/nvmem/layerscape-sfp.c b/drivers/nvmem/layerscape-sfp.c
index 59083f048921..e2b424561949 100644
--- a/drivers/nvmem/layerscape-sfp.c
+++ b/drivers/nvmem/layerscape-sfp.c
@@ -78,12 +78,18 @@ static int layerscape_sfp_probe(struct platform_device *pdev)
 	return PTR_ERR_OR_ZERO(nvmem);
 }
 
+static const struct layerscape_sfp_data ls1021a_data = {
+	.size = 0x88,
+	.endian = REGMAP_ENDIAN_BIG,
+};
+
 static const struct layerscape_sfp_data ls1028a_data = {
 	.size = 0x88,
 	.endian = REGMAP_ENDIAN_LITTLE,
 };
 
 static const struct of_device_id layerscape_sfp_dt_ids[] = {
+	{ .compatible = "fsl,ls1021a-sfp", .data = &ls1021a_data },
 	{ .compatible = "fsl,ls1028a-sfp", .data = &ls1028a_data },
 	{},
 };
-- 
2.35.1.1320.gc452695387.dirty


^ permalink raw reply related	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 0/9] nvmem: sfp: binding updates and additions
  2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
                   ` (8 preceding siblings ...)
  2022-04-28 18:17 ` [PATCH v3 9/9] nvmem: sfp: Add support for TA 2.1 devices Sean Anderson
@ 2022-04-29 15:56 ` Srinivas Kandagatla
  2022-05-03 13:43   ` Michael Walle
  9 siblings, 1 reply; 16+ messages in thread
From: Srinivas Kandagatla @ 2022-04-29 15:56 UTC (permalink / raw)
  To: Sean Anderson, linux-arm-kernel, devicetree
  Cc: Li Yang, linux-kernel, Rob Herring, Shawn Guo,
	Krzysztof Kozlowski, Michael Walle, Andrew Lunn



On 28/04/2022 19:16, Sean Anderson wrote:
> This adds several properties to the Layerscape Security Fuse Processor
> (SFP) necessary for writing. Although the Linux driver does not use
> these bindings, I plan to use them in U-Boot [1]. It also adds a new
> compatibles for Trust Architecture (TA) 2.1 devices. In addition, it
> also adds an SFP binding for all TA 2.1 and 3.0 devices.
> 
> I would like to get this series merged for 5.18. As noted in patch 2,
> making the clock property mandatory is not an ABI break, but if this is
> not applied then it would become an ABI break. The absolute minimum
> patches to apply for this would be patches 2 and 5. The rest (including
> the regmap changes) could be deferred if necessary.
> 
> [1] https://lore.kernel.org/u-boot/7c8e206a-cd40-2a77-6282-7f4bead2b13a@seco.com/T/#m591f8425b6f096ab3d54e6f7bd258e41cfa4c43b
> 
> Changes in v3:
> - Update commit message to note that this binding has not yet been
>    present in a relase, so it is OK to make otherwise breaking changes.
> 
> Changes in v2:
> - Mention "regulator" in the description for ta-prog-sfp-supply
> - Convert sfp driver to use regmap
> - Fix various typos in commit messages
> 
> Sean Anderson (9):
>    dt-bindings: nvmem: sfp: Fix typo
>    dt-bindings: nvmem: sfp: Add clock properties
>    dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply
>    dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs
>    arm64: dts: ls1028a: Update SFP binding to include clock
>    ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
>    ARM: dts: Add SFP binding for TA 3.0 devices
>    nvmem: sfp: Use regmap
>    nvmem: sfp: Add support for TA 2.1 devices
> 

I have applied all the patches except 5/9, 6/9, and 7/9 dts patches 
which need to go via dts maintainer tree.

--srini

>   .../bindings/nvmem/fsl,layerscape-sfp.yaml    | 30 ++++++++++++++--
>   arch/arm/boot/dts/ls1021a.dtsi                |  7 ++++
>   .../arm64/boot/dts/freescale/fsl-ls1012a.dtsi |  8 +++++
>   .../arm64/boot/dts/freescale/fsl-ls1028a.dtsi |  5 ++-
>   .../arm64/boot/dts/freescale/fsl-ls1043a.dtsi |  8 +++++
>   .../arm64/boot/dts/freescale/fsl-ls1046a.dtsi |  8 +++++
>   .../arm64/boot/dts/freescale/fsl-ls1088a.dtsi |  8 +++++
>   .../arm64/boot/dts/freescale/fsl-ls208xa.dtsi |  8 +++++
>   .../arm64/boot/dts/freescale/fsl-lx2160a.dtsi |  8 +++++
>   drivers/nvmem/Kconfig                         |  1 +
>   drivers/nvmem/layerscape-sfp.c                | 36 ++++++++++++++-----
>   11 files changed, 115 insertions(+), 12 deletions(-)
> 

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 0/9] nvmem: sfp: binding updates and additions
  2022-04-29 15:56 ` [PATCH v3 0/9] nvmem: sfp: binding updates and additions Srinivas Kandagatla
@ 2022-05-03 13:43   ` Michael Walle
  2022-05-09  8:28     ` Michael Walle
  0 siblings, 1 reply; 16+ messages in thread
From: Michael Walle @ 2022-05-03 13:43 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: Sean Anderson, linux-arm-kernel, devicetree, Li Yang,
	linux-kernel, Rob Herring, Shawn Guo, Krzysztof Kozlowski,
	Andrew Lunn

Am 2022-04-29 17:56, schrieb Srinivas Kandagatla:
> On 28/04/2022 19:16, Sean Anderson wrote:
>> This adds several properties to the Layerscape Security Fuse Processor
>> (SFP) necessary for writing. Although the Linux driver does not use
>> these bindings, I plan to use them in U-Boot [1]. It also adds a new
>> compatibles for Trust Architecture (TA) 2.1 devices. In addition, it
>> also adds an SFP binding for all TA 2.1 and 3.0 devices.
>> 
>> I would like to get this series merged for 5.18. As noted in patch 2,
>> making the clock property mandatory is not an ABI break, but if this 
>> is
>> not applied then it would become an ABI break. The absolute minimum
>> patches to apply for this would be patches 2 and 5. The rest 
>> (including
>> the regmap changes) could be deferred if necessary.
>> 
>> [1] 
>> https://lore.kernel.org/u-boot/7c8e206a-cd40-2a77-6282-7f4bead2b13a@seco.com/T/#m591f8425b6f096ab3d54e6f7bd258e41cfa4c43b
>> 
>> Changes in v3:
>> - Update commit message to note that this binding has not yet been
>>    present in a relase, so it is OK to make otherwise breaking 
>> changes.
>> 
>> Changes in v2:
>> - Mention "regulator" in the description for ta-prog-sfp-supply
>> - Convert sfp driver to use regmap
>> - Fix various typos in commit messages
>> 
>> Sean Anderson (9):
>>    dt-bindings: nvmem: sfp: Fix typo
>>    dt-bindings: nvmem: sfp: Add clock properties
>>    dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply
>>    dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs
>>    arm64: dts: ls1028a: Update SFP binding to include clock
>>    ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
>>    ARM: dts: Add SFP binding for TA 3.0 devices
>>    nvmem: sfp: Use regmap
>>    nvmem: sfp: Add support for TA 2.1 devices
>> 
> 
> I have applied all the patches except 5/9, 6/9, and 7/9 dts patches
> which need to go via dts maintainer tree.

Ahh. At least the device tree binding change (and the device tree
changes itself) should be applied as fixes for the 5.18 release,
so we don't have any conflicting descriptions. My fixes tag was never
picked up, unfortunately:
https://lore.kernel.org/linux-devicetree/4a45db184fbadc278624571dfbeb5004@walle.cc/

Srinivas, I've seen you picked it up into your for-next branch.
Can we fix that?

I'd guess the layerscape device tree change also need a Fixes: tag.

-michael

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock
  2022-04-28 18:16 ` [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock Sean Anderson
@ 2022-05-03 13:47   ` Michael Walle
  2022-06-29 13:32     ` Shawn Guo
  0 siblings, 1 reply; 16+ messages in thread
From: Michael Walle @ 2022-05-03 13:47 UTC (permalink / raw)
  To: Sean Anderson
  Cc: linux-arm-kernel, devicetree, Li Yang, linux-kernel,
	Srinivas Kandagatla, Rob Herring, Shawn Guo, Krzysztof Kozlowski,
	Andrew Lunn

Am 2022-04-28 20:16, schrieb Sean Anderson:
> The clocks property is now mandatory. Add it.
> 
> Signed-off-by: Sean Anderson <sean.anderson@seco.com>
> Reviewed-by: Michael Walle <michael@walle.cc>

Fixes: eba5bea8f37f ("arm64: dts: ls1028a: add efuse node")

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 0/9] nvmem: sfp: binding updates and additions
  2022-05-03 13:43   ` Michael Walle
@ 2022-05-09  8:28     ` Michael Walle
  0 siblings, 0 replies; 16+ messages in thread
From: Michael Walle @ 2022-05-09  8:28 UTC (permalink / raw)
  To: Srinivas Kandagatla
  Cc: Sean Anderson, linux-arm-kernel, devicetree, Li Yang,
	linux-kernel, Rob Herring, Shawn Guo, Krzysztof Kozlowski,
	Andrew Lunn

Am 2022-05-03 15:43, schrieb Michael Walle:
> Am 2022-04-29 17:56, schrieb Srinivas Kandagatla:
>> On 28/04/2022 19:16, Sean Anderson wrote:
>>> This adds several properties to the Layerscape Security Fuse 
>>> Processor
>>> (SFP) necessary for writing. Although the Linux driver does not use
>>> these bindings, I plan to use them in U-Boot [1]. It also adds a new
>>> compatibles for Trust Architecture (TA) 2.1 devices. In addition, it
>>> also adds an SFP binding for all TA 2.1 and 3.0 devices.
>>> 
>>> I would like to get this series merged for 5.18. As noted in patch 2,
>>> making the clock property mandatory is not an ABI break, but if this 
>>> is
>>> not applied then it would become an ABI break. The absolute minimum
>>> patches to apply for this would be patches 2 and 5. The rest 
>>> (including
>>> the regmap changes) could be deferred if necessary.
>>> 
>>> [1] 
>>> https://lore.kernel.org/u-boot/7c8e206a-cd40-2a77-6282-7f4bead2b13a@seco.com/T/#m591f8425b6f096ab3d54e6f7bd258e41cfa4c43b
>>> 
>>> Changes in v3:
>>> - Update commit message to note that this binding has not yet been
>>>    present in a relase, so it is OK to make otherwise breaking 
>>> changes.
>>> 
>>> Changes in v2:
>>> - Mention "regulator" in the description for ta-prog-sfp-supply
>>> - Convert sfp driver to use regmap
>>> - Fix various typos in commit messages
>>> 
>>> Sean Anderson (9):
>>>    dt-bindings: nvmem: sfp: Fix typo
>>>    dt-bindings: nvmem: sfp: Add clock properties
>>>    dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply
>>>    dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs
>>>    arm64: dts: ls1028a: Update SFP binding to include clock
>>>    ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
>>>    ARM: dts: Add SFP binding for TA 3.0 devices
>>>    nvmem: sfp: Use regmap
>>>    nvmem: sfp: Add support for TA 2.1 devices
>>> 
>> 
>> I have applied all the patches except 5/9, 6/9, and 7/9 dts patches
>> which need to go via dts maintainer tree.
> 
> Ahh. At least the device tree binding change (and the device tree
> changes itself) should be applied as fixes for the 5.18 release,
> so we don't have any conflicting descriptions. My fixes tag was never
> picked up, unfortunately:
> https://lore.kernel.org/linux-devicetree/4a45db184fbadc278624571dfbeb5004@walle.cc/
> 
> Srinivas, I've seen you picked it up into your for-next branch.
> Can we fix that?
> 
> I'd guess the layerscape device tree change also need a Fixes: tag.

Ping. We are now -rc7 :/

-michael

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock
  2022-05-03 13:47   ` Michael Walle
@ 2022-06-29 13:32     ` Shawn Guo
  0 siblings, 0 replies; 16+ messages in thread
From: Shawn Guo @ 2022-06-29 13:32 UTC (permalink / raw)
  To: Michael Walle
  Cc: Sean Anderson, linux-arm-kernel, devicetree, Li Yang,
	linux-kernel, Srinivas Kandagatla, Rob Herring,
	Krzysztof Kozlowski, Andrew Lunn

On Tue, May 03, 2022 at 03:47:51PM +0200, Michael Walle wrote:
> Am 2022-04-28 20:16, schrieb Sean Anderson:
> > The clocks property is now mandatory. Add it.
> > 
> > Signed-off-by: Sean Anderson <sean.anderson@seco.com>
> > Reviewed-by: Michael Walle <michael@walle.cc>
> 
> Fixes: eba5bea8f37f ("arm64: dts: ls1028a: add efuse node")

Applied, thanks!

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices
  2022-04-28 18:17 ` [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices Sean Anderson
@ 2022-06-29 13:34   ` Shawn Guo
  0 siblings, 0 replies; 16+ messages in thread
From: Shawn Guo @ 2022-06-29 13:34 UTC (permalink / raw)
  To: Sean Anderson
  Cc: linux-arm-kernel, devicetree, Li Yang, linux-kernel,
	Srinivas Kandagatla, Rob Herring, Krzysztof Kozlowski,
	Michael Walle, Andrew Lunn

On Thu, Apr 28, 2022 at 02:17:00PM -0400, Sean Anderson wrote:
> This adds an appropriate SFP binding for Trust Architecture 2.1 devices.
> 
> Signed-off-by: Sean Anderson <sean.anderson@seco.com>
> ---
> 
> (no changes since v1)
> 
>  arch/arm/boot/dts/ls1021a.dtsi                 | 7 +++++++

Separate patches for arm and arm64 DTS, please.

Also prefix arm patches like 'ARM: dts: ...', while 'arm64: dts: ...'
for arm64 ones.

Shawn

>  arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi | 8 ++++++++
>  arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi | 8 ++++++++
>  arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi | 8 ++++++++
>  4 files changed, 31 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/ls1021a.dtsi b/arch/arm/boot/dts/ls1021a.dtsi
> index 2e69d6eab4d1..c1e94a317cba 100644
> --- a/arch/arm/boot/dts/ls1021a.dtsi
> +++ b/arch/arm/boot/dts/ls1021a.dtsi
> @@ -129,6 +129,13 @@ ifc: ifc@1530000 {
>  			status = "disabled";
>  		};
>  
> +		sfp: efuse@1e80000 {
> +			compatible = "fsl,ls1021a-sfp";
> +			reg = <0x0 0x1e80000 0x0 0x10000>;
> +			clocks = <&clockgen 4 3>;
> +			clock-names = "sfp";
> +		};
> +
>  		dcfg: dcfg@1ee0000 {
>  			compatible = "fsl,ls1021a-dcfg", "syscon";
>  			reg = <0x0 0x1ee0000 0x0 0x1000>;
> diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
> index 50a72cda4727..47ce525e0a72 100644
> --- a/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
> +++ b/arch/arm64/boot/dts/freescale/fsl-ls1012a.dtsi
> @@ -271,6 +271,14 @@ rtic_d: rtic-d@60 {
>  			};
>  		};
>  
> +		sfp: efuse@1e80000 {
> +			compatible = "fsl,ls1021a-sfp";
> +			reg = <0x0 0x1e80000 0x0 0x10000>;
> +			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
> +					    QORIQ_CLK_PLL_DIV(4)>;
> +			clock-names = "sfp";
> +		};
> +
>  		sec_mon: sec_mon@1e90000 {
>  			compatible = "fsl,sec-v5.4-mon", "fsl,sec-v5.0-mon",
>  				     "fsl,sec-v4.0-mon";
> diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
> index 35d1939e690b..b0ab0b19de7e 100644
> --- a/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
> +++ b/arch/arm64/boot/dts/freescale/fsl-ls1043a.dtsi
> @@ -383,6 +383,14 @@ sec_jr3: jr@40000 {
>  			};
>  		};
>  
> +		sfp: efuse@1e80000 {
> +			compatible = "fsl,ls1021a-sfp";
> +			reg = <0x0 0x1e80000 0x0 0x10000>;
> +			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
> +					    QORIQ_CLK_PLL_DIV(4)>;
> +			clock-names = "sfp";
> +		};
> +
>  		dcfg: dcfg@1ee0000 {
>  			compatible = "fsl,ls1043a-dcfg", "syscon";
>  			reg = <0x0 0x1ee0000 0x0 0x10000>;
> diff --git a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
> index 4e7bd04d9798..c30056afc02a 100644
> --- a/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
> +++ b/arch/arm64/boot/dts/freescale/fsl-ls1046a.dtsi
> @@ -413,6 +413,14 @@ bportals: bman-portals@508000000 {
>  			ranges = <0x0 0x5 0x08000000 0x8000000>;
>  		};
>  
> +		sfp: efuse@1e80000 {
> +			compatible = "fsl,ls1021a-sfp";
> +			reg = <0x0 0x1e80000 0x0 0x10000>;
> +			clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
> +					    QORIQ_CLK_PLL_DIV(4)>;
> +			clock-names = "sfp";
> +		};
> +
>  		dcfg: dcfg@1ee0000 {
>  			compatible = "fsl,ls1046a-dcfg", "syscon";
>  			reg = <0x0 0x1ee0000 0x0 0x1000>;
> -- 
> 2.35.1.1320.gc452695387.dirty
> 

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2022-06-29 13:34 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-28 18:16 [PATCH v3 0/9] nvmem: sfp: binding updates and additions Sean Anderson
2022-04-28 18:16 ` [PATCH v3 1/9] dt-bindings: nvmem: sfp: Fix typo Sean Anderson
2022-04-28 18:16 ` [PATCH v3 2/9] dt-bindings: nvmem: sfp: Add clock properties Sean Anderson
2022-04-28 18:16 ` [PATCH v3 3/9] dt-bindings: nvmem: sfp: Add TA_PROG_SFP supply Sean Anderson
2022-04-28 18:16 ` [PATCH v3 4/9] dt-bindings: nvmem: sfp: Add compatible binding for TA 2.1 SFPs Sean Anderson
2022-04-28 18:16 ` [PATCH v3 5/9] arm64: dts: ls1028a: Update SFP binding to include clock Sean Anderson
2022-05-03 13:47   ` Michael Walle
2022-06-29 13:32     ` Shawn Guo
2022-04-28 18:17 ` [PATCH v3 6/9] ARM: dts: layerscape: Add SFP binding for TA 2.1 devices Sean Anderson
2022-06-29 13:34   ` Shawn Guo
2022-04-28 18:17 ` [PATCH v3 7/9] ARM: dts: Add SFP binding for TA 3.0 devices Sean Anderson
2022-04-28 18:17 ` [PATCH v3 8/9] nvmem: sfp: Use regmap Sean Anderson
2022-04-28 18:17 ` [PATCH v3 9/9] nvmem: sfp: Add support for TA 2.1 devices Sean Anderson
2022-04-29 15:56 ` [PATCH v3 0/9] nvmem: sfp: binding updates and additions Srinivas Kandagatla
2022-05-03 13:43   ` Michael Walle
2022-05-09  8:28     ` Michael Walle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).