Skip to content

Commit e624dc5

Browse files
authored
Enable Inline crypto engine for kodiak and monaco (#439)
Enable Inline crypto engine for kodiak and monaco
2 parents 8cda12a + a104fa1 commit e624dc5

3 files changed

Lines changed: 85 additions & 28 deletions

File tree

Documentation/devicetree/bindings/mmc/sdhci-msm.yaml

Lines changed: 67 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,11 @@ properties:
139139
$ref: /schemas/types.yaml#/definitions/uint32
140140
description: platform specific settings for DLL_CONFIG reg.
141141

142+
qcom,ice:
143+
$ref: /schemas/types.yaml#/definitions/phandle
144+
description:
145+
phandle to the Inline Crypto Engine (ICE) hardware block for this controller.
146+
142147
iommus:
143148
minItems: 1
144149
maxItems: 8
@@ -192,35 +197,69 @@ allOf:
192197
enum:
193198
- qcom,sdhci-msm-v4
194199
then:
195-
properties:
196-
reg:
197-
minItems: 2
198-
items:
199-
- description: Host controller register map
200-
- description: SD Core register map
201-
- description: CQE register map
202-
- description: Inline Crypto Engine register map
203-
reg-names:
204-
minItems: 2
205-
items:
206-
- const: hc
207-
- const: core
208-
- const: cqhci
209-
- const: ice
200+
if:
201+
required:
202+
- qcom,ice
203+
then:
204+
properties:
205+
reg:
206+
minItems: 2
207+
items:
208+
- description: Host controller register map
209+
- description: SD Core register map
210+
- description: CQE register map
211+
reg-names:
212+
minItems: 2
213+
items:
214+
- const: hc
215+
- const: core
216+
- const: cqhci
217+
else:
218+
properties:
219+
reg:
220+
minItems: 2
221+
items:
222+
- description: Host controller register map
223+
- description: SD Core register map
224+
- description: CQE register map
225+
- description: Inline Crypto Engine register map
226+
reg-names:
227+
minItems: 2
228+
items:
229+
- const: hc
230+
- const: core
231+
- const: cqhci
232+
- const: ice
210233
else:
211-
properties:
212-
reg:
213-
minItems: 1
214-
items:
215-
- description: Host controller register map
216-
- description: CQE register map
217-
- description: Inline Crypto Engine register map
218-
reg-names:
219-
minItems: 1
220-
items:
221-
- const: hc
222-
- const: cqhci
223-
- const: ice
234+
if:
235+
required:
236+
- qcom,ice
237+
then:
238+
properties:
239+
reg:
240+
minItems: 1
241+
items:
242+
- description: Host controller register map
243+
- description: CQE register map
244+
reg-names:
245+
minItems: 1
246+
items:
247+
- const: hc
248+
- const: cqhci
249+
else:
250+
properties:
251+
reg:
252+
minItems: 1
253+
items:
254+
- description: Host controller register map
255+
- description: CQE register map
256+
- description: Inline Crypto Engine register map
257+
reg-names:
258+
minItems: 1
259+
items:
260+
- const: hc
261+
- const: cqhci
262+
- const: ice
224263

225264
unevaluatedProperties: false
226265

arch/arm64/boot/dts/qcom/monaco.dtsi

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4533,6 +4533,8 @@
45334533
supports-cqe;
45344534
dma-coherent;
45354535

4536+
qcom,ice = <&sdhc_ice>;
4537+
45364538
status = "disabled";
45374539

45384540
sdhc1_opp_table: opp-table {
@@ -4560,6 +4562,13 @@
45604562
};
45614563
};
45624564

4565+
sdhc_ice: crypto@87c8000 {
4566+
compatible = "qcom,qcs8300-inline-crypto-engine",
4567+
"qcom,inline-crypto-engine";
4568+
reg = <0x0 0x087c8000 0x0 0x18000>;
4569+
clocks = <&gcc GCC_SDCC1_ICE_CORE_CLK>;
4570+
};
4571+
45634572
usb_1_hsphy: phy@8904000 {
45644573
compatible = "qcom,qcs8300-usb-hs-phy",
45654574
"qcom,usb-snps-hs-7nm-phy";

arch/arm64/boot/dts/qcom/sc7280.dtsi

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1050,6 +1050,8 @@
10501050
qcom,dll-config = <0x0007642c>;
10511051
qcom,ddr-config = <0x80040868>;
10521052

1053+
qcom,ice = <&sdhc_ice>;
1054+
10531055
mmc-ddr-1_8v;
10541056
mmc-hs200-1_8v;
10551057
mmc-hs400-1_8v;
@@ -1076,6 +1078,13 @@
10761078
};
10771079
};
10781080

1081+
sdhc_ice: crypto@7c8000 {
1082+
compatible = "qcom,sc7280-inline-crypto-engine",
1083+
"qcom,inline-crypto-engine";
1084+
reg = <0x0 0x007c8000 0x0 0x18000>;
1085+
clocks = <&gcc GCC_SDCC1_ICE_CORE_CLK>;
1086+
};
1087+
10791088
gpi_dma0: dma-controller@900000 {
10801089
#dma-cells = <3>;
10811090
compatible = "qcom,sc7280-gpi-dma", "qcom,sm6350-gpi-dma";

0 commit comments

Comments
 (0)