Skip to contentSkip to conversation

dt-bindings: crypto: inside-secure,safexcel: add compatible for MT7981

PATCH In review Aleksander Jan Bajkowski 3 participants 4 messages Mar 3 – Mar 14

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

PATCH v3 1/2 dt-bindings: crypto: inside-secure,safexcel: add compatible for MT7981

The MT7981 as well as the MT7986 have a built-in EIP-97 crypto accelerator. This commit adds a compatible string for MT7981.

---
v3:
- drop oneOf
v2:
- just add compatible strings

---
 .../devicetree/bindings/crypto/inside-secure,safexcel.yaml   | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
Documentation/devicetree/bindings/crypto/inside-secure,safexcel.yaml +4 -1
index 3dc6c5f89d32..a34d13e92c59 100644
@@ -18,6 +18,7 @@ properties:
       - items:
           - enum:
               - marvell,armada-3700-crypto
+              - mediatek,mt7981-crypto
               - mediatek,mt7986-crypto
           - const: inside-secure,safexcel-eip97ies
       - const: inside-secure,safexcel-eip197b
@@ -80,7 +81,9 @@ allOf:
         compatible:
           not:
             contains:
-              const: mediatek,mt7986-crypto
+              enum:
+                - mediatek,mt7981-crypto
+                - mediatek,mt7986-crypto
     then:
       properties:
         interrupts:
Signature · 1 line
2.47.3
#1 lore raw

PATCH v3 2/2 arm64: dts: mediatek: add crypto offload support on MT7981

The MT7981 as well as the MT7986 have a built-in EIP-97 crypto accelerator. This commit adds the missing entry in the dts.

---
 arch/arm64/boot/dts/mediatek/mt7981b.dtsi | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
arch/arm64/boot/dts/mediatek/mt7981b.dtsi +15 -0
index 4084f4dfa3e5..94c7bf0050fc 100644
@@ -150,6 +150,21 @@ sgmiisys1: syscon@10070000 {
 			#clock-cells = <1>;
 		};
 
+		crypto@10320000 {
+			compatible = "mediatek,mt7981-crypto",
+				"inside-secure,safexcel-eip97ies";
+			reg = <0 0x10320000 0 0x40000>;
+			interrupts = <GIC_SPI 116 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 117 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 118 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 119 IRQ_TYPE_LEVEL_HIGH>;
+			interrupt-names = "ring0", "ring1", "ring2", "ring3";
+			clocks = <&topckgen CLK_TOP_EIP97B>;
+			clock-names = "core";
+			assigned-clocks = <&topckgen CLK_TOP_EIP97B_SEL>;
+			assigned-clock-parents = <&topckgen CLK_TOP_CB_NET1_D5>;
+		};
+
 		uart0: serial@11002000 {
 			compatible = "mediatek,mt7981-uart", "mediatek,mt6577-uart";
 			reg = <0 0x11002000 0 0x100>;
Signature · 1 line
2.47.3
maintainer
#3 lore raw
In reply to Aleksander Jan Bajkowski
Quoted 5 lines · Aleksander Jan Bajkowski

The MT7981 as well as the MT7986 have a built-in EIP-97 crypto accelerator. This commit adds a compatible string for MT7981.

Quoted 8 lines

---
v3:
- drop oneOf
v2:
- just add compatible strings

---
 .../devicetree/bindings/crypto/inside-secure,safexcel.yaml   | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Patch applied. Thanks.

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt