starfive: add new target for StarFive JH7100/7110 SoC
[openwrt/staging/981213.git] / target / linux / starfive / patches-6.1 / 0111-dt-bindings-dma-snps-dw-axi-dmac-constrain-the-items.patch
1 From c2f59eeeee68bb66a3db8555474fe94e73b65b02 Mon Sep 17 00:00:00 2001
2 From: Walker Chen <walker.chen@starfivetech.com>
3 Date: Wed, 22 Mar 2023 17:48:17 +0800
4 Subject: [PATCH 111/122] dt-bindings: dma: snps,dw-axi-dmac: constrain the
5 items of resets for JH7110 dma
6
7 The DMA controller needs two reset items to work properly on JH7110 SoC,
8 so there is need to constrain the items' value to 2, other platforms
9 have 1 reset item at most.
10
11 Reviewed-by: Rob Herring <robh@kernel.org>
12 Signed-off-by: Walker Chen <walker.chen@starfivetech.com>
13 ---
14 .../bindings/dma/snps,dw-axi-dmac.yaml | 23 ++++++++++++++++++-
15 1 file changed, 22 insertions(+), 1 deletion(-)
16
17 --- a/Documentation/devicetree/bindings/dma/snps,dw-axi-dmac.yaml
18 +++ b/Documentation/devicetree/bindings/dma/snps,dw-axi-dmac.yaml
19 @@ -21,6 +21,7 @@ properties:
20 enum:
21 - snps,axi-dma-1.01a
22 - intel,kmb-axi-dma
23 + - starfive,jh7110-axi-dma
24
25 reg:
26 minItems: 1
27 @@ -59,7 +60,8 @@ properties:
28 maximum: 8
29
30 resets:
31 - maxItems: 1
32 + minItems: 1
33 + maxItems: 2
34
35 snps,dma-masters:
36 description: |
37 @@ -110,6 +112,25 @@ required:
38 - snps,priority
39 - snps,block-size
40
41 +if:
42 + properties:
43 + compatible:
44 + contains:
45 + enum:
46 + - starfive,jh7110-axi-dma
47 +then:
48 + properties:
49 + resets:
50 + minItems: 2
51 + items:
52 + - description: AXI reset line
53 + - description: AHB reset line
54 + - description: module reset
55 +else:
56 + properties:
57 + resets:
58 + maxItems: 1
59 +
60 additionalProperties: false
61
62 examples: