devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Agner <stefan-XLVq0VzYD2Y@public.gmane.org>
To: shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
	kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org,
	u.kleine-koenig-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org
Cc: olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org,
	arnd-r2nGTMty4D4@public.gmane.org,
	marcel-mitwqZ+T+m9Wk0Htik3J/w@public.gmane.org,
	linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Stefan Agner <stefan-XLVq0VzYD2Y@public.gmane.org>
Subject: [RFC 3/7] ARM: vf610m4: add new machine and SoC for Vybrid on Cortex-M4
Date: Sun, 12 Oct 2014 20:13:57 +0200	[thread overview]
Message-ID: <d1b3670556c7c7a11092834abf52eedb22c332b7.1413136383.git.stefan@agner.ch> (raw)
In-Reply-To: <cover.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
In-Reply-To: <cover.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>

This patch adds a new machine ARCH_MXCM4 which requires !MMU and
!MULTIARCH and is meant as machine for the hetregenous multi-core
Vybrid/i.MX SoC's to run Linux on the Cortex-M4.

The first SoC supported is Vybrid on Cortex-M4 (SOC_VF610M4).

Signed-off-by: Stefan Agner <stefan-XLVq0VzYD2Y@public.gmane.org>
---
Not sure whether we really need a new MACH, but since MACH_MXC needs
MULTIARCH, which in turn conflicts with !MMU, I guess there is no
easier way to do it... And then, this also needs a new SOC.

 arch/arm/Kconfig                 | 12 ++++++++++++
 arch/arm/Kconfig.debug           |  4 ++--
 arch/arm/Makefile                |  1 +
 arch/arm/mach-imx/Kconfig        | 22 ++++++++++++++++++++++
 arch/arm/mach-imx/Makefile       |  1 +
 arch/arm/mach-imx/Makefile.boot  |  0
 arch/arm/mach-imx/mach-vf610m4.c | 16 ++++++++++++++++
 drivers/mmc/host/Kconfig         |  2 +-
 drivers/pinctrl/Kconfig          |  2 +-
 9 files changed, 56 insertions(+), 4 deletions(-)
 create mode 100644 arch/arm/mach-imx/Makefile.boot
 create mode 100644 arch/arm/mach-imx/mach-vf610m4.c

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 32cbbd5..69f0bad 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -455,6 +455,18 @@ config ARCH_FOOTBRIDGE
 	  Support for systems based on the DC21285 companion chip
 	  ("FootBridge"), such as the Simtec CATS and the Rebel NetWinder.
 
+menuconfig ARCH_MXCM4
+	bool "Freescale Vybrid/i.MX family on Cortex-M4" if !MMU
+	select ARCH_REQUIRE_GPIOLIB
+	select ARM_CPU_SUSPEND if PM
+	select CLKSRC_MMIO
+	select GENERIC_IRQ_CHIP
+	select PINCTRL
+	select PM_OPP if PM
+	select SOC_BUS
+	help
+	  Support for Freescale Vybrid/iMX-based family of processors on Cortex-M4
+
 config ARCH_NETX
 	bool "Hilscher NetX based"
 	select ARM_VIC
diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index b11ad54..3ac00e7 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -435,7 +435,7 @@ choice
 
 	config DEBUG_VF_UART
 		bool "Vybrid UART"
-		depends on SOC_VF610
+		depends on SOC_VF610 || SOC_VF610M4
 		help
 		  Say Y here if you want kernel low-level debugging support
 		  on Vybrid based platforms.
@@ -994,7 +994,7 @@ config DEBUG_VF_UART_PORT
 	int "Vybrid Debug UART Port Selection" if DEBUG_VF_UART
 	default 1
 	range 0 3
-	depends on SOC_VF610
+	depends on SOC_VF610 || SOC_VF610M4
 	help
 	  Choose UART port on which kernel low-level debug messages
 	  should be output.
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 0ce9d0f..55339fd 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -174,6 +174,7 @@ machine-$(CONFIG_ARCH_MSM)		+= msm
 machine-$(CONFIG_ARCH_MV78XX0)		+= mv78xx0
 machine-$(CONFIG_ARCH_MVEBU)		+= mvebu
 machine-$(CONFIG_ARCH_MXC)		+= imx
+machine-$(CONFIG_ARCH_MXCM4)		+= imx
 machine-$(CONFIG_ARCH_MEDIATEK)		+= mediatek
 machine-$(CONFIG_ARCH_MXS)		+= mxs
 machine-$(CONFIG_ARCH_NETX)		+= netx
diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index be9a51a..7ed3ab9 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -739,3 +739,25 @@ endif
 source "arch/arm/mach-imx/devices/Kconfig"
 
 endif
+
+if !MMU && ARCH_MXCM4
+
+config SOC_VF610M4
+	bool "Vybrid Family VF610 support for Cortex-M4"
+	select ARCH_REQUIRE_GPIOLIB
+	select PINCTRL_VF610
+	select PINCTRL_IMX
+	select ARM_NVIC
+	select AUTO_ZRELADDR
+	select CPU_V7M
+	select COMMON_CLK
+	select GENERIC_CLOCKEVENTS
+	select NO_DMA
+	select NO_IOPORT_MAP
+	select SPARSE_IRQ
+	select USE_OF
+	select VF_PIT_TIMER
+	help
+	  Support for Vybrid Familiy VF610's Cortex-M4
+
+endif
diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile
index 23c0293..d326220 100644
--- a/arch/arm/mach-imx/Makefile
+++ b/arch/arm/mach-imx/Makefile
@@ -113,5 +113,6 @@ obj-$(CONFIG_SOC_IMX51) += mach-imx51.o
 obj-$(CONFIG_SOC_IMX53) += mach-imx53.o
 
 obj-$(CONFIG_SOC_VF610) += clk-vf610.o mach-vf610.o
+obj-$(CONFIG_SOC_VF610M4) += clk-vf610.o mach-vf610m4.o
 
 obj-y += devices/
diff --git a/arch/arm/mach-imx/Makefile.boot b/arch/arm/mach-imx/Makefile.boot
new file mode 100644
index 0000000..e69de29
diff --git a/arch/arm/mach-imx/mach-vf610m4.c b/arch/arm/mach-imx/mach-vf610m4.c
new file mode 100644
index 0000000..d534f01
--- /dev/null
+++ b/arch/arm/mach-imx/mach-vf610m4.c
@@ -0,0 +1,16 @@
+#include <linux/kernel.h>
+
+#include <asm/v7m.h>
+
+#include <asm/mach/arch.h>
+
+static const char *const vf610m4_compat[] __initconst = {
+	"fsl,vf610m4",
+	NULL
+};
+
+
+DT_MACHINE_START(VF610M4DT, "VF610 on Cortex-M4 (Device Tree Support)")
+	.dt_compat = vf610m4_compat,
+	.restart = armv7m_restart,
+MACHINE_END
diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig
index 4511358..eef90c0 100644
--- a/drivers/mmc/host/Kconfig
+++ b/drivers/mmc/host/Kconfig
@@ -155,7 +155,7 @@ config MMC_SDHCI_CNS3XXX
 
 config MMC_SDHCI_ESDHC_IMX
 	tristate "SDHCI support for the Freescale eSDHC/uSDHC i.MX controller"
-	depends on ARCH_MXC
+	depends on ARCH_MXC || ARCH_MXCM4
 	depends on MMC_SDHCI_PLTFM
 	select MMC_SDHCI_IO_ACCESSORS
 	help
diff --git a/drivers/pinctrl/Kconfig b/drivers/pinctrl/Kconfig
index bfd2c2e..508dc95 100644
--- a/drivers/pinctrl/Kconfig
+++ b/drivers/pinctrl/Kconfig
@@ -181,7 +181,7 @@ config PINCTRL_IMX6SX
 
 config PINCTRL_VF610
 	bool "Freescale Vybrid VF610 pinctrl driver"
-	depends on SOC_VF610
+	depends on SOC_VF610 || SOC_VF610M4
 	select PINCTRL_IMX
 	help
 	  Say Y here to enable the Freescale Vybrid VF610 pinctrl driver
-- 
2.1.2

