From 550987be94aa41fe973b709b904f12545aa99635 Mon Sep 17 00:00:00 2001 From: Alexandre Torgue Date: Mon, 11 Dec 2017 09:54:00 +0100 Subject: [PATCH 1/8] ARM: stm32: Kconfig: introduce MACH_STM32F769 flag This patch introduces the MACH_STM32F769 to make possible to only select STM32F769 pinctrl driver. By default, all the MACH_STM32Fxxx flags will be set with STM32 defconfig. Signed-off-by: Alexandre Torgue --- arch/arm/mach-stm32/Kconfig | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig index 0d1889bbde58..33b07db3755d 100644 --- a/arch/arm/mach-stm32/Kconfig +++ b/arch/arm/mach-stm32/Kconfig @@ -25,6 +25,11 @@ config MACH_STM32F746 depends on ARCH_STM32 default y +config MACH_STM32F769 + bool "STMicroelectronics STM32F769" + depends on ARCH_STM32 + default y + config MACH_STM32H743 bool "STMicrolectronics STM32H743" depends on ARCH_STM32 From 85beb77f87f750b3b363ddc427708338522f3909 Mon Sep 17 00:00:00 2001 From: Alexandre Torgue Date: Mon, 11 Dec 2017 09:54:00 +0100 Subject: [PATCH 2/8] ARM: stm32: add new STM32F769 MCU Add new st,stm32f769 compatible machine name for STM32F769 MCU and update documentation. Signed-off-by: Alexandre Torgue --- .../arm/stm32/stm32f769-overview.txt | 36 +++++++++++++++++++ arch/arm/mach-stm32/board-dt.c | 1 + 2 files changed, 37 insertions(+) create mode 100644 Documentation/arm/stm32/stm32f769-overview.txt diff --git a/Documentation/arm/stm32/stm32f769-overview.txt b/Documentation/arm/stm32/stm32f769-overview.txt new file mode 100644 index 000000000000..9ab7e603d6c9 --- /dev/null +++ b/Documentation/arm/stm32/stm32f769-overview.txt @@ -0,0 +1,36 @@ + STM32F769 Overview + ================== + + Introduction + ------------ + The STM32F769 is a Cortex-M7 MCU aimed at various applications. + It features: + - Cortex-M7 core running up to @216MHz + - 2MB internal flash, 512KBytes internal RAM (+4KB of backup SRAM) + - FMC controller to connect SDRAM, NOR and NAND memories + - Dual mode QSPI + - SD/MMC/SDIO support*2 + - Ethernet controller + - USB OTFG FS & HS controllers + - I2C*4, SPI*6, CAN*3 busses support + - Several 16 & 32 bits general purpose timers + - Serial Audio interface *2 + - LCD controller + - HDMI-CEC + - DSI + - SPDIFRX + - MDIO salave interface + + Resources + --------- + Datasheet and reference manual are publicly available on ST website: + - http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32-high-performance-mcus/stm32f7-series/stm32f7x9/stm32f769ni.html + + Document Author + --------------- + Alexandre Torgue + + + + + diff --git a/arch/arm/mach-stm32/board-dt.c b/arch/arm/mach-stm32/board-dt.c index e918686e4191..48246325c6cc 100644 --- a/arch/arm/mach-stm32/board-dt.c +++ b/arch/arm/mach-stm32/board-dt.c @@ -12,6 +12,7 @@ static const char *const stm32_compat[] __initconst = { "st,stm32f429", "st,stm32f469", "st,stm32f746", + "st,stm32f769", "st,stm32h743", NULL }; From 61ea291cff9e8cc4b35d84c73b2659b628d4ff9b Mon Sep 17 00:00:00 2001 From: Benjamin Gaignard Date: Thu, 30 Nov 2017 09:49:00 +0100 Subject: [PATCH 3/8] ARM: stm32: Fix copyright Uniformize STMicroelectronics copyrights header Add SPDX identifier Signed-off-by: Benjamin Gaignard CC: Maxime Coquelin Acked-by: Maxime Coquelin Signed-off-by: Alexandre Torgue --- arch/arm/mach-stm32/board-dt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-stm32/board-dt.c b/arch/arm/mach-stm32/board-dt.c index 48246325c6cc..8c682f4a8ffc 100644 --- a/arch/arm/mach-stm32/board-dt.c +++ b/arch/arm/mach-stm32/board-dt.c @@ -1,7 +1,8 @@ +// SPDX-License-Identifier: GPL-2.0 /* * Copyright (C) Maxime Coquelin 2015 + * Copyright (C) STMicroelectronics 2017 * Author: Maxime Coquelin - * License terms: GNU General Public License (GPL), version 2 */ #include From 40fed8d0e3833200f4b9f7cd057e37d0450a5044 Mon Sep 17 00:00:00 2001 From: Ludovic Barre Date: Mon, 26 Feb 2018 14:39:52 +0100 Subject: [PATCH 4/8] Documentation: arm: stm32: move to rst format This patch rewrites stm32 documentation to rst (ReStructuredText) format. Signed-off-by: Ludovic Barre Signed-off-by: Alexandre Torgue --- Documentation/arm/stm32/overview.rst | 31 ++++++++++++++++ Documentation/arm/stm32/overview.txt | 33 ----------------- .../arm/stm32/stm32f429-overview.rst | 26 ++++++++++++++ .../arm/stm32/stm32f429-overview.txt | 22 ------------ .../arm/stm32/stm32f746-overview.rst | 33 +++++++++++++++++ .../arm/stm32/stm32f746-overview.txt | 34 ------------------ .../arm/stm32/stm32f769-overview.rst | 35 ++++++++++++++++++ .../arm/stm32/stm32f769-overview.txt | 36 ------------------- .../arm/stm32/stm32h743-overview.rst | 34 ++++++++++++++++++ .../arm/stm32/stm32h743-overview.txt | 30 ---------------- 10 files changed, 159 insertions(+), 155 deletions(-) create mode 100644 Documentation/arm/stm32/overview.rst delete mode 100644 Documentation/arm/stm32/overview.txt create mode 100644 Documentation/arm/stm32/stm32f429-overview.rst delete mode 100644 Documentation/arm/stm32/stm32f429-overview.txt create mode 100644 Documentation/arm/stm32/stm32f746-overview.rst delete mode 100644 Documentation/arm/stm32/stm32f746-overview.txt create mode 100644 Documentation/arm/stm32/stm32f769-overview.rst delete mode 100644 Documentation/arm/stm32/stm32f769-overview.txt create mode 100644 Documentation/arm/stm32/stm32h743-overview.rst delete mode 100644 Documentation/arm/stm32/stm32h743-overview.txt diff --git a/Documentation/arm/stm32/overview.rst b/Documentation/arm/stm32/overview.rst new file mode 100644 index 000000000000..6be60592eaf7 --- /dev/null +++ b/Documentation/arm/stm32/overview.rst @@ -0,0 +1,31 @@ +======================== +STM32 ARM Linux Overview +======================== + +Introduction +------------ + +The STMicroelectronics family of Cortex-M based MCUs are supported by the +'STM32' platform of ARM Linux. Currently only the STM32F429 (Cortex-M4) +and STM32F746 (Cortex-M7) are supported. + +Configuration +------------- + +A generic configuration is provided for STM32 family, and can be used as the +default by + make stm32_defconfig + +Layout +------ + +All the files for multiple machine families are located in the platform code +contained in arch/arm/mach-stm32 + +There is a generic board board-dt.c in the mach folder which support +Flattened Device Tree, which means, it works with any compatible board with +Device Trees. + +:Authors: + +Maxime Coquelin diff --git a/Documentation/arm/stm32/overview.txt b/Documentation/arm/stm32/overview.txt deleted file mode 100644 index a03b0357c017..000000000000 --- a/Documentation/arm/stm32/overview.txt +++ /dev/null @@ -1,33 +0,0 @@ - STM32 ARM Linux Overview - ======================== - -Introduction ------------- - - The STMicroelectronics family of Cortex-M based MCUs are supported by the - 'STM32' platform of ARM Linux. Currently only the STM32F429 (Cortex-M4) - and STM32F746 (Cortex-M7) are supported. - - -Configuration -------------- - - A generic configuration is provided for STM32 family, and can be used as the - default by - make stm32_defconfig - -Layout ------- - - All the files for multiple machine families are located in the platform code - contained in arch/arm/mach-stm32 - - There is a generic board board-dt.c in the mach folder which support - Flattened Device Tree, which means, it works with any compatible board with - Device Trees. - - -Document Author ---------------- - - Maxime Coquelin diff --git a/Documentation/arm/stm32/stm32f429-overview.rst b/Documentation/arm/stm32/stm32f429-overview.rst new file mode 100644 index 000000000000..18feda97f483 --- /dev/null +++ b/Documentation/arm/stm32/stm32f429-overview.rst @@ -0,0 +1,26 @@ +STM32F429 Overview +================== + +Introduction +------------ + +The STM32F429 is a Cortex-M4 MCU aimed at various applications. +It features: + +- ARM Cortex-M4 up to 180MHz with FPU +- 2MB internal Flash Memory +- External memory support through FMC controller (PSRAM, SDRAM, NOR, NAND) +- I2C, SPI, SAI, CAN, USB OTG, Ethernet controllers +- LCD controller & Camera interface +- Cryptographic processor + +Resources +--------- + +Datasheet and reference manual are publicly available on ST website (STM32F429_). + +.. _STM32F429: http://www.st.com/web/en/catalog/mmc/FM141/SC1169/SS1577/LN1806?ecmp=stm32f429-439_pron_pr-ces2014_nov2013 + +:Authors: + +Maxime Coquelin diff --git a/Documentation/arm/stm32/stm32f429-overview.txt b/Documentation/arm/stm32/stm32f429-overview.txt deleted file mode 100644 index 5206822bd8ef..000000000000 --- a/Documentation/arm/stm32/stm32f429-overview.txt +++ /dev/null @@ -1,22 +0,0 @@ - STM32F429 Overview - ================== - - Introduction - ------------ - The STM32F429 is a Cortex-M4 MCU aimed at various applications. - It features: - - ARM Cortex-M4 up to 180MHz with FPU - - 2MB internal Flash Memory - - External memory support through FMC controller (PSRAM, SDRAM, NOR, NAND) - - I2C, SPI, SAI, CAN, USB OTG, Ethernet controllers - - LCD controller & Camera interface - - Cryptographic processor - - Resources - --------- - Datasheet and reference manual are publicly available on ST website: - - http://www.st.com/web/en/catalog/mmc/FM141/SC1169/SS1577/LN1806?ecmp=stm32f429-439_pron_pr-ces2014_nov2013 - - Document Author - --------------- - Maxime Coquelin diff --git a/Documentation/arm/stm32/stm32f746-overview.rst b/Documentation/arm/stm32/stm32f746-overview.rst new file mode 100644 index 000000000000..b5f4b6ce7656 --- /dev/null +++ b/Documentation/arm/stm32/stm32f746-overview.rst @@ -0,0 +1,33 @@ +STM32F746 Overview +================== + +Introduction +------------ + +The STM32F746 is a Cortex-M7 MCU aimed at various applications. +It features: + +- Cortex-M7 core running up to @216MHz +- 1MB internal flash, 320KBytes internal RAM (+4KB of backup SRAM) +- FMC controller to connect SDRAM, NOR and NAND memories +- Dual mode QSPI +- SD/MMC/SDIO support +- Ethernet controller +- USB OTFG FS & HS controllers +- I2C, SPI, CAN busses support +- Several 16 & 32 bits general purpose timers +- Serial Audio interface +- LCD controller +- HDMI-CEC +- SPDIFRX + +Resources +--------- + +Datasheet and reference manual are publicly available on ST website (STM32F746_). + +.. _STM32F746: http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32f7-series/stm32f7x6/stm32f746ng.html + +:Authors: + +Alexandre Torgue diff --git a/Documentation/arm/stm32/stm32f746-overview.txt b/Documentation/arm/stm32/stm32f746-overview.txt deleted file mode 100644 index cffd2b1ccd6f..000000000000 --- a/Documentation/arm/stm32/stm32f746-overview.txt +++ /dev/null @@ -1,34 +0,0 @@ - STM32F746 Overview - ================== - - Introduction - ------------ - The STM32F746 is a Cortex-M7 MCU aimed at various applications. - It features: - - Cortex-M7 core running up to @216MHz - - 1MB internal flash, 320KBytes internal RAM (+4KB of backup SRAM) - - FMC controller to connect SDRAM, NOR and NAND memories - - Dual mode QSPI - - SD/MMC/SDIO support - - Ethernet controller - - USB OTFG FS & HS controllers - - I2C, SPI, CAN busses support - - Several 16 & 32 bits general purpose timers - - Serial Audio interface - - LCD controller - - HDMI-CEC - - SPDIFRX - - Resources - --------- - Datasheet and reference manual are publicly available on ST website: - - http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32f7-series/stm32f7x6/stm32f746ng.html - - Document Author - --------------- - Alexandre Torgue - - - - - diff --git a/Documentation/arm/stm32/stm32f769-overview.rst b/Documentation/arm/stm32/stm32f769-overview.rst new file mode 100644 index 000000000000..228656ced2fe --- /dev/null +++ b/Documentation/arm/stm32/stm32f769-overview.rst @@ -0,0 +1,35 @@ +STM32F769 Overview +================== + +Introduction +------------ + +The STM32F769 is a Cortex-M7 MCU aimed at various applications. +It features: + +- Cortex-M7 core running up to @216MHz +- 2MB internal flash, 512KBytes internal RAM (+4KB of backup SRAM) +- FMC controller to connect SDRAM, NOR and NAND memories +- Dual mode QSPI +- SD/MMC/SDIO support*2 +- Ethernet controller +- USB OTFG FS & HS controllers +- I2C*4, SPI*6, CAN*3 busses support +- Several 16 & 32 bits general purpose timers +- Serial Audio interface*2 +- LCD controller +- HDMI-CEC +- DSI +- SPDIFRX +- MDIO salave interface + +Resources +--------- + +Datasheet and reference manual are publicly available on ST website (STM32F769_). + +.. _STM32F769: http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32-high-performance-mcus/stm32f7-series/stm32f7x9/stm32f769ni.html + +:Authors: + +Alexandre Torgue diff --git a/Documentation/arm/stm32/stm32f769-overview.txt b/Documentation/arm/stm32/stm32f769-overview.txt deleted file mode 100644 index 9ab7e603d6c9..000000000000 --- a/Documentation/arm/stm32/stm32f769-overview.txt +++ /dev/null @@ -1,36 +0,0 @@ - STM32F769 Overview - ================== - - Introduction - ------------ - The STM32F769 is a Cortex-M7 MCU aimed at various applications. - It features: - - Cortex-M7 core running up to @216MHz - - 2MB internal flash, 512KBytes internal RAM (+4KB of backup SRAM) - - FMC controller to connect SDRAM, NOR and NAND memories - - Dual mode QSPI - - SD/MMC/SDIO support*2 - - Ethernet controller - - USB OTFG FS & HS controllers - - I2C*4, SPI*6, CAN*3 busses support - - Several 16 & 32 bits general purpose timers - - Serial Audio interface *2 - - LCD controller - - HDMI-CEC - - DSI - - SPDIFRX - - MDIO salave interface - - Resources - --------- - Datasheet and reference manual are publicly available on ST website: - - http://www.st.com/content/st_com/en/products/microcontrollers/stm32-32-bit-arm-cortex-mcus/stm32-high-performance-mcus/stm32f7-series/stm32f7x9/stm32f769ni.html - - Document Author - --------------- - Alexandre Torgue - - - - - diff --git a/Documentation/arm/stm32/stm32h743-overview.rst b/Documentation/arm/stm32/stm32h743-overview.rst new file mode 100644 index 000000000000..3458dc00095d --- /dev/null +++ b/Documentation/arm/stm32/stm32h743-overview.rst @@ -0,0 +1,34 @@ +STM32H743 Overview +================== + +Introduction +------------ + +The STM32H743 is a Cortex-M7 MCU aimed at various applications. +It features: + +- Cortex-M7 core running up to @400MHz +- 2MB internal flash, 1MBytes internal RAM +- FMC controller to connect SDRAM, NOR and NAND memories +- Dual mode QSPI +- SD/MMC/SDIO support +- Ethernet controller +- USB OTFG FS & HS controllers +- I2C, SPI, CAN busses support +- Several 16 & 32 bits general purpose timers +- Serial Audio interface +- LCD controller +- HDMI-CEC +- SPDIFRX +- DFSDM + +Resources +--------- + +Datasheet and reference manual are publicly available on ST website (STM32H743_). + +.. _STM32H743: http://www.st.com/en/microcontrollers/stm32h7x3.html?querycriteria=productId=LN2033 + +:Authors: + +Alexandre Torgue diff --git a/Documentation/arm/stm32/stm32h743-overview.txt b/Documentation/arm/stm32/stm32h743-overview.txt deleted file mode 100644 index 3031cbae31a5..000000000000 --- a/Documentation/arm/stm32/stm32h743-overview.txt +++ /dev/null @@ -1,30 +0,0 @@ - STM32H743 Overview - ================== - - Introduction - ------------ - The STM32H743 is a Cortex-M7 MCU aimed at various applications. - It features: - - Cortex-M7 core running up to @400MHz - - 2MB internal flash, 1MBytes internal RAM - - FMC controller to connect SDRAM, NOR and NAND memories - - Dual mode QSPI - - SD/MMC/SDIO support - - Ethernet controller - - USB OTFG FS & HS controllers - - I2C, SPI, CAN busses support - - Several 16 & 32 bits general purpose timers - - Serial Audio interface - - LCD controller - - HDMI-CEC - - SPDIFRX - - DFSDM - - Resources - --------- - Datasheet and reference manual are publicly available on ST website: - - http://www.st.com/en/microcontrollers/stm32h7x3.html?querycriteria=productId=LN2033 - - Document Author - --------------- - Alexandre Torgue From 3ed71f8ad98a07803299693481b03fa6391e094f Mon Sep 17 00:00:00 2001 From: Ludovic Barre Date: Tue, 27 Feb 2018 09:05:18 +0100 Subject: [PATCH 5/8] ARM: stm32: prepare stm32 family to welcome armv7 architecture This patch prepares the STM32 machine for the integration of Cortex-A based microprocessor (MPU), on top of the existing Cortex-M microcontroller family (MCU). Since both MCUs and MPUs are sharing common hardware blocks we can keep using ARCH_STM32 flag for most of them. If a hardware block is specific to one family we can use either ARM_SINGLE_ARMV7M or ARCH_MULTI_V7 flag. Signed-off-by: Ludovic Barre Signed-off-by: Alexandre Torgue --- Documentation/arm/stm32/overview.rst | 15 +++++++++------ arch/arm/mach-stm32/Kconfig | 28 +++++++++++++++------------- arch/arm/mach-stm32/board-dt.c | 2 -- 3 files changed, 24 insertions(+), 21 deletions(-) diff --git a/Documentation/arm/stm32/overview.rst b/Documentation/arm/stm32/overview.rst index 6be60592eaf7..85cfc8410798 100644 --- a/Documentation/arm/stm32/overview.rst +++ b/Documentation/arm/stm32/overview.rst @@ -5,16 +5,17 @@ STM32 ARM Linux Overview Introduction ------------ -The STMicroelectronics family of Cortex-M based MCUs are supported by the -'STM32' platform of ARM Linux. Currently only the STM32F429 (Cortex-M4) -and STM32F746 (Cortex-M7) are supported. +The STMicroelectronics STM32 family of Cortex-A microprocessors (MPUs) and +Cortex-M microcontrollers (MCUs) are supported by the 'STM32' platform of +ARM Linux. Configuration ------------- -A generic configuration is provided for STM32 family, and can be used as the -default by +For MCUs, use the provided default configuration: make stm32_defconfig +For MPUs, use multi_v7 configuration: + make multi_v7_defconfig Layout ------ @@ -28,4 +29,6 @@ Device Trees. :Authors: -Maxime Coquelin +- Maxime Coquelin +- Ludovic Barre +- Gerald Baeza diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig index 33b07db3755d..1a876460c74d 100644 --- a/arch/arm/mach-stm32/Kconfig +++ b/arch/arm/mach-stm32/Kconfig @@ -1,8 +1,7 @@ -config ARCH_STM32 - bool "STMicrolectronics STM32" - depends on ARM_SINGLE_ARMV7M +menuconfig ARCH_STM32 + bool "STMicroelectronics STM32 family" if ARM_SINGLE_ARMV7M || ARCH_MULTI_V7 + select ARMV7M_SYSTICK if ARM_SINGLE_ARMV7M select ARCH_HAS_RESET_CONTROLLER - select ARMV7M_SYSTICK select CLKSRC_STM32 select PINCTRL select RESET_CONTROLLER @@ -10,27 +9,30 @@ config ARCH_STM32 help Support for STMicroelectronics STM32 processors. +if ARCH_STM32 + +if ARM_SINGLE_ARMV7M + config MACH_STM32F429 - bool "STMicrolectronics STM32F429" - depends on ARCH_STM32 + bool "STMicroelectronics STM32F429" default y config MACH_STM32F469 - bool "STMicrolectronics STM32F469" - depends on ARCH_STM32 + bool "STMicroelectronics STM32F469" default y config MACH_STM32F746 - bool "STMicrolectronics STM32F746" - depends on ARCH_STM32 + bool "STMicroelectronics STM32F746" default y config MACH_STM32F769 bool "STMicroelectronics STM32F769" - depends on ARCH_STM32 default y config MACH_STM32H743 - bool "STMicrolectronics STM32H743" - depends on ARCH_STM32 + bool "STMicroelectronics STM32H743" default y + +endif # ARMv7-M + +endif diff --git a/arch/arm/mach-stm32/board-dt.c b/arch/arm/mach-stm32/board-dt.c index 8c682f4a8ffc..6786f357851f 100644 --- a/arch/arm/mach-stm32/board-dt.c +++ b/arch/arm/mach-stm32/board-dt.c @@ -6,7 +6,6 @@ */ #include -#include #include static const char *const stm32_compat[] __initconst = { @@ -20,5 +19,4 @@ static const char *const stm32_compat[] __initconst = { DT_MACHINE_START(STM32DT, "STM32 (Device Tree Support)") .dt_compat = stm32_compat, - .restart = armv7m_restart, MACHINE_END From f7dcb04475b24e8c655aa8f285450ada17c16ebf Mon Sep 17 00:00:00 2001 From: Ludovic Barre Date: Tue, 16 Jan 2018 15:56:00 +0100 Subject: [PATCH 6/8] ARM: stm32: add initial support for STM32MP157 This patch adds initial support of STM32MP157 microprocessor (MPU) based on Arm Cortex-A7. New Cortex-A infrastructure (gic, timer,...) are selected if ARCH_MULTI_V7 is defined. Signed-off-by: Ludovic Barre Signed-off-by: Alexandre Torgue --- .../arm/stm32/stm32mp157-overview.rst | 19 +++++++++++++++++++ arch/arm/mach-stm32/Kconfig | 11 +++++++++++ arch/arm/mach-stm32/board-dt.c | 1 + 3 files changed, 31 insertions(+) create mode 100644 Documentation/arm/stm32/stm32mp157-overview.rst diff --git a/Documentation/arm/stm32/stm32mp157-overview.rst b/Documentation/arm/stm32/stm32mp157-overview.rst new file mode 100644 index 000000000000..62e176d47ca7 --- /dev/null +++ b/Documentation/arm/stm32/stm32mp157-overview.rst @@ -0,0 +1,19 @@ +STM32MP157 Overview +=================== + +Introduction +------------ + +The STM32MP157 is a Cortex-A MPU aimed at various applications. +It features: + +- Dual core Cortex-A7 application core +- 2D/3D image composition with GPU +- Standard memories interface support +- Standard connectivity, widely inherited from the STM32 MCU family +- Comprehensive security support + +:Authors: + +- Ludovic Barre +- Gerald Baeza diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig index 1a876460c74d..5bc7f5ab61cd 100644 --- a/arch/arm/mach-stm32/Kconfig +++ b/arch/arm/mach-stm32/Kconfig @@ -1,6 +1,9 @@ menuconfig ARCH_STM32 bool "STMicroelectronics STM32 family" if ARM_SINGLE_ARMV7M || ARCH_MULTI_V7 select ARMV7M_SYSTICK if ARM_SINGLE_ARMV7M + select HAVE_ARM_ARCH_TIMER if ARCH_MULTI_V7 + select ARM_GIC if ARCH_MULTI_V7 + select ARM_PSCI if ARCH_MULTI_V7 select ARCH_HAS_RESET_CONTROLLER select CLKSRC_STM32 select PINCTRL @@ -35,4 +38,12 @@ config MACH_STM32H743 endif # ARMv7-M +if ARCH_MULTI_V7 + +config MACH_STM32MP157 + bool "STMicroelectronics STM32MP157" + default y + +endif # ARMv7-A + endif diff --git a/arch/arm/mach-stm32/board-dt.c b/arch/arm/mach-stm32/board-dt.c index 6786f357851f..06911ad60cea 100644 --- a/arch/arm/mach-stm32/board-dt.c +++ b/arch/arm/mach-stm32/board-dt.c @@ -14,6 +14,7 @@ static const char *const stm32_compat[] __initconst = { "st,stm32f746", "st,stm32f769", "st,stm32h743", + "st,stm32mp157", NULL }; From abdd50e96de86b433fbed0ea2fa3a7b0eb004c59 Mon Sep 17 00:00:00 2001 From: Patrice Chotard Date: Thu, 18 Jan 2018 15:34:00 +0100 Subject: [PATCH 7/8] ARM: stm32: Add AMBA support for STM32F4 and STM32F7 SoCs As both STM32F4 and STM32F7 SoCs embeds an AMBA PL180 mmci IP, we need to enable AMBA support in mach-stm32. Signed-off-by: Patrice Chotard Signed-off-by: Alexandre Torgue --- arch/arm/mach-stm32/Kconfig | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig index 5bc7f5ab61cd..713c068b953f 100644 --- a/arch/arm/mach-stm32/Kconfig +++ b/arch/arm/mach-stm32/Kconfig @@ -18,18 +18,22 @@ if ARM_SINGLE_ARMV7M config MACH_STM32F429 bool "STMicroelectronics STM32F429" + select ARM_AMBA default y config MACH_STM32F469 bool "STMicroelectronics STM32F469" + select ARM_AMBA default y config MACH_STM32F746 bool "STMicroelectronics STM32F746" + select ARM_AMBA default y config MACH_STM32F769 bool "STMicroelectronics STM32F769" + select ARM_AMBA default y config MACH_STM32H743 From 2092e3adc323695255bd06d65f14c89afb5727ae Mon Sep 17 00:00:00 2001 From: Benjamin Gaignard Date: Tue, 27 Feb 2018 15:36:00 +0100 Subject: [PATCH 8/8] ARM: stm32: restore reboot capabilities To be able to reboot the platform we need to use armv7m_restart for STM32 SoCs using ARMv7 cores. Fixes: e0644101bd2f ("ARM: mach-stm32: prepare stm32 family to welcome armv7 architecture) Signed-off-by: Benjamin Gaignard Signed-off-by: Alexandre Torgue --- arch/arm/mach-stm32/board-dt.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/arm/mach-stm32/board-dt.c b/arch/arm/mach-stm32/board-dt.c index 06911ad60cea..011d57b488c2 100644 --- a/arch/arm/mach-stm32/board-dt.c +++ b/arch/arm/mach-stm32/board-dt.c @@ -7,6 +7,9 @@ #include #include +#ifdef CONFIG_ARM_SINGLE_ARMV7M +#include +#endif static const char *const stm32_compat[] __initconst = { "st,stm32f429", @@ -20,4 +23,7 @@ static const char *const stm32_compat[] __initconst = { DT_MACHINE_START(STM32DT, "STM32 (Device Tree Support)") .dt_compat = stm32_compat, +#ifdef CONFIG_ARM_SINGLE_ARMV7M + .restart = armv7m_restart, +#endif MACHINE_END