devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ludovic Barre <ludovic.Barre-qxv4g6HH51o@public.gmane.org>
To: Russell King <linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org>,
	Rob Herring <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	Linus Walleij
	<linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	Arnd Bergmann <arnd-r2nGTMty4D4@public.gmane.org>
Cc: Maxime Coquelin
	<mcoquelin.stm32-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Alexandre Torgue <alexandre.torgue-qxv4g6HH51o@public.gmane.org>,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Ludovic Barre <ludovic.barre-qxv4g6HH51o@public.gmane.org>
Subject: [PATCH 2/6] ARM: stm32: add initial support for STM32MP157
Date: Fri, 8 Dec 2017 15:11:13 +0100	[thread overview]
Message-ID: <1512742277-28205-3-git-send-email-ludovic.Barre@st.com> (raw)
In-Reply-To: <1512742277-28205-1-git-send-email-ludovic.Barre-qxv4g6HH51o@public.gmane.org>

From: Ludovic Barre <ludovic.barre-qxv4g6HH51o@public.gmane.org>

This patch adds initial support of STM32MP157 microprocessor (MPU)
based on Arm Cortex-A7. Under new ARCH_STM32_MPU flag we select the
needed Cortex-A infrastructure (like gic, timer,...)

Signed-off-by: Ludovic Barre <ludovic.barre-qxv4g6HH51o@public.gmane.org>
---
 Documentation/arm/stm32/stm32mp157-overview.txt | 12 ++++++++++++
 Documentation/devicetree/bindings/arm/stm32.txt |  1 +
 arch/arm/mach-stm32/Kconfig                     | 22 ++++++++++++++++++++--
 arch/arm/mach-stm32/Makefile                    |  1 +
 arch/arm/mach-stm32/board-mpu-dt.c              | 16 ++++++++++++++++
 5 files changed, 50 insertions(+), 2 deletions(-)
 create mode 100644 Documentation/arm/stm32/stm32mp157-overview.txt
 create mode 100644 arch/arm/mach-stm32/board-mpu-dt.c

diff --git a/Documentation/arm/stm32/stm32mp157-overview.txt b/Documentation/arm/stm32/stm32mp157-overview.txt
new file mode 100644
index 0000000..8a3e7cb
--- /dev/null
+++ b/Documentation/arm/stm32/stm32mp157-overview.txt
@@ -0,0 +1,12 @@
+			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
diff --git a/Documentation/devicetree/bindings/arm/stm32.txt b/Documentation/devicetree/bindings/arm/stm32.txt
index 05762b0..6808ed9 100644
--- a/Documentation/devicetree/bindings/arm/stm32.txt
+++ b/Documentation/devicetree/bindings/arm/stm32.txt
@@ -7,3 +7,4 @@ using one of the following compatible strings:
   st,stm32f469
   st,stm32f746
   st,stm32h743
+  st,stm32mp157
diff --git a/arch/arm/mach-stm32/Kconfig b/arch/arm/mach-stm32/Kconfig
index c8059ea..2b227c7 100644
--- a/arch/arm/mach-stm32/Kconfig
+++ b/arch/arm/mach-stm32/Kconfig
@@ -1,12 +1,12 @@
 menuconfig ARCH_STM32
-	bool "STMicrolectronics STM32 family" if ARM_SINGLE_ARMV7M
+	bool "STMicrolectronics STM32 family" if ARM_SINGLE_ARMV7M || ARCH_MULTI_V7
 	select ARCH_HAS_RESET_CONTROLLER
 	select CLKSRC_STM32
 	select PINCTRL
 	select RESET_CONTROLLER
 	select STM32_EXTI
 	help
-	  Support for STMicroelectronics STM32 MCU family
+	  Support for STMicroelectronics STM32 MCU/MPU family
 
 if ARCH_STM32
 
@@ -40,4 +40,22 @@ config MACH_STM32H743
 
 endif
 
+if ARCH_MULTI_V7
+
+config ARCH_STM32_MPU
+	bool "STMicrolectronics STM32 MPU"
+	default y
+	select ARM_GIC
+	select HAVE_ARM_ARCH_TIMER
+	select ARM_PSCI
+	help
+	  Support for STMicroelectronics STM32 Microprocessors.
+
+config MACH_STM32MP157
+	bool "STMicrolectronics STM32MP157"
+	depends on ARCH_STM32_MPU
+	default y
+
+endif
+
 endif
diff --git a/arch/arm/mach-stm32/Makefile b/arch/arm/mach-stm32/Makefile
index 90c1b71..a405eb6 100644
--- a/arch/arm/mach-stm32/Makefile
+++ b/arch/arm/mach-stm32/Makefile
@@ -1 +1,2 @@
 obj-$(CONFIG_ARCH_STM32_MCU) += board-mcu-dt.o
+obj-$(CONFIG_ARCH_STM32_MPU) += board-mpu-dt.o
diff --git a/arch/arm/mach-stm32/board-mpu-dt.c b/arch/arm/mach-stm32/board-mpu-dt.c
new file mode 100644
index 0000000..9e18405
--- /dev/null
+++ b/arch/arm/mach-stm32/board-mpu-dt.c
@@ -0,0 +1,16 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright (C) STMicroelectronics 2017 - All Rights Reserved
+ * Author: Ludovic Barre <ludovic.barre-qxv4g6HH51o@public.gmane.org> for STMicroelectronics.
+ */
+#include <asm/mach/arch.h>
+#include <linux/of_platform.h>
+
+static const char *const stm32mp_compat[] __initconst = {
+	"st,stm32mp157",
+	NULL
+};
+
+DT_MACHINE_START(STM32MPDT, "STM32 MP (Device Tree Support)")
+	.dt_compat = stm32mp_compat,
+MACHINE_END
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2017-12-08 14:11 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-08 14:11 [PATCH 0/6] ARM: stm32: add initial STM32MPU support Ludovic Barre
     [not found] ` <1512742277-28205-1-git-send-email-ludovic.Barre-qxv4g6HH51o@public.gmane.org>
2017-12-08 14:11   ` [PATCH 1/6] ARM: stm32: prepare stm32 family to welcome armv7 architecture Ludovic Barre
2017-12-11 10:25     ` Linus Walleij
     [not found]       ` <CACRpkdaKZk5N9F=_nYSzKWyXgW4xQ9Ltft7-UNM+a-nOpqq2xg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-12-11 13:40         ` Arnd Bergmann
2017-12-11 14:22           ` Ludovic BARRE
2017-12-12 11:03           ` afzal mohammed
2017-12-12 13:32             ` Ludovic BARRE
2017-12-08 14:11   ` Ludovic Barre [this message]
2017-12-12 23:24     ` [PATCH 2/6] ARM: stm32: add initial support for STM32MP157 Rob Herring
2017-12-13  9:02       ` Ludovic BARRE
2017-12-08 14:11   ` [PATCH 4/6] ARM: configs: multi_v7: add stm32 support Ludovic Barre
2017-12-08 14:11   ` [PATCH 6/6] ARM: dts: stm32: add initial support of stm32mp157c eval board Ludovic Barre
2017-12-08 14:41   ` [PATCH 0/6] ARM: stm32: add initial STM32MPU support Neil Armstrong
2017-12-08 14:11 ` [PATCH 3/6] pinctrl: stm32: Add STM32MP157 MPU support Ludovic Barre
     [not found]   ` <1512742277-28205-4-git-send-email-ludovic.Barre-qxv4g6HH51o@public.gmane.org>
2017-12-12 23:25     ` Rob Herring
2017-12-08 14:11 ` [PATCH 5/6] ARM: dts: stm32: add stm32mp157c initial support Ludovic Barre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1512742277-28205-3-git-send-email-ludovic.Barre@st.com \
    --to=ludovic.barre-qxv4g6hh51o@public.gmane.org \
    --cc=alexandre.torgue-qxv4g6HH51o@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=linux-I+IVW8TIWO2tmTQ+vhA3Yw@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mcoquelin.stm32-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).