Skip to content

Commit

Permalink
dts: arm: st: Add SOC support for STM32G473
Browse files Browse the repository at this point in the history
This commit adds SOC support for STM32G473 MCUs

Signed-off-by: Guðni Már Gilbert <gudni.m.g@gmail.com>
  • Loading branch information
gudnimg authored and ioannisg committed Apr 26, 2021
1 parent 4700d9e commit 76a6320
Show file tree
Hide file tree
Showing 6 changed files with 109 additions and 0 deletions.
26 changes: 26 additions & 0 deletions dts/arm/st/g4/stm32g473.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
/*
* Copyright (c) 2021 Guðni Már Gilbert
*
* SPDX-License-Identifier: Apache-2.0
*/

#include <st/g4/stm32g4.dtsi>

/ {
soc {
dma1: dma@40020000 {
interrupts = <11 0 12 0 13 0 14 0 15 0 16 0 17 0 96 0>;
dma-requests = <8>;
};

dma2: dma@40020400 {
interrupts = <56 0 57 0 58 0 59 0 60 0 97 0 98 0 99 0>;
dma-requests = <8>;
dma-offset = <8>;
};

dmamux1: dmamux@40020800 {
dma-channels = <16>;
};
};
};
22 changes: 22 additions & 0 deletions dts/arm/st/g4/stm32g473Xb.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* Copyright (c) 2021 Guðni Már Gilbert
*
* SPDX-License-Identifier: Apache-2.0
*/

#include <mem.h>
#include <st/g4/stm32g473.dtsi>

/ {
sram0: memory@20000000 {
reg = <0x20000000 DT_SIZE_K(128)>;
};

soc {
flash-controller@40022000 {
flash0: flash@8000000 {
reg = <0x08000000 DT_SIZE_K(128)>;
};
};
};
};
22 changes: 22 additions & 0 deletions dts/arm/st/g4/stm32g473Xc.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* Copyright (c) 2021 Guðni Már Gilbert
*
* SPDX-License-Identifier: Apache-2.0
*/

#include <mem.h>
#include <st/g4/stm32g473.dtsi>

/ {
sram0: memory@20000000 {
reg = <0x20000000 DT_SIZE_K(128)>;
};

soc {
flash-controller@40022000 {
flash0: flash@8000000 {
reg = <0x08000000 DT_SIZE_K(256)>;
};
};
};
};
22 changes: 22 additions & 0 deletions dts/arm/st/g4/stm32g473Xe.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/*
* Copyright (c) 2021 Guðni Már Gilbert
*
* SPDX-License-Identifier: Apache-2.0
*/

#include <mem.h>
#include <st/g4/stm32g473.dtsi>

/ {
sram0: memory@20000000 {
reg = <0x20000000 DT_SIZE_K(128)>;
};

soc {
flash-controller@40022000 {
flash0: flash@8000000 {
reg = <0x08000000 DT_SIZE_K(512)>;
};
};
};
};
14 changes: 14 additions & 0 deletions soc/arm/st_stm32/stm32g4/Kconfig.defconfig.stm32g473xx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# STMicroelectronics STM32G473XX MCU

# Copyright (c) 2021 Guðni Már Gilbert
# SPDX-License-Identifier: Apache-2.0

if SOC_STM32G473XX

config SOC
default "stm32g473xx"

config NUM_IRQS
default 102

endif # SOC_STM32G473XX
3 changes: 3 additions & 0 deletions soc/arm/st_stm32/stm32g4/Kconfig.soc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ config SOC_STM32G431XX
config SOC_STM32G441XX
bool "STM32G441XX"

config SOC_STM32G473XX
bool "STM32G473XX"

config SOC_STM32G474XX
bool "STM32G474XX"

Expand Down

0 comments on commit 76a6320

Please sign in to comment.