--
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:[~2014-10-12 18:13 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-12 18:13 [RFC 0/7] ARM: vf610m4: Add Vybrid Cortex-M4 support Stefan Agner
     [not found] ` <cover.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 18:13   ` [RFC 1/7] ARM: vf610: add low level debug support for !MMU Stefan Agner
     [not found]     ` <331b5f06d72890ac348adcd8cce616db576eb10e.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 18:48       ` Arnd Bergmann
2014-10-13  9:26         ` Stefan Agner
2014-10-12 18:13   ` [RFC 2/7] clocksource: add dependencies for Vybrid pit clocksource Stefan Agner
     [not found]     ` <603e0f51e88b5643cb42e966cbb1b80b21a55ecf.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 18:18       ` Uwe Kleine-König
     [not found]         ` <20141012181821.GQ31554-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2014-10-13  9:46           ` Stefan Agner
     [not found]             ` <98ca2b7a76dc786a36cf6c4113ca751f-XLVq0VzYD2Y@public.gmane.org>
2014-10-13 10:57               ` Uwe Kleine-König
2014-10-12 18:13   ` Stefan Agner [this message]
     [not found]     ` <d1b3670556c7c7a11092834abf52eedb22c332b7.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 18:51       ` [RFC 3/7] ARM: vf610m4: add new machine and SoC for Vybrid on Cortex-M4 Arnd Bergmann
2014-10-13 10:03         ` Stefan Agner
     [not found]           ` <776a06abd938d507d7798670e6ad27d1-XLVq0VzYD2Y@public.gmane.org>
2014-10-13 10:57             ` Arnd Bergmann
2014-10-12 18:13   ` [RFC 4/7] ARM: dts: add support for Vybrid running " Stefan Agner
     [not found]     ` <b3dd902655e9cc4496170a05a907fcce5a687427.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 18:56       ` Arnd Bergmann
2014-10-13 10:41         ` Stefan Agner
2014-10-13 10:32       ` Mark Rutland
2014-10-13 11:08         ` Stefan Agner
     [not found]           ` <fadc1e22c016f4259819d87ba06d0d99-XLVq0VzYD2Y@public.gmane.org>
2014-10-13 11:24             ` Arnd Bergmann
2014-10-13 16:11               ` Stefan Agner
     [not found]                 ` <e7425f34e2149aa495a2e3611854e952-XLVq0VzYD2Y@public.gmane.org>
2014-10-13 19:54                   ` Arnd Bergmann
2014-10-13 21:20                     ` Stefan Agner
     [not found]                       ` <7c474d8f876cbf9adaec55af1dffd6c2-XLVq0VzYD2Y@public.gmane.org>
2014-10-14 10:01                         ` Arnd Bergmann
2014-10-12 18:13   ` [RFC 5/7] irqchip: nvic: increase number of external interrupts to 112 Stefan Agner
2014-10-12 18:14   ` [RFC 6/7] ARM: vf610m4: HACK: get dtb pointer from SRC_GPR3 Stefan Agner
     [not found]     ` <2bdc44912522eb02db2e4612738fe9f0545b36d9.1413136383.git.stefan-XLVq0VzYD2Y@public.gmane.org>
2014-10-12 19:00       ` Arnd Bergmann
2014-10-13 10:10         ` Stefan Agner
2014-10-12 18:14   ` [RFC 7/7] ARM: vf610m4: add defconfig for Linux on Vybrids Cortex-M4 Stefan Agner
2014-11-28 14:17   ` [RFC 0/7] ARM: vf610m4: Add Vybrid Cortex-M4 support Andreas Färber
     [not found]     ` <54788417.6020408-l3A5Bk7waGM@public.gmane.org>
2014-11-28 16:00       ` Stefan Agner

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=d1b3670556c7c7a11092834abf52eedb22c332b7.1413136383.git.stefan@agner.ch \
    --to=stefan-xlvq0vzyd2y@public.gmane.org \
    --cc=arnd-r2nGTMty4D4@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org \
    --cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
    --cc=linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org \
    --cc=marcel-mitwqZ+T+m9Wk0Htik3J/w@public.gmane.org \
    --cc=olof-nZhT3qVonbNeoWH0uzbU5w@public.gmane.org \
    --cc=shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=u.kleine-koenig-bIcnvbaLZ9MEGnE8C9+IrQ@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).