Tom Rini | 6bb92fc | 2024-05-20 09:54:58 -0600 | [diff] [blame] | 1 | # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) |
| 2 | %YAML 1.2 |
| 3 | --- |
| 4 | $id: http://devicetree.org/schemas/pinctrl/mobileye,eyeq5-pinctrl.yaml# |
| 5 | $schema: http://devicetree.org/meta-schemas/core.yaml# |
| 6 | |
| 7 | title: Mobileye EyeQ5 pin controller |
| 8 | |
| 9 | description: > |
| 10 | The EyeQ5 pin controller handles the two pin banks of the system. It belongs |
| 11 | to a system-controller block called OLB. |
| 12 | |
| 13 | Pin control is about bias (pull-down, pull-up), drive strength and muxing. Pin |
| 14 | muxing supports two functions for each pin: first is GPIO, second is |
| 15 | pin-dependent. |
| 16 | |
| 17 | Pins and groups are bijective. |
| 18 | |
| 19 | maintainers: |
| 20 | - Grégory Clement <gregory.clement@bootlin.com> |
| 21 | - Théo Lebrun <theo.lebrun@bootlin.com> |
| 22 | - Vladimir Kondratiev <vladimir.kondratiev@mobileye.com> |
| 23 | |
| 24 | $ref: pinctrl.yaml# |
| 25 | |
| 26 | properties: |
| 27 | compatible: |
| 28 | enum: |
| 29 | - mobileye,eyeq5-pinctrl |
| 30 | |
| 31 | reg: |
| 32 | maxItems: 1 |
| 33 | |
| 34 | patternProperties: |
| 35 | "-pins?$": |
| 36 | type: object |
| 37 | description: Pin muxing configuration. |
| 38 | $ref: pinmux-node.yaml# |
| 39 | additionalProperties: false |
| 40 | properties: |
| 41 | pins: true |
| 42 | function: |
| 43 | enum: [gpio, |
| 44 | # Bank A |
| 45 | timer0, timer1, timer2, timer5, uart0, uart1, can0, can1, spi0, |
| 46 | spi1, refclk0, |
| 47 | # Bank B |
| 48 | timer3, timer4, timer6, uart2, can2, spi2, spi3, mclk0] |
| 49 | bias-disable: true |
| 50 | bias-pull-down: true |
| 51 | bias-pull-up: true |
| 52 | drive-strength: true |
| 53 | required: |
| 54 | - pins |
| 55 | - function |
| 56 | allOf: |
| 57 | - if: |
| 58 | properties: |
| 59 | function: |
| 60 | const: gpio |
| 61 | then: |
| 62 | properties: |
| 63 | pins: |
| 64 | items: # PA0 - PA28, PB0 - PB22 |
| 65 | pattern: '^(P(A|B)1?[0-9]|PA2[0-8]|PB2[0-2])$' |
| 66 | - if: |
| 67 | properties: |
| 68 | function: |
| 69 | const: timer0 |
| 70 | then: |
| 71 | properties: |
| 72 | pins: |
| 73 | items: |
| 74 | enum: [PA0, PA1] |
| 75 | - if: |
| 76 | properties: |
| 77 | function: |
| 78 | const: timer1 |
| 79 | then: |
| 80 | properties: |
| 81 | pins: |
| 82 | items: |
| 83 | enum: [PA2, PA3] |
| 84 | - if: |
| 85 | properties: |
| 86 | function: |
| 87 | const: timer2 |
| 88 | then: |
| 89 | properties: |
| 90 | pins: |
| 91 | items: |
| 92 | enum: [PA4, PA5] |
| 93 | - if: |
| 94 | properties: |
| 95 | function: |
| 96 | const: timer5 |
| 97 | then: |
| 98 | properties: |
| 99 | pins: |
| 100 | items: |
| 101 | enum: [PA6, PA7, PA8, PA9] |
| 102 | - if: |
| 103 | properties: |
| 104 | function: |
| 105 | const: uart0 |
| 106 | then: |
| 107 | properties: |
| 108 | pins: |
| 109 | items: |
| 110 | enum: [PA10, PA11] |
| 111 | - if: |
| 112 | properties: |
| 113 | function: |
| 114 | const: uart1 |
| 115 | then: |
| 116 | properties: |
| 117 | pins: |
| 118 | items: |
| 119 | enum: [PA12, PA13] |
| 120 | - if: |
| 121 | properties: |
| 122 | function: |
| 123 | const: can0 |
| 124 | then: |
| 125 | properties: |
| 126 | pins: |
| 127 | items: |
| 128 | enum: [PA14, PA15] |
| 129 | - if: |
| 130 | properties: |
| 131 | function: |
| 132 | const: can1 |
| 133 | then: |
| 134 | properties: |
| 135 | pins: |
| 136 | items: |
| 137 | enum: [PA16, PA17] |
| 138 | - if: |
| 139 | properties: |
| 140 | function: |
| 141 | const: spi0 |
| 142 | then: |
| 143 | properties: |
| 144 | pins: |
| 145 | items: |
| 146 | enum: [PA18, PA19, PA20, PA21, PA22] |
| 147 | - if: |
| 148 | properties: |
| 149 | function: |
| 150 | const: spi1 |
| 151 | then: |
| 152 | properties: |
| 153 | pins: |
| 154 | items: |
| 155 | enum: [PA23, PA24, PA25, PA26, PA27] |
| 156 | - if: |
| 157 | properties: |
| 158 | function: |
| 159 | const: refclk0 |
| 160 | then: |
| 161 | properties: |
| 162 | pins: |
| 163 | items: |
| 164 | enum: [PA28] |
| 165 | - if: |
| 166 | properties: |
| 167 | function: |
| 168 | const: timer3 |
| 169 | then: |
| 170 | properties: |
| 171 | pins: |
| 172 | items: |
| 173 | enum: [PB0, PB1] |
| 174 | - if: |
| 175 | properties: |
| 176 | function: |
| 177 | const: timer4 |
| 178 | then: |
| 179 | properties: |
| 180 | pins: |
| 181 | items: |
| 182 | enum: [PB2, PB3] |
| 183 | - if: |
| 184 | properties: |
| 185 | function: |
| 186 | const: timer6 |
| 187 | then: |
| 188 | properties: |
| 189 | pins: |
| 190 | items: |
| 191 | enum: [PB4, PB5, PB6, PB7] |
| 192 | - if: |
| 193 | properties: |
| 194 | function: |
| 195 | const: uart2 |
| 196 | then: |
| 197 | properties: |
| 198 | pins: |
| 199 | items: |
| 200 | enum: [PB8, PB9] |
| 201 | - if: |
| 202 | properties: |
| 203 | function: |
| 204 | const: can2 |
| 205 | then: |
| 206 | properties: |
| 207 | pins: |
| 208 | items: |
| 209 | enum: [PB10, PB11] |
| 210 | - if: |
| 211 | properties: |
| 212 | function: |
| 213 | const: spi2 |
| 214 | then: |
| 215 | properties: |
| 216 | pins: |
| 217 | items: |
| 218 | enum: [PB12, PB13, PB14, PB15, PB16] |
| 219 | - if: |
| 220 | properties: |
| 221 | function: |
| 222 | const: spi3 |
| 223 | then: |
| 224 | properties: |
| 225 | pins: |
| 226 | items: |
| 227 | enum: [PB17, PB18, PB19, PB20, PB21] |
| 228 | - if: |
| 229 | properties: |
| 230 | function: |
| 231 | const: mclk0 |
| 232 | then: |
| 233 | properties: |
| 234 | pins: |
| 235 | items: |
| 236 | enum: [PB22] |
| 237 | |
| 238 | required: |
| 239 | - compatible |
| 240 | - reg |
| 241 | |
| 242 | additionalProperties: false |