|
| 1 | +/* |
| 2 | + * Copyright (c) 2025 STMicroelectronics |
| 3 | + * |
| 4 | + * SPDX-License-Identifier: Apache-2.0 |
| 5 | + */ |
| 6 | + |
| 7 | +#include <arm/armv7-a.dtsi> |
| 8 | + |
| 9 | +#include <freq.h> |
| 10 | +#include <mem.h> |
| 11 | + |
| 12 | +#include <zephyr/dt-bindings/clock/stm32mp13_clock.h> |
| 13 | +#include <zephyr/dt-bindings/gpio/gpio.h> |
| 14 | +#include <zephyr/dt-bindings/interrupt-controller/arm-gic.h> |
| 15 | +#include <zephyr/dt-bindings/reset/stm32mp13_reset.h> |
| 16 | + |
| 17 | +/ { |
| 18 | + cpus { |
| 19 | + #address-cells = <1>; |
| 20 | + #size-cells = <0>; |
| 21 | + |
| 22 | + cpu0: cpu@0 { |
| 23 | + compatible = "arm,cortex-a7"; |
| 24 | + device_type = "cpu"; |
| 25 | + reg = <0>; |
| 26 | + }; |
| 27 | + }; |
| 28 | + |
| 29 | + soc { |
| 30 | + interrupt-parent = <&gic>; |
| 31 | + |
| 32 | + sysram: memory@2ffe0000 { |
| 33 | + compatible = "mmio-sram"; |
| 34 | + reg = <0x2FFE0000 DT_SIZE_K(128)>; |
| 35 | + }; |
| 36 | + |
| 37 | + uart4: serial@40010000 { |
| 38 | + compatible = "st,stm32-uart"; |
| 39 | + reg = <0x40010000 0x400>; |
| 40 | + clocks = <&rcc STM32_CLOCK(APB1, 16)>; |
| 41 | + resets = <&rctl STM32_RESET(APB1, 16)>; |
| 42 | + interrupts = <GIC_SPI 53 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>; |
| 43 | + status = "disabled"; |
| 44 | + }; |
| 45 | + |
| 46 | + rcc: rcc@50000000 { |
| 47 | + compatible = "st,stm32-rcc"; |
| 48 | + reg = <0x50000000 0x1000>; |
| 49 | + #clock-cells = <2>; |
| 50 | + |
| 51 | + rctl: reset-controller { |
| 52 | + compatible = "st,stm32-rcc-rctl"; |
| 53 | + #reset-cells = <1>; |
| 54 | + set-bit-to-deassert; |
| 55 | + }; |
| 56 | + }; |
| 57 | + |
| 58 | + pinctrl: pin-controller@50002000 { |
| 59 | + compatible = "st,stm32-pinctrl"; |
| 60 | + reg = <0x50002000 0x9000>; |
| 61 | + #address-cells = <1>; |
| 62 | + #size-cells = <1>; |
| 63 | + |
| 64 | + gpioa: gpio@50002000 { |
| 65 | + compatible = "st,stm32-gpio"; |
| 66 | + reg = <0x50002000 0x400>; |
| 67 | + gpio-controller; |
| 68 | + #gpio-cells = <2>; |
| 69 | + clocks = <&rcc STM32_CLOCK(AHB4, 0)>; |
| 70 | + }; |
| 71 | + |
| 72 | + gpiob: gpio@50003000 { |
| 73 | + compatible = "st,stm32-gpio"; |
| 74 | + reg = <0x50003000 0x400>; |
| 75 | + gpio-controller; |
| 76 | + #gpio-cells = <2>; |
| 77 | + clocks = <&rcc STM32_CLOCK(AHB4, 1)>; |
| 78 | + }; |
| 79 | + |
| 80 | + gpioc: gpio@50004000 { |
| 81 | + compatible = "st,stm32-gpio"; |
| 82 | + reg = <0x50004000 0x400>; |
| 83 | + gpio-controller; |
| 84 | + #gpio-cells = <2>; |
| 85 | + clocks = <&rcc STM32_CLOCK(AHB4, 2)>; |
| 86 | + }; |
| 87 | + |
| 88 | + gpiod: gpio@50005000 { |
| 89 | + compatible = "st,stm32-gpio"; |
| 90 | + reg = <0x50005000 0x400>; |
| 91 | + gpio-controller; |
| 92 | + #gpio-cells = <2>; |
| 93 | + clocks = <&rcc STM32_CLOCK(AHB4, 3)>; |
| 94 | + }; |
| 95 | + |
| 96 | + gpioe: gpio@50006000 { |
| 97 | + compatible = "st,stm32-gpio"; |
| 98 | + reg = <0x50006000 0x400>; |
| 99 | + gpio-controller; |
| 100 | + #gpio-cells = <2>; |
| 101 | + clocks = <&rcc STM32_CLOCK(AHB4, 4)>; |
| 102 | + }; |
| 103 | + |
| 104 | + gpiof: gpio@50007000 { |
| 105 | + compatible = "st,stm32-gpio"; |
| 106 | + reg = <0x50007000 0x400>; |
| 107 | + gpio-controller; |
| 108 | + #gpio-cells = <2>; |
| 109 | + clocks = <&rcc STM32_CLOCK(AHB4, 5)>; |
| 110 | + }; |
| 111 | + |
| 112 | + gpiog: gpio@50008000 { |
| 113 | + compatible = "st,stm32-gpio"; |
| 114 | + reg = <0x50008000 0x400>; |
| 115 | + gpio-controller; |
| 116 | + #gpio-cells = <2>; |
| 117 | + clocks = <&rcc STM32_CLOCK(AHB4, 6)>; |
| 118 | + }; |
| 119 | + |
| 120 | + gpioh: gpio@50009000 { |
| 121 | + compatible = "st,stm32-gpio"; |
| 122 | + reg = <0x50009000 0x400>; |
| 123 | + gpio-controller; |
| 124 | + #gpio-cells = <2>; |
| 125 | + clocks = <&rcc STM32_CLOCK(AHB4, 7)>; |
| 126 | + }; |
| 127 | + |
| 128 | + gpioi: gpio@5000a000 { |
| 129 | + compatible = "st,stm32-gpio"; |
| 130 | + reg = <0x5000a000 0x400>; |
| 131 | + gpio-controller; |
| 132 | + #gpio-cells = <2>; |
| 133 | + clocks = <&rcc STM32_CLOCK(AHB4, 8)>; |
| 134 | + }; |
| 135 | + }; |
| 136 | + |
| 137 | + exti: interrupt-controller@5000d000 { |
| 138 | + compatible = "st,stm32g0-exti","st,stm32-exti"; |
| 139 | + interrupt-controller; |
| 140 | + #interrupt-cells = <1>; |
| 141 | + #address-cells = <1>; |
| 142 | + reg = <0x5000D000 0x400>; |
| 143 | + num-lines = <16>; |
| 144 | + interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 145 | + <GIC_SPI 7 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 146 | + <GIC_SPI 8 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 147 | + <GIC_SPI 9 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 148 | + <GIC_SPI 10 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 149 | + <GIC_SPI 24 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 150 | + <GIC_SPI 65 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 151 | + <GIC_SPI 66 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 152 | + <GIC_SPI 67 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 153 | + <GIC_SPI 68 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 154 | + <GIC_SPI 41 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 155 | + <GIC_SPI 43 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 156 | + <GIC_SPI 77 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 157 | + <GIC_SPI 78 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 158 | + <GIC_SPI 106 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 159 | + <GIC_SPI 109 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>; |
| 160 | + interrupt-names = "line0", "line1", "line2", "line3", |
| 161 | + "line4", "line5", "line6", "line7", |
| 162 | + "line8", "line9", "line10", "line11", |
| 163 | + "line12", "line13", "line14", "line15"; |
| 164 | + line-ranges = <0 1>, <1 1>, <2 1>, <3 1>, |
| 165 | + <4 1>, <5 1>, <6 1>, <7 1>, |
| 166 | + <8 1>, <9 1>, <10 1>, <11 1>, |
| 167 | + <12 1>, <13 1>, <14 1>, <15 1>; |
| 168 | + }; |
| 169 | + }; |
| 170 | + |
| 171 | + gic: gic@A0021000 { |
| 172 | + compatible = "arm,gic-v2", "arm,gic"; |
| 173 | + reg = <0xA0021000 0x1000>, |
| 174 | + <0xA0022000 0x2000>; |
| 175 | + interrupt-controller; |
| 176 | + #interrupt-cells = <4>; |
| 177 | + status = "okay"; |
| 178 | + }; |
| 179 | + |
| 180 | + ddr_code: memory@C0000000 { |
| 181 | + compatible = "mmio-sram"; |
| 182 | + reg = <0xC0000000 0x10000000>; |
| 183 | + }; |
| 184 | + |
| 185 | + ddr_data: memory@D0000000 { |
| 186 | + compatible = "mmio-sram"; |
| 187 | + reg = <0xD0000000 0x10000000>; |
| 188 | + }; |
| 189 | + |
| 190 | + clocks { |
| 191 | + |
| 192 | + clk_hse: clk-hse { |
| 193 | + #clock-cells = <0>; |
| 194 | + compatible = "fixed-clock"; |
| 195 | + status = "disabled"; |
| 196 | + }; |
| 197 | + |
| 198 | + clk_hsi: clk-hsi { |
| 199 | + #clock-cells = <0>; |
| 200 | + compatible = "fixed-clock"; |
| 201 | + status = "disabled"; |
| 202 | + }; |
| 203 | + |
| 204 | + cpusw: cpusw { |
| 205 | + #clock-cells = <0>; |
| 206 | + compatible = "st,stm32mp13-cpu-clock-mux"; |
| 207 | + status = "disabled"; |
| 208 | + }; |
| 209 | + |
| 210 | + pll1: pll: pll { |
| 211 | + #clock-cells = <0>; |
| 212 | + compatible = "st,stm32mp13-pll-clock"; |
| 213 | + status = "disabled"; |
| 214 | + }; |
| 215 | + }; |
| 216 | + |
| 217 | + timer { |
| 218 | + compatible = "arm,armv8-timer"; |
| 219 | + interrupt-parent = <&gic>; |
| 220 | + interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 221 | + <GIC_PPI 14 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 222 | + <GIC_PPI 11 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>, |
| 223 | + <GIC_PPI 10 IRQ_TYPE_LEVEL IRQ_DEFAULT_PRIORITY>; |
| 224 | + }; |
| 225 | +}; |
0 commit comments