aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2018-10-29 18:37:33 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2018-10-29 18:37:33 -0400
commit4b42745211af552f170f38a1b97f4a112b5da6b2 (patch)
tree83b165e30cc685ba335d3295deb193dd910c7271
parentb22b6beae6116e3a9c46ced312c626f6737a3fa6 (diff)
parentf4f9554f16d0a14b8ced9b3b91bd4e545fca5d66 (diff)
Merge tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc
Pull ARM SoC platform updates from Arnd Bergmann: "A couple of platforms change hands in the MAINTAINERS file: - Linus Walleij lists himself for the ARM Reference platforms: versatile, vexpress, integrator and realview. He has been the main contributor for these for a while, and makes it official now. - Vladimir Zapolskiy takes over the LPC18xx platform from Joachim Eastwood - Manivannan Sadhasivam becomes a secondary maintainer for the Actions Semi machines - Nicolas Ferre lists updates the MAINTAINER listing for the AT91 platform: Ludovic Desroches is now a co-maintainer for the platform, and several other people (Claudiu Beznea, Cristian Birsan, Eugen Hristev, Codrin Ciubotariu) take over individual device drivers. Thanks everyone for working on this, and welcome to the new maintainers! The "virt" platform on qemy or kvm can now be used in big-endian mode without additional tricks, thanks to Jason Donenfeld. Once again, we gain support for another NXP i.MX6 variant, this time it's the i.MX 6ULZ 32-bit single-core version. On arm64, we add support for two SoCs from Renesas: RZ/G2E (r8a774c0) and RZ/G2M (r8a774a1). These are described as microcontrollers on the manufacturer website, but appear to be rather powerful. The RZ/G2M is used on the reference board for the CIP Super Long Term Support (SLTS) Linux Kernels" * tag 'armsoc-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (54 commits) MAINTAINERS: Assign myself as a maintainer of ARM/LPC18XX architecture arm64: exynos: Enable generic power domain support MAINTAINERS: remove non-exsiting email address of Baoyou MAINTAINERS: fix pattern in ARM/Synaptics berlin SoC section MAINTAINERS: Drop dt-bindings/genpd/k2g.h ARM: samsung: Limit SAMSUNG_PM_CHECK config option to non-Exynos platforms arm64: actions: Enable PINCTRL in platforms Kconfig MAINTAINERS: Add entry for Actions Semi Owl SoCs DMA driver MAINTAINERS: Add entry for Actions Semiconductor Owl I2C driver MAINTAINERS: Update clock binding entry for Actions Semi Owl SoCs ARM: imx: add i.mx6ulz msl support ARM: Assume maintainership of ARM reference designs ARM: support big-endian for the virt architecture MAINTAINERS: sdhci: move the Microchip entry to proper location MAINTAINERS: move former ATMEL entries to proper MICROCHIP location MAINTAINERS: remove the / ATMEL string from MICROCHIP entries MAINTAINERS: iio: add co-maintainer to SAMA5D2-compatible ADC driver MAINTAINERS: pwm: add entry for Microchip pwm driver MAINTAINERS: dmaengine: add files to Microchip dma entry MAINTAINERS: USB: change maintainer for Microchip USBA gadget driver ...
-rw-r--r--Documentation/devicetree/bindings/net/marvell,prestera.txt4
-rw-r--r--MAINTAINERS262
-rw-r--r--arch/arm/Kconfig1
-rw-r--r--arch/arm/Kconfig.debug9
-rw-r--r--arch/arm/mach-at91/pm.c9
-rw-r--r--arch/arm/mach-imx/anatop.c20
-rw-r--r--arch/arm/mach-imx/cpu.c3
-rw-r--r--arch/arm/mach-imx/mmdc.c14
-rw-r--r--arch/arm/mach-imx/mxc.h7
-rw-r--r--arch/arm/mach-imx/pm-imx6.c29
-rw-r--r--arch/arm/mach-mvebu/board-v7.c14
-rw-r--r--arch/arm/mach-omap1/ams-delta-fiq-handler.S12
-rw-r--r--arch/arm/mach-omap1/board-ams-delta.c161
-rw-r--r--arch/arm/mach-omap1/include/mach/board-ams-delta.h7
-rw-r--r--arch/arm/mach-omap2/omap_hwmod.c88
-rw-r--r--arch/arm/mach-shmobile/Kconfig10
-rw-r--r--arch/arm/mach-shmobile/headsmp-scu.S13
-rw-r--r--arch/arm/mach-shmobile/headsmp.S7
-rw-r--r--arch/arm/mach-shmobile/platsmp-scu.c5
-rw-r--r--arch/arm/mach-shmobile/platsmp.c5
-rw-r--r--arch/arm/mach-shmobile/pm-rcar-gen2.c5
-rw-r--r--arch/arm/mach-shmobile/pm-rmobile.c7
-rw-r--r--arch/arm/mach-shmobile/pm-rmobile.h7
-rw-r--r--arch/arm/mach-shmobile/regulator-quirk-rcar-gen2.c139
-rw-r--r--arch/arm/mach-shmobile/setup-r8a7779.c2
-rw-r--r--arch/arm/mach-shmobile/setup-rcar-gen2.c2
-rw-r--r--arch/arm/mach-shmobile/smp-sh73a0.c10
-rw-r--r--arch/arm/mach-shmobile/suspend.c5
-rw-r--r--arch/arm/mach-shmobile/timer.c10
-rw-r--r--arch/arm/mach-u300/Kconfig13
-rw-r--r--arch/arm/mach-u300/Makefile1
-rw-r--r--arch/arm/mach-u300/dummyspichip.c276
-rw-r--r--arch/arm/mach-zynq/slcr.c2
-rw-r--r--arch/arm/plat-samsung/Kconfig2
-rw-r--r--arch/arm64/Kconfig.platforms60
-rw-r--r--include/linux/platform_data/gpio-omap.h5
36 files changed, 567 insertions, 659 deletions
diff --git a/Documentation/devicetree/bindings/net/marvell,prestera.txt b/Documentation/devicetree/bindings/net/marvell,prestera.txt
index c329608fa887..83370ebf5b89 100644
--- a/Documentation/devicetree/bindings/net/marvell,prestera.txt
+++ b/Documentation/devicetree/bindings/net/marvell,prestera.txt
@@ -2,7 +2,7 @@ Marvell Prestera Switch Chip bindings
2------------------------------------- 2-------------------------------------
3 3
4Required properties: 4Required properties:
5- compatible: one of the following 5- compatible: must be "marvell,prestera" and one of the following
6 "marvell,prestera-98dx3236", 6 "marvell,prestera-98dx3236",
7 "marvell,prestera-98dx3336", 7 "marvell,prestera-98dx3336",
8 "marvell,prestera-98dx4251", 8 "marvell,prestera-98dx4251",
@@ -21,7 +21,7 @@ switch {
21 ranges = <0 MBUS_ID(0x03, 0x00) 0 0x100000>; 21 ranges = <0 MBUS_ID(0x03, 0x00) 0 0x100000>;
22 22
23 packet-processor@0 { 23 packet-processor@0 {
24 compatible = "marvell,prestera-98dx3236"; 24 compatible = "marvell,prestera-98dx3236", "marvell,prestera";
25 reg = <0 0x4000000>; 25 reg = <0 0x4000000>;
26 interrupts = <33>, <34>, <35>; 26 interrupts = <33>, <34>, <35>;
27 dfx = <&dfx>; 27 dfx = <&dfx>;
diff --git a/MAINTAINERS b/MAINTAINERS
index 85365afe3059..930241eb6e2d 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1087,6 +1087,29 @@ F: arch/arm/include/asm/arch_timer.h
1087F: arch/arm64/include/asm/arch_timer.h 1087F: arch/arm64/include/asm/arch_timer.h
1088F: drivers/clocksource/arm_arch_timer.c 1088F: drivers/clocksource/arm_arch_timer.c
1089 1089
1090ARM INTEGRATOR, VERSATILE AND REALVIEW SUPPORT
1091M: Linus Walleij <linus.walleij@linaro.org>
1092L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1093S: Maintained
1094F: Documentation/devicetree/bindings/arm/arm-boards
1095F: Documentation/devicetree/bindings/auxdisplay/arm-charlcd.txt
1096F: Documentation/devicetree/bindings/clock/arm-integrator.txt
1097F: Documentation/devicetree/bindings/interrupt-controller/arm,versatile-fpga-irq.txt
1098F: Documentation/devicetree/bindings/mtd/arm-versatile.txt
1099F: arch/arm/mach-integrator/
1100F: arch/arm/mach-realview/
1101F: arch/arm/mach-versatile/
1102F: arch/arm/plat-versatile/
1103F: arch/arm/boot/dts/arm-realview-*
1104F: arch/arm/boot/dts/integrator*
1105F: arch/arm/boot/dts/versatile*
1106F: drivers/clk/versatile/
1107F: drivers/i2c/busses/i2c-versatile.c
1108F: drivers/irqchip/irq-versatile-fpga.c
1109F: drivers/mtd/maps/physmap_of_versatile.c
1110F: drivers/power/reset/arm-versatile-reboot.c
1111F: drivers/soc/versatile/
1112
1090ARM HDLCD DRM DRIVER 1113ARM HDLCD DRM DRIVER
1091M: Liviu Dudau <liviu.dudau@arm.com> 1114M: Liviu Dudau <liviu.dudau@arm.com>
1092S: Supported 1115S: Supported
@@ -1159,12 +1182,26 @@ S: Odd Fixes
1159F: drivers/mmc/host/mmci.* 1182F: drivers/mmc/host/mmci.*
1160F: include/linux/amba/mmci.h 1183F: include/linux/amba/mmci.h
1161 1184
1185ARM PRIMECELL SSP PL022 SPI DRIVER
1186M: Linus Walleij <linus.walleij@linaro.org>
1187L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1188S: Maintained
1189F: Documentation/devicetree/bindings/spi/spi_pl022.txt
1190F: drivers/spi/spi-pl022.c
1191
1162ARM PRIMECELL UART PL010 AND PL011 DRIVERS 1192ARM PRIMECELL UART PL010 AND PL011 DRIVERS
1163M: Russell King <linux@armlinux.org.uk> 1193M: Russell King <linux@armlinux.org.uk>
1164S: Odd Fixes 1194S: Odd Fixes
1165F: drivers/tty/serial/amba-pl01*.c 1195F: drivers/tty/serial/amba-pl01*.c
1166F: include/linux/amba/serial.h 1196F: include/linux/amba/serial.h
1167 1197
1198ARM PRIMECELL VIC PL190/PL192 DRIVER
1199M: Linus Walleij <linus.walleij@linaro.org>
1200L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1201S: Maintained
1202F: Documentation/devicetree/bindings/interrupt-controller/arm,vic.txt
1203F: drivers/irqchip/irq-vic.c
1204
1168ARM SMMU DRIVERS 1205ARM SMMU DRIVERS
1169M: Will Deacon <will.deacon@arm.com> 1206M: Will Deacon <will.deacon@arm.com>
1170R: Robin Murphy <robin.murphy@arm.com> 1207R: Robin Murphy <robin.murphy@arm.com>
@@ -1184,18 +1221,25 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc.git
1184 1221
1185ARM/ACTIONS SEMI ARCHITECTURE 1222ARM/ACTIONS SEMI ARCHITECTURE
1186M: Andreas Färber <afaerber@suse.de> 1223M: Andreas Färber <afaerber@suse.de>
1224R: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
1187L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 1225L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1188S: Maintained 1226S: Maintained
1189N: owl 1227N: owl
1190F: arch/arm/mach-actions/ 1228F: arch/arm/mach-actions/
1191F: arch/arm/boot/dts/owl-* 1229F: arch/arm/boot/dts/owl-*
1192F: arch/arm64/boot/dts/actions/ 1230F: arch/arm64/boot/dts/actions/
1231F: drivers/clk/actions/
1193F: drivers/clocksource/timer-owl* 1232F: drivers/clocksource/timer-owl*
1233F: drivers/dma/owl-dma.c
1234F: drivers/i2c/busses/i2c-owl.c
1194F: drivers/pinctrl/actions/* 1235F: drivers/pinctrl/actions/*
1195F: drivers/soc/actions/ 1236F: drivers/soc/actions/
1196F: include/dt-bindings/power/owl-* 1237F: include/dt-bindings/power/owl-*
1197F: include/linux/soc/actions/ 1238F: include/linux/soc/actions/
1198F: Documentation/devicetree/bindings/arm/actions.txt 1239F: Documentation/devicetree/bindings/arm/actions.txt
1240F: Documentation/devicetree/bindings/clock/actions,owl-cmu.txt
1241F: Documentation/devicetree/bindings/dma/owl-dma.txt
1242F: Documentation/devicetree/bindings/i2c/i2c-owl.txt
1199F: Documentation/devicetree/bindings/pinctrl/actions,s900-pinctrl.txt 1243F: Documentation/devicetree/bindings/pinctrl/actions,s900-pinctrl.txt
1200F: Documentation/devicetree/bindings/power/actions,owl-sps.txt 1244F: Documentation/devicetree/bindings/power/actions,owl-sps.txt
1201F: Documentation/devicetree/bindings/timer/actions,owl-timer.txt 1245F: Documentation/devicetree/bindings/timer/actions,owl-timer.txt
@@ -1610,12 +1654,10 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1610S: Maintained 1654S: Maintained
1611 1655
1612ARM/LPC18XX ARCHITECTURE 1656ARM/LPC18XX ARCHITECTURE
1613M: Joachim Eastwood <manabian@gmail.com> 1657M: Vladimir Zapolskiy <vz@mleia.com>
1614L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 1658L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1615S: Maintained 1659S: Maintained
1616F: arch/arm/boot/dts/lpc43* 1660F: arch/arm/boot/dts/lpc43*
1617F: drivers/clk/nxp/clk-lpc18xx*
1618F: drivers/clocksource/timer-lpc32xx.c
1619F: drivers/i2c/busses/i2c-lpc2k.c 1661F: drivers/i2c/busses/i2c-lpc2k.c
1620F: drivers/memory/pl172.c 1662F: drivers/memory/pl172.c
1621F: drivers/mtd/spi-nor/nxp-spifi.c 1663F: drivers/mtd/spi-nor/nxp-spifi.c
@@ -1714,9 +1756,10 @@ S: Odd Fixes
1714ARM/Microchip (AT91) SoC support 1756ARM/Microchip (AT91) SoC support
1715M: Nicolas Ferre <nicolas.ferre@microchip.com> 1757M: Nicolas Ferre <nicolas.ferre@microchip.com>
1716M: Alexandre Belloni <alexandre.belloni@bootlin.com> 1758M: Alexandre Belloni <alexandre.belloni@bootlin.com>
1759M: Ludovic Desroches <ludovic.desroches@microchip.com>
1717L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 1760L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
1718W: http://www.linux4sam.org 1761W: http://www.linux4sam.org
1719T: git git://git.kernel.org/pub/scm/linux/kernel/git/nferre/linux-at91.git 1762T: git git://git.kernel.org/pub/scm/linux/kernel/git/at91/linux.git
1720S: Supported 1763S: Supported
1721N: at91 1764N: at91
1722N: atmel 1765N: atmel
@@ -2096,22 +2139,24 @@ F: include/linux/remoteproc/st_slim_rproc.h
2096ARM/STM32 ARCHITECTURE 2139ARM/STM32 ARCHITECTURE
2097M: Maxime Coquelin <mcoquelin.stm32@gmail.com> 2140M: Maxime Coquelin <mcoquelin.stm32@gmail.com>
2098M: Alexandre Torgue <alexandre.torgue@st.com> 2141M: Alexandre Torgue <alexandre.torgue@st.com>
2142L: linux-stm32@st-md-mailman.stormreply.com (moderated for non-subscribers)
2099L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 2143L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2100S: Maintained 2144S: Maintained
2101T: git git://git.kernel.org/pub/scm/linux/kernel/git/atorgue/stm32.git stm32-next 2145T: git git://git.kernel.org/pub/scm/linux/kernel/git/atorgue/stm32.git stm32-next
2102N: stm32 2146N: stm32
2147N: stm
2103F: arch/arm/boot/dts/stm32* 2148F: arch/arm/boot/dts/stm32*
2104F: arch/arm/mach-stm32/ 2149F: arch/arm/mach-stm32/
2105F: drivers/clocksource/armv7m_systick.c 2150F: drivers/clocksource/armv7m_systick.c
2106 2151
2107ARM/Synaptics Berlin SoC support 2152ARM/Synaptics SoC support
2108M: Jisheng Zhang <Jisheng.Zhang@synaptics.com> 2153M: Jisheng Zhang <Jisheng.Zhang@synaptics.com>
2109M: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com> 2154M: Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
2110L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 2155L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2111S: Maintained 2156S: Maintained
2112F: arch/arm/mach-berlin/ 2157F: arch/arm/mach-berlin/
2113F: arch/arm/boot/dts/berlin* 2158F: arch/arm/boot/dts/berlin*
2114F: arch/arm64/boot/dts/marvell/berlin* 2159F: arch/arm64/boot/dts/synaptics/
2115 2160
2116ARM/TANGO ARCHITECTURE 2161ARM/TANGO ARCHITECTURE
2117M: Marc Gonzalez <marc.w.gonzalez@free.fr> 2162M: Marc Gonzalez <marc.w.gonzalez@free.fr>
@@ -2275,7 +2320,6 @@ F: arch/arm/mach-pxa/include/mach/z2.h
2275 2320
2276ARM/ZTE ARCHITECTURE 2321ARM/ZTE ARCHITECTURE
2277M: Jun Nie <jun.nie@linaro.org> 2322M: Jun Nie <jun.nie@linaro.org>
2278M: Baoyou Xie <baoyou.xie@linaro.org>
2279M: Shawn Guo <shawnguo@kernel.org> 2323M: Shawn Guo <shawnguo@kernel.org>
2280L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 2324L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2281S: Maintained 2325S: Maintained
@@ -2483,42 +2527,6 @@ F: drivers/atm/
2483F: include/linux/atm* 2527F: include/linux/atm*
2484F: include/uapi/linux/atm* 2528F: include/uapi/linux/atm*
2485 2529
2486ATMEL AT91 / AT32 MCI DRIVER
2487M: Ludovic Desroches <ludovic.desroches@microchip.com>
2488S: Maintained
2489F: drivers/mmc/host/atmel-mci.c
2490
2491ATMEL AT91 SAMA5D2-Compatible Shutdown Controller
2492M: Nicolas Ferre <nicolas.ferre@microchip.com>
2493S: Supported
2494F: drivers/power/reset/at91-sama5d2_shdwc.c
2495
2496ATMEL Audio ALSA driver
2497M: Nicolas Ferre <nicolas.ferre@microchip.com>
2498L: alsa-devel@alsa-project.org (moderated for non-subscribers)
2499S: Supported
2500F: sound/soc/atmel
2501
2502ATMEL I2C DRIVER
2503M: Ludovic Desroches <ludovic.desroches@microchip.com>
2504L: linux-i2c@vger.kernel.org
2505S: Supported
2506F: drivers/i2c/busses/i2c-at91.c
2507
2508ATMEL ISI DRIVER
2509M: Ludovic Desroches <ludovic.desroches@microchip.com>
2510L: linux-media@vger.kernel.org
2511S: Supported
2512F: drivers/media/platform/atmel/atmel-isi.c
2513F: include/media/atmel-isi.h
2514
2515ATMEL LCDFB DRIVER
2516M: Nicolas Ferre <nicolas.ferre@microchip.com>
2517L: linux-fbdev@vger.kernel.org
2518S: Maintained
2519F: drivers/video/fbdev/atmel_lcdfb.c
2520F: include/video/atmel_lcdc.h
2521
2522ATMEL MACB ETHERNET DRIVER 2530ATMEL MACB ETHERNET DRIVER
2523M: Nicolas Ferre <nicolas.ferre@microchip.com> 2531M: Nicolas Ferre <nicolas.ferre@microchip.com>
2524S: Supported 2532S: Supported
@@ -2531,43 +2539,6 @@ S: Maintained
2531F: Documentation/devicetree/bindings/input/atmel,maxtouch.txt 2539F: Documentation/devicetree/bindings/input/atmel,maxtouch.txt
2532F: drivers/input/touchscreen/atmel_mxt_ts.c 2540F: drivers/input/touchscreen/atmel_mxt_ts.c
2533 2541
2534ATMEL SAMA5D2 ADC DRIVER
2535M: Ludovic Desroches <ludovic.desroches@microchip.com>
2536L: linux-iio@vger.kernel.org
2537S: Supported
2538F: drivers/iio/adc/at91-sama5d2_adc.c
2539
2540ATMEL SDMMC DRIVER
2541M: Ludovic Desroches <ludovic.desroches@microchip.com>
2542L: linux-mmc@vger.kernel.org
2543S: Supported
2544F: drivers/mmc/host/sdhci-of-at91.c
2545
2546ATMEL SPI DRIVER
2547M: Nicolas Ferre <nicolas.ferre@microchip.com>
2548S: Supported
2549F: drivers/spi/spi-atmel.*
2550
2551ATMEL SSC DRIVER
2552M: Nicolas Ferre <nicolas.ferre@microchip.com>
2553L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2554S: Supported
2555F: drivers/misc/atmel-ssc.c
2556F: include/linux/atmel-ssc.h
2557
2558ATMEL Timer Counter (TC) AND CLOCKSOURCE DRIVERS
2559M: Nicolas Ferre <nicolas.ferre@microchip.com>
2560L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2561S: Supported
2562F: drivers/misc/atmel_tclib.c
2563F: drivers/clocksource/tcb_clksrc.c
2564
2565ATMEL USBA UDC DRIVER
2566M: Nicolas Ferre <nicolas.ferre@microchip.com>
2567L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
2568S: Supported
2569F: drivers/usb/gadget/udc/atmel_usba_udc.*
2570
2571ATMEL WIRELESS DRIVER 2542ATMEL WIRELESS DRIVER
2572M: Simon Kelley <simon@thekelleys.org.uk> 2543M: Simon Kelley <simon@thekelleys.org.uk>
2573L: linux-wireless@vger.kernel.org 2544L: linux-wireless@vger.kernel.org
@@ -2576,13 +2547,6 @@ W: http://atmelwlandriver.sourceforge.net/
2576S: Maintained 2547S: Maintained
2577F: drivers/net/wireless/atmel/atmel* 2548F: drivers/net/wireless/atmel/atmel*
2578 2549
2579ATMEL XDMA DRIVER
2580M: Ludovic Desroches <ludovic.desroches@microchip.com>
2581L: linux-arm-kernel@lists.infradead.org
2582L: dmaengine@vger.kernel.org
2583S: Supported
2584F: drivers/dma/at_xdmac.c
2585
2586ATOMIC INFRASTRUCTURE 2550ATOMIC INFRASTRUCTURE
2587M: Will Deacon <will.deacon@arm.com> 2551M: Will Deacon <will.deacon@arm.com>
2588M: Peter Zijlstra <peterz@infradead.org> 2552M: Peter Zijlstra <peterz@infradead.org>
@@ -8899,7 +8863,7 @@ S: Maintained
8899F: drivers/net/phy/marvell10g.c 8863F: drivers/net/phy/marvell10g.c
8900 8864
8901MARVELL MVNETA ETHERNET DRIVER 8865MARVELL MVNETA ETHERNET DRIVER
8902M: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 8866M: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
8903L: netdev@vger.kernel.org 8867L: netdev@vger.kernel.org
8904S: Maintained 8868S: Maintained
8905F: drivers/net/ethernet/marvell/mvneta.* 8869F: drivers/net/ethernet/marvell/mvneta.*
@@ -9624,14 +9588,20 @@ T: git git://git.monstr.eu/linux-2.6-microblaze.git
9624S: Supported 9588S: Supported
9625F: arch/microblaze/ 9589F: arch/microblaze/
9626 9590
9627MICROCHIP / ATMEL AT91 SERIAL DRIVER 9591MICROCHIP AT91 SERIAL DRIVER
9628M: Richard Genoud <richard.genoud@gmail.com> 9592M: Richard Genoud <richard.genoud@gmail.com>
9629S: Maintained 9593S: Maintained
9630F: drivers/tty/serial/atmel_serial.c 9594F: drivers/tty/serial/atmel_serial.c
9631F: drivers/tty/serial/atmel_serial.h 9595F: drivers/tty/serial/atmel_serial.h
9632F: Documentation/devicetree/bindings/mfd/atmel-usart.txt 9596F: Documentation/devicetree/bindings/mfd/atmel-usart.txt
9633 9597
9634MICROCHIP / ATMEL DMA DRIVER 9598MICROCHIP AUDIO ASOC DRIVERS
9599M: Codrin Ciubotariu <codrin.ciubotariu@microchip.com>
9600L: alsa-devel@alsa-project.org (moderated for non-subscribers)
9601S: Supported
9602F: sound/soc/atmel
9603
9604MICROCHIP DMA DRIVER
9635M: Ludovic Desroches <ludovic.desroches@microchip.com> 9605M: Ludovic Desroches <ludovic.desroches@microchip.com>
9636L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 9606L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
9637L: dmaengine@vger.kernel.org 9607L: dmaengine@vger.kernel.org
@@ -9639,27 +9609,35 @@ S: Supported
9639F: drivers/dma/at_hdmac.c 9609F: drivers/dma/at_hdmac.c
9640F: drivers/dma/at_hdmac_regs.h 9610F: drivers/dma/at_hdmac_regs.h
9641F: include/linux/platform_data/dma-atmel.h 9611F: include/linux/platform_data/dma-atmel.h
9612F: Documentation/devicetree/bindings/dma/atmel-dma.txt
9613F: include/dt-bindings/dma/at91.h
9642 9614
9643MICROCHIP / ATMEL ECC DRIVER 9615MICROCHIP ECC DRIVER
9644M: Tudor Ambarus <tudor.ambarus@microchip.com> 9616M: Tudor Ambarus <tudor.ambarus@microchip.com>
9645L: linux-crypto@vger.kernel.org 9617L: linux-crypto@vger.kernel.org
9646S: Maintained 9618S: Maintained
9647F: drivers/crypto/atmel-ecc.* 9619F: drivers/crypto/atmel-ecc.*
9648 9620
9649MICROCHIP / ATMEL ISC DRIVER 9621MICROCHIP I2C DRIVER
9650M: Songjun Wu <songjun.wu@microchip.com> 9622M: Ludovic Desroches <ludovic.desroches@microchip.com>
9623L: linux-i2c@vger.kernel.org
9624S: Supported
9625F: drivers/i2c/busses/i2c-at91.c
9626
9627MICROCHIP ISC DRIVER
9628M: Eugen Hristev <eugen.hristev@microchip.com>
9651L: linux-media@vger.kernel.org 9629L: linux-media@vger.kernel.org
9652S: Supported 9630S: Supported
9653F: drivers/media/platform/atmel/atmel-isc.c 9631F: drivers/media/platform/atmel/atmel-isc.c
9654F: drivers/media/platform/atmel/atmel-isc-regs.h 9632F: drivers/media/platform/atmel/atmel-isc-regs.h
9655F: devicetree/bindings/media/atmel-isc.txt 9633F: devicetree/bindings/media/atmel-isc.txt
9656 9634
9657MICROCHIP / ATMEL NAND DRIVER 9635MICROCHIP ISI DRIVER
9658M: Josh Wu <rainyfeeling@outlook.com> 9636M: Eugen Hristev <eugen.hristev@microchip.com>
9659L: linux-mtd@lists.infradead.org 9637L: linux-media@vger.kernel.org
9660S: Supported 9638S: Supported
9661F: drivers/mtd/nand/raw/atmel/* 9639F: drivers/media/platform/atmel/atmel-isi.c
9662F: Documentation/devicetree/bindings/mtd/atmel-nand.txt 9640F: include/media/atmel-isi.h
9663 9641
9664MICROCHIP AT91 USART MFD DRIVER 9642MICROCHIP AT91 USART MFD DRIVER
9665M: Radu Pirea <radu_nicolae.pirea@upb.ro> 9643M: Radu Pirea <radu_nicolae.pirea@upb.ro>
@@ -9693,7 +9671,19 @@ L: netdev@vger.kernel.org
9693S: Maintained 9671S: Maintained
9694F: drivers/net/ethernet/microchip/lan743x_* 9672F: drivers/net/ethernet/microchip/lan743x_*
9695 9673
9696MICROCHIP / ATMEL MCP3911 ADC DRIVER 9674MICROCHIP LCDFB DRIVER
9675M: Nicolas Ferre <nicolas.ferre@microchip.com>
9676L: linux-fbdev@vger.kernel.org
9677S: Maintained
9678F: drivers/video/fbdev/atmel_lcdfb.c
9679F: include/video/atmel_lcdc.h
9680
9681MICROCHIP MMC/SD/SDIO MCI DRIVER
9682M: Ludovic Desroches <ludovic.desroches@microchip.com>
9683S: Maintained
9684F: drivers/mmc/host/atmel-mci.c
9685
9686MICROCHIP MCP3911 ADC DRIVER
9697M: Marcus Folkesson <marcus.folkesson@gmail.com> 9687M: Marcus Folkesson <marcus.folkesson@gmail.com>
9698M: Kent Gustavsson <kent@minoris.se> 9688M: Kent Gustavsson <kent@minoris.se>
9699L: linux-iio@vger.kernel.org 9689L: linux-iio@vger.kernel.org
@@ -9701,6 +9691,60 @@ S: Supported
9701F: drivers/iio/adc/mcp3911.c 9691F: drivers/iio/adc/mcp3911.c
9702F: Documentation/devicetree/bindings/iio/adc/mcp3911.txt 9692F: Documentation/devicetree/bindings/iio/adc/mcp3911.txt
9703 9693
9694MICROCHIP NAND DRIVER
9695M: Tudor Ambarus <tudor.ambarus@microchip.com>
9696L: linux-mtd@lists.infradead.org
9697S: Supported
9698F: drivers/mtd/nand/raw/atmel/*
9699F: Documentation/devicetree/bindings/mtd/atmel-nand.txt
9700
9701MICROCHIP PWM DRIVER
9702M: Claudiu Beznea <claudiu.beznea@microchip.com>
9703L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
9704L: linux-pwm@vger.kernel.org
9705S: Supported
9706F: drivers/pwm/pwm-atmel.c
9707F: Documentation/devicetree/bindings/pwm/atmel-pwm.txt
9708
9709MICROCHIP SAMA5D2-COMPATIBLE ADC DRIVER
9710M: Ludovic Desroches <ludovic.desroches@microchip.com>
9711M: Eugen Hristev <eugen.hristev@microchip.com>
9712L: linux-iio@vger.kernel.org
9713S: Supported
9714F: drivers/iio/adc/at91-sama5d2_adc.c
9715F: Documentation/devicetree/bindings/iio/adc/at91-sama5d2_adc.txt
9716F: include/dt-bindings/iio/adc/at91-sama5d2_adc.h
9717
9718MICROCHIP SAMA5D2-COMPATIBLE SHUTDOWN CONTROLLER
9719M: Nicolas Ferre <nicolas.ferre@microchip.com>
9720S: Supported
9721F: drivers/power/reset/at91-sama5d2_shdwc.c
9722
9723MICROCHIP SPI DRIVER
9724M: Nicolas Ferre <nicolas.ferre@microchip.com>
9725S: Supported
9726F: drivers/spi/spi-atmel.*
9727
9728MICROCHIP SSC DRIVER
9729M: Nicolas Ferre <nicolas.ferre@microchip.com>
9730L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
9731S: Supported
9732F: drivers/misc/atmel-ssc.c
9733F: include/linux/atmel-ssc.h
9734
9735MICROCHIP TIMER COUNTER (TC) AND CLOCKSOURCE DRIVERS
9736M: Nicolas Ferre <nicolas.ferre@microchip.com>
9737L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
9738S: Supported
9739F: drivers/misc/atmel_tclib.c
9740F: drivers/clocksource/tcb_clksrc.c
9741
9742MICROCHIP USBA UDC DRIVER
9743M: Cristian Birsan <cristian.birsan@microchip.com>
9744L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
9745S: Supported
9746F: drivers/usb/gadget/udc/atmel_usba_udc.*
9747
9704MICROCHIP USB251XB DRIVER 9748MICROCHIP USB251XB DRIVER
9705M: Richard Leitner <richard.leitner@skidata.com> 9749M: Richard Leitner <richard.leitner@skidata.com>
9706L: linux-usb@vger.kernel.org 9750L: linux-usb@vger.kernel.org
@@ -9708,6 +9752,13 @@ S: Maintained
9708F: drivers/usb/misc/usb251xb.c 9752F: drivers/usb/misc/usb251xb.c
9709F: Documentation/devicetree/bindings/usb/usb251xb.txt 9753F: Documentation/devicetree/bindings/usb/usb251xb.txt
9710 9754
9755MICROCHIP XDMA DRIVER
9756M: Ludovic Desroches <ludovic.desroches@microchip.com>
9757L: linux-arm-kernel@lists.infradead.org
9758L: dmaengine@vger.kernel.org
9759S: Supported
9760F: drivers/dma/at_xdmac.c
9761
9711MICROSEMI MIPS SOCS 9762MICROSEMI MIPS SOCS
9712M: Alexandre Belloni <alexandre.belloni@bootlin.com> 9763M: Alexandre Belloni <alexandre.belloni@bootlin.com>
9713L: linux-mips@linux-mips.org 9764L: linux-mips@linux-mips.org
@@ -11191,7 +11242,7 @@ S: Maintained
11191F: drivers/firmware/pcdp.* 11242F: drivers/firmware/pcdp.*
11192 11243
11193PCI DRIVER FOR AARDVARK (Marvell Armada 3700) 11244PCI DRIVER FOR AARDVARK (Marvell Armada 3700)
11194M: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 11245M: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
11195L: linux-pci@vger.kernel.org 11246L: linux-pci@vger.kernel.org
11196L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 11247L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
11197S: Maintained 11248S: Maintained
@@ -11223,7 +11274,7 @@ F: Documentation/devicetree/bindings/pci/versatile.txt
11223F: drivers/pci/controller/pci-versatile.c 11274F: drivers/pci/controller/pci-versatile.c
11224 11275
11225PCI DRIVER FOR ARMADA 8K 11276PCI DRIVER FOR ARMADA 8K
11226M: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 11277M: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
11227L: linux-pci@vger.kernel.org 11278L: linux-pci@vger.kernel.org
11228L: linux-arm-kernel@lists.infradead.org 11279L: linux-arm-kernel@lists.infradead.org
11229S: Maintained 11280S: Maintained
@@ -11292,7 +11343,7 @@ F: Documentation/devicetree/bindings/pci/mobiveil-pcie.txt
11292F: drivers/pci/controller/pcie-mobiveil.c 11343F: drivers/pci/controller/pcie-mobiveil.c
11293 11344
11294PCI DRIVER FOR MVEBU (Marvell Armada 370 and Armada XP SOC support) 11345PCI DRIVER FOR MVEBU (Marvell Armada 370 and Armada XP SOC support)
11295M: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> 11346M: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
11296M: Jason Cooper <jason@lakedaemon.net> 11347M: Jason Cooper <jason@lakedaemon.net>
11297L: linux-pci@vger.kernel.org 11348L: linux-pci@vger.kernel.org
11298L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 11349L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
@@ -13203,6 +13254,12 @@ L: linux-mmc@vger.kernel.org
13203S: Maintained 13254S: Maintained
13204F: drivers/mmc/host/sdhci-pci-dwc-mshc.c 13255F: drivers/mmc/host/sdhci-pci-dwc-mshc.c
13205 13256
13257SECURE DIGITAL HOST CONTROLLER INTERFACE (SDHCI) MICROCHIP DRIVER
13258M: Ludovic Desroches <ludovic.desroches@microchip.com>
13259L: linux-mmc@vger.kernel.org
13260S: Supported
13261F: drivers/mmc/host/sdhci-of-at91.c
13262
13206SECURE DIGITAL HOST CONTROLLER INTERFACE (SDHCI) SAMSUNG DRIVER 13263SECURE DIGITAL HOST CONTROLLER INTERFACE (SDHCI) SAMSUNG DRIVER
13207M: Ben Dooks <ben-linux@fluff.org> 13264M: Ben Dooks <ben-linux@fluff.org>
13208M: Jaehoon Chung <jh80.chung@samsung.com> 13265M: Jaehoon Chung <jh80.chung@samsung.com>
@@ -14626,7 +14683,6 @@ F: Documentation/devicetree/bindings/arm/keystone/ti,sci.txt
14626F: drivers/firmware/ti_sci* 14683F: drivers/firmware/ti_sci*
14627F: include/linux/soc/ti/ti_sci_protocol.h 14684F: include/linux/soc/ti/ti_sci_protocol.h
14628F: Documentation/devicetree/bindings/soc/ti/sci-pm-domain.txt 14685F: Documentation/devicetree/bindings/soc/ti/sci-pm-domain.txt
14629F: include/dt-bindings/genpd/k2g.h
14630F: drivers/soc/ti/ti_sci_pm_domains.c 14686F: drivers/soc/ti/ti_sci_pm_domains.c
14631F: Documentation/devicetree/bindings/reset/ti,sci-reset.txt 14687F: Documentation/devicetree/bindings/reset/ti,sci-reset.txt
14632F: Documentation/devicetree/bindings/clock/ti,sci-clk.txt 14688F: Documentation/devicetree/bindings/clock/ti,sci-clk.txt
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index e8cd55a5b04c..b8c6062ca0c1 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -701,6 +701,7 @@ config ARCH_VIRT
701 select ARM_GIC_V3_ITS if PCI 701 select ARM_GIC_V3_ITS if PCI
702 select ARM_PSCI 702 select ARM_PSCI
703 select HAVE_ARM_ARCH_TIMER 703 select HAVE_ARM_ARCH_TIMER
704 select ARCH_SUPPORTS_BIG_ENDIAN
704 705
705# 706#
706# This is sorted alphabetically by mach-* pathname. However, plat-* 707# This is sorted alphabetically by mach-* pathname. However, plat-*
diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index a810fa8ba404..d6a49f59ecd9 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -947,12 +947,13 @@ choice
947 947
948 config DEBUG_RCAR_GEN2_SCIF0 948 config DEBUG_RCAR_GEN2_SCIF0
949 bool "Kernel low-level debugging messages via SCIF0 on R-Car Gen2 and RZ/G1" 949 bool "Kernel low-level debugging messages via SCIF0 on R-Car Gen2 and RZ/G1"
950 depends on ARCH_R8A7743 || ARCH_R8A7790 || ARCH_R8A7791 || \ 950 depends on ARCH_R8A7743 || ARCH_R8A7744 || ARCH_R8A7790 || \
951 ARCH_R8A7792 || ARCH_R8A7793 951 ARCH_R8A7791 || ARCH_R8A7792 || ARCH_R8A7793
952 help 952 help
953 Say Y here if you want kernel low-level debugging support 953 Say Y here if you want kernel low-level debugging support
954 via SCIF0 on Renesas RZ/G1M (R8A7743), R-Car H2 (R8A7790), 954 via SCIF0 on Renesas RZ/G1M (R8A7743), RZ/G1N (R8A7744),
955 M2-W (R8A7791), V2H (R8A7792), or M2-N (R8A7793). 955 R-Car H2 (R8A7790), M2-W (R8A7791), V2H (R8A7792), or
956 M2-N (R8A7793).
956 957
957 config DEBUG_RCAR_GEN2_SCIF1 958 config DEBUG_RCAR_GEN2_SCIF1
958 bool "Kernel low-level debugging messages via SCIF1 on R8A77470" 959 bool "Kernel low-level debugging messages via SCIF1 on R8A77470"
diff --git a/arch/arm/mach-at91/pm.c b/arch/arm/mach-at91/pm.c
index 32fae4dbd63b..51e808adb00c 100644
--- a/arch/arm/mach-at91/pm.c
+++ b/arch/arm/mach-at91/pm.c
@@ -143,15 +143,15 @@ static int at91_pm_config_ws(unsigned int pm_mode, bool set)
143 143
144 /* Check if enabled on SHDWC. */ 144 /* Check if enabled on SHDWC. */
145 if (wsi->shdwc_mr_bit && !(val & wsi->shdwc_mr_bit)) 145 if (wsi->shdwc_mr_bit && !(val & wsi->shdwc_mr_bit))
146 goto put_node; 146 goto put_device;
147 147
148 mode |= wsi->pmc_fsmr_bit; 148 mode |= wsi->pmc_fsmr_bit;
149 if (wsi->set_polarity) 149 if (wsi->set_polarity)
150 polarity |= wsi->pmc_fsmr_bit; 150 polarity |= wsi->pmc_fsmr_bit;
151 } 151 }
152 152
153put_node: 153put_device:
154 of_node_put(np); 154 put_device(&pdev->dev);
155 } 155 }
156 156
157 if (mode) { 157 if (mode) {
@@ -580,8 +580,6 @@ static int __init at91_pm_backup_init(void)
580 if (!at91_is_pm_mode_active(AT91_PM_BACKUP)) 580 if (!at91_is_pm_mode_active(AT91_PM_BACKUP))
581 return 0; 581 return 0;
582 582
583 pm_bu = NULL;
584
585 np = of_find_compatible_node(NULL, NULL, "atmel,sama5d2-sfrbu"); 583 np = of_find_compatible_node(NULL, NULL, "atmel,sama5d2-sfrbu");
586 if (!np) { 584 if (!np) {
587 pr_warn("%s: failed to find sfrbu!\n", __func__); 585 pr_warn("%s: failed to find sfrbu!\n", __func__);
@@ -590,7 +588,6 @@ static int __init at91_pm_backup_init(void)
590 588
591 pm_data.sfrbu = of_iomap(np, 0); 589 pm_data.sfrbu = of_iomap(np, 0);
592 of_node_put(np); 590 of_node_put(np);
593 pm_bu = NULL;
594 591
595 np = of_find_compatible_node(NULL, NULL, "atmel,sama5d2-securam"); 592 np = of_find_compatible_node(NULL, NULL, "atmel,sama5d2-securam");
596 if (!np) 593 if (!np)
diff --git a/arch/arm/mach-imx/anatop.c b/arch/arm/mach-imx/anatop.c
index 61f3d94f1633..45d618abf26b 100644
--- a/arch/arm/mach-imx/anatop.c
+++ b/arch/arm/mach-imx/anatop.c
@@ -31,6 +31,8 @@
31#define ANADIG_DIGPROG_IMX6SL 0x280 31#define ANADIG_DIGPROG_IMX6SL 0x280
32#define ANADIG_DIGPROG_IMX7D 0x800 32#define ANADIG_DIGPROG_IMX7D 0x800
33 33
34#define SRC_SBMR2 0x1c
35
34#define BM_ANADIG_REG_2P5_ENABLE_WEAK_LINREG 0x40000 36#define BM_ANADIG_REG_2P5_ENABLE_WEAK_LINREG 0x40000
35#define BM_ANADIG_REG_2P5_ENABLE_PULLDOWN 0x8 37#define BM_ANADIG_REG_2P5_ENABLE_PULLDOWN 0x8
36#define BM_ANADIG_REG_CORE_FET_ODRIVE 0x20000000 38#define BM_ANADIG_REG_CORE_FET_ODRIVE 0x20000000
@@ -148,6 +150,24 @@ void __init imx_init_revision_from_anatop(void)
148 major_part = (digprog >> 8) & 0xf; 150 major_part = (digprog >> 8) & 0xf;
149 minor_part = digprog & 0xf; 151 minor_part = digprog & 0xf;
150 revision = ((major_part + 1) << 4) | minor_part; 152 revision = ((major_part + 1) << 4) | minor_part;
153
154 if ((digprog >> 16) == MXC_CPU_IMX6ULL) {
155 void __iomem *src_base;
156 u32 sbmr2;
157
158 np = of_find_compatible_node(NULL, NULL,
159 "fsl,imx6ul-src");
160 src_base = of_iomap(np, 0);
161 WARN_ON(!src_base);
162 sbmr2 = readl_relaxed(src_base + SRC_SBMR2);
163 iounmap(src_base);
164
165 /* src_sbmr2 bit 6 is to identify if it is i.MX6ULZ */
166 if (sbmr2 & (1 << 6)) {
167 digprog &= ~(0xff << 16);
168 digprog |= (MXC_CPU_IMX6ULZ << 16);
169 }
170 }
151 } 171 }
152 172
153 mxc_set_cpu_type(digprog >> 16 & 0xff); 173 mxc_set_cpu_type(digprog >> 16 & 0xff);
diff --git a/arch/arm/mach-imx/cpu.c b/arch/arm/mach-imx/cpu.c
index c6b1bf97a6c1..c73593e09121 100644
--- a/arch/arm/mach-imx/cpu.c
+++ b/arch/arm/mach-imx/cpu.c
@@ -136,6 +136,9 @@ struct device * __init imx_soc_device_init(void)
136 case MXC_CPU_IMX6ULL: 136 case MXC_CPU_IMX6ULL:
137 soc_id = "i.MX6ULL"; 137 soc_id = "i.MX6ULL";
138 break; 138 break;
139 case MXC_CPU_IMX6ULZ:
140 soc_id = "i.MX6ULZ";
141 break;
139 case MXC_CPU_IMX6SLL: 142 case MXC_CPU_IMX6SLL:
140 soc_id = "i.MX6SLL"; 143 soc_id = "i.MX6SLL";
141 break; 144 break;
diff --git a/arch/arm/mach-imx/mmdc.c b/arch/arm/mach-imx/mmdc.c
index 04b3bf71de94..e49e06834516 100644
--- a/arch/arm/mach-imx/mmdc.c
+++ b/arch/arm/mach-imx/mmdc.c
@@ -11,6 +11,7 @@
11 * http://www.gnu.org/copyleft/gpl.html 11 * http://www.gnu.org/copyleft/gpl.html
12 */ 12 */
13 13
14#include <linux/clk.h>
14#include <linux/hrtimer.h> 15#include <linux/hrtimer.h>
15#include <linux/init.h> 16#include <linux/init.h>
16#include <linux/interrupt.h> 17#include <linux/interrupt.h>
@@ -546,7 +547,20 @@ static int imx_mmdc_probe(struct platform_device *pdev)
546{ 547{
547 struct device_node *np = pdev->dev.of_node; 548 struct device_node *np = pdev->dev.of_node;
548 void __iomem *mmdc_base, *reg; 549 void __iomem *mmdc_base, *reg;
550 struct clk *mmdc_ipg_clk;
549 u32 val; 551 u32 val;
552 int err;
553
554 /* the ipg clock is optional */
555 mmdc_ipg_clk = devm_clk_get(&pdev->dev, NULL);
556 if (IS_ERR(mmdc_ipg_clk))
557 mmdc_ipg_clk = NULL;
558
559 err = clk_prepare_enable(mmdc_ipg_clk);
560 if (err) {
561 dev_err(&pdev->dev, "Unable to enable mmdc ipg clock.\n");
562 return err;
563 }
550 564
551 mmdc_base = of_iomap(np, 0); 565 mmdc_base = of_iomap(np, 0);
552 WARN_ON(!mmdc_base); 566 WARN_ON(!mmdc_base);
diff --git a/arch/arm/mach-imx/mxc.h b/arch/arm/mach-imx/mxc.h
index 026e2ca45f1e..b130a53ff62a 100644
--- a/arch/arm/mach-imx/mxc.h
+++ b/arch/arm/mach-imx/mxc.h
@@ -40,6 +40,8 @@
40#define MXC_CPU_IMX6Q 0x63 40#define MXC_CPU_IMX6Q 0x63
41#define MXC_CPU_IMX6UL 0x64 41#define MXC_CPU_IMX6UL 0x64
42#define MXC_CPU_IMX6ULL 0x65 42#define MXC_CPU_IMX6ULL 0x65
43/* virtual cpu id for i.mx6ulz */
44#define MXC_CPU_IMX6ULZ 0x6b
43#define MXC_CPU_IMX6SLL 0x67 45#define MXC_CPU_IMX6SLL 0x67
44#define MXC_CPU_IMX7D 0x72 46#define MXC_CPU_IMX7D 0x72
45 47
@@ -80,6 +82,11 @@ static inline bool cpu_is_imx6ull(void)
80 return __mxc_cpu_type == MXC_CPU_IMX6ULL; 82 return __mxc_cpu_type == MXC_CPU_IMX6ULL;
81} 83}
82 84
85static inline bool cpu_is_imx6ulz(void)
86{
87 return __mxc_cpu_type == MXC_CPU_IMX6ULZ;
88}
89
83static inline bool cpu_is_imx6sll(void) 90static inline bool cpu_is_imx6sll(void)
84{ 91{
85 return __mxc_cpu_type == MXC_CPU_IMX6SLL; 92 return __mxc_cpu_type == MXC_CPU_IMX6SLL;
diff --git a/arch/arm/mach-imx/pm-imx6.c b/arch/arm/mach-imx/pm-imx6.c
index b08e407d8d96..87f45b926c78 100644
--- a/arch/arm/mach-imx/pm-imx6.c
+++ b/arch/arm/mach-imx/pm-imx6.c
@@ -313,7 +313,7 @@ int imx6_set_lpm(enum mxc_cpu_pwr_mode mode)
313 if (cpu_is_imx6sl()) 313 if (cpu_is_imx6sl())
314 val |= BM_CLPCR_BYPASS_PMIC_READY; 314 val |= BM_CLPCR_BYPASS_PMIC_READY;
315 if (cpu_is_imx6sl() || cpu_is_imx6sx() || cpu_is_imx6ul() || 315 if (cpu_is_imx6sl() || cpu_is_imx6sx() || cpu_is_imx6ul() ||
316 cpu_is_imx6ull() || cpu_is_imx6sll()) 316 cpu_is_imx6ull() || cpu_is_imx6sll() || cpu_is_imx6ulz())
317 val |= BM_CLPCR_BYP_MMDC_CH0_LPM_HS; 317 val |= BM_CLPCR_BYP_MMDC_CH0_LPM_HS;
318 else 318 else
319 val |= BM_CLPCR_BYP_MMDC_CH1_LPM_HS; 319 val |= BM_CLPCR_BYP_MMDC_CH1_LPM_HS;
@@ -331,7 +331,7 @@ int imx6_set_lpm(enum mxc_cpu_pwr_mode mode)
331 if (cpu_is_imx6sl() || cpu_is_imx6sx()) 331 if (cpu_is_imx6sl() || cpu_is_imx6sx())
332 val |= BM_CLPCR_BYPASS_PMIC_READY; 332 val |= BM_CLPCR_BYPASS_PMIC_READY;
333 if (cpu_is_imx6sl() || cpu_is_imx6sx() || cpu_is_imx6ul() || 333 if (cpu_is_imx6sl() || cpu_is_imx6sx() || cpu_is_imx6ul() ||
334 cpu_is_imx6ull() || cpu_is_imx6sll()) 334 cpu_is_imx6ull() || cpu_is_imx6sll() || cpu_is_imx6ulz())
335 val |= BM_CLPCR_BYP_MMDC_CH0_LPM_HS; 335 val |= BM_CLPCR_BYP_MMDC_CH0_LPM_HS;
336 else 336 else
337 val |= BM_CLPCR_BYP_MMDC_CH1_LPM_HS; 337 val |= BM_CLPCR_BYP_MMDC_CH1_LPM_HS;
@@ -618,6 +618,28 @@ static void __init imx6_pm_common_init(const struct imx6_pm_socdata
618 IMX6Q_GPR1_GINT); 618 IMX6Q_GPR1_GINT);
619} 619}
620 620
621static void imx6_pm_stby_poweroff(void)
622{
623 imx6_set_lpm(STOP_POWER_OFF);
624 imx6q_suspend_finish(0);
625
626 mdelay(1000);
627
628 pr_emerg("Unable to poweroff system\n");
629}
630
631static int imx6_pm_stby_poweroff_probe(void)
632{
633 if (pm_power_off) {
634 pr_warn("%s: pm_power_off already claimed %p %pf!\n",
635 __func__, pm_power_off, pm_power_off);
636 return -EBUSY;
637 }
638
639 pm_power_off = imx6_pm_stby_poweroff;
640 return 0;
641}
642
621void __init imx6_pm_ccm_init(const char *ccm_compat) 643void __init imx6_pm_ccm_init(const char *ccm_compat)
622{ 644{
623 struct device_node *np; 645 struct device_node *np;
@@ -634,6 +656,9 @@ void __init imx6_pm_ccm_init(const char *ccm_compat)
634 val = readl_relaxed(ccm_base + CLPCR); 656 val = readl_relaxed(ccm_base + CLPCR);
635 val &= ~BM_CLPCR_LPM; 657 val &= ~BM_CLPCR_LPM;
636 writel_relaxed(val, ccm_base + CLPCR); 658 writel_relaxed(val, ccm_base + CLPCR);
659
660 if (of_property_read_bool(np, "fsl,pmic-stby-poweroff"))
661 imx6_pm_stby_poweroff_probe();
637} 662}
638 663
639void __init imx6q_pm_init(void) 664void __init imx6q_pm_init(void)
diff --git a/arch/arm/mach-mvebu/board-v7.c b/arch/arm/mach-mvebu/board-v7.c
index ccca95173e17..0b10acd7d1b9 100644
--- a/arch/arm/mach-mvebu/board-v7.c
+++ b/arch/arm/mach-mvebu/board-v7.c
@@ -145,6 +145,13 @@ static void __init mvebu_dt_init(void)
145 i2c_quirk(); 145 i2c_quirk();
146} 146}
147 147
148static void __init armada_370_xp_dt_fixup(void)
149{
150#ifdef CONFIG_SMP
151 smp_set_ops(smp_ops(armada_xp_smp_ops));
152#endif
153}
154
148static const char * const armada_370_xp_dt_compat[] __initconst = { 155static const char * const armada_370_xp_dt_compat[] __initconst = {
149 "marvell,armada-370-xp", 156 "marvell,armada-370-xp",
150 NULL, 157 NULL,
@@ -153,17 +160,12 @@ static const char * const armada_370_xp_dt_compat[] __initconst = {
153DT_MACHINE_START(ARMADA_370_XP_DT, "Marvell Armada 370/XP (Device Tree)") 160DT_MACHINE_START(ARMADA_370_XP_DT, "Marvell Armada 370/XP (Device Tree)")
154 .l2c_aux_val = 0, 161 .l2c_aux_val = 0,
155 .l2c_aux_mask = ~0, 162 .l2c_aux_mask = ~0,
156/*
157 * The following field (.smp) is still needed to ensure backward
158 * compatibility with old Device Trees that were not specifying the
159 * cpus enable-method property.
160 */
161 .smp = smp_ops(armada_xp_smp_ops),
162 .init_machine = mvebu_dt_init, 163 .init_machine = mvebu_dt_init,
163 .init_irq = mvebu_init_irq, 164 .init_irq = mvebu_init_irq,
164 .restart = mvebu_restart, 165 .restart = mvebu_restart,
165 .reserve = mvebu_memblock_reserve, 166 .reserve = mvebu_memblock_reserve,
166 .dt_compat = armada_370_xp_dt_compat, 167 .dt_compat = armada_370_xp_dt_compat,
168 .dt_fixup = armada_370_xp_dt_fixup,
167MACHINE_END 169MACHINE_END
168 170
169static const char * const armada_375_dt_compat[] __initconst = { 171static const char * const armada_375_dt_compat[] __initconst = {
diff --git a/arch/arm/mach-omap1/ams-delta-fiq-handler.S b/arch/arm/mach-omap1/ams-delta-fiq-handler.S
index ddc27638ba2a..e3faa0274b56 100644
--- a/arch/arm/mach-omap1/ams-delta-fiq-handler.S
+++ b/arch/arm/mach-omap1/ams-delta-fiq-handler.S
@@ -15,6 +15,7 @@
15 15
16#include <linux/linkage.h> 16#include <linux/linkage.h>
17#include <linux/platform_data/ams-delta-fiq.h> 17#include <linux/platform_data/ams-delta-fiq.h>
18#include <linux/platform_data/gpio-omap.h>
18 19
19#include <asm/assembler.h> 20#include <asm/assembler.h>
20#include <mach/board-ams-delta.h> 21#include <mach/board-ams-delta.h>
@@ -24,17 +25,10 @@
24#include "soc.h" 25#include "soc.h"
25 26
26/* 27/*
27 * GPIO related definitions, copied from arch/arm/plat-omap/gpio.c. 28 * OMAP1510 GPIO related symbol copied from arch/arm/mach-omap1/gpio15xx.c.
28 * Unfortunately, those were not placed in a separate header file. 29 * Unfortunately, it was not placed in a separate header file.
29 */ 30 */
30#define OMAP1510_GPIO_BASE 0xFFFCE000 31#define OMAP1510_GPIO_BASE 0xFFFCE000
31#define OMAP1510_GPIO_DATA_INPUT 0x00
32#define OMAP1510_GPIO_DATA_OUTPUT 0x04
33#define OMAP1510_GPIO_DIR_CONTROL 0x08
34#define OMAP1510_GPIO_INT_CONTROL 0x0c
35#define OMAP1510_GPIO_INT_MASK 0x10
36#define OMAP1510_GPIO_INT_STATUS 0x14
37#define OMAP1510_GPIO_PIN_CONTROL 0x18
38 32
39/* GPIO register bitmasks */ 33/* GPIO register bitmasks */
40#define KEYBRD_DATA_MASK (0x1 << AMS_DELTA_GPIO_PIN_KEYBRD_DATA) 34#define KEYBRD_DATA_MASK (0x1 << AMS_DELTA_GPIO_PIN_KEYBRD_DATA)
diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
index f226973f3d8c..af318d958fd2 100644
--- a/arch/arm/mach-omap1/board-ams-delta.c
+++ b/arch/arm/mach-omap1/board-ams-delta.c
@@ -250,39 +250,6 @@ static struct platform_device latch2_gpio_device = {
250#define LATCH2_PIN_HOOKFLASH1 14 250#define LATCH2_PIN_HOOKFLASH1 14
251#define LATCH2_PIN_HOOKFLASH2 15 251#define LATCH2_PIN_HOOKFLASH2 15
252 252
253static const struct gpio latch_gpios[] __initconst = {
254 {
255 .gpio = LATCH1_GPIO_BASE + 6,
256 .flags = GPIOF_OUT_INIT_LOW,
257 .label = "dockit1",
258 },
259 {
260 .gpio = LATCH1_GPIO_BASE + 7,
261 .flags = GPIOF_OUT_INIT_LOW,
262 .label = "dockit2",
263 },
264 {
265 .gpio = AMS_DELTA_GPIO_PIN_SCARD_RSTIN,
266 .flags = GPIOF_OUT_INIT_LOW,
267 .label = "scard_rstin",
268 },
269 {
270 .gpio = AMS_DELTA_GPIO_PIN_SCARD_CMDVCC,
271 .flags = GPIOF_OUT_INIT_LOW,
272 .label = "scard_cmdvcc",
273 },
274 {
275 .gpio = AMS_DELTA_LATCH2_GPIO_BASE + 14,
276 .flags = GPIOF_OUT_INIT_LOW,
277 .label = "hookflash1",
278 },
279 {
280 .gpio = AMS_DELTA_LATCH2_GPIO_BASE + 15,
281 .flags = GPIOF_OUT_INIT_LOW,
282 .label = "hookflash2",
283 },
284};
285
286static struct regulator_consumer_supply modem_nreset_consumers[] = { 253static struct regulator_consumer_supply modem_nreset_consumers[] = {
287 REGULATOR_SUPPLY("RESET#", "serial8250.1"), 254 REGULATOR_SUPPLY("RESET#", "serial8250.1"),
288 REGULATOR_SUPPLY("POR", "cx20442-codec"), 255 REGULATOR_SUPPLY("POR", "cx20442-codec"),
@@ -329,20 +296,6 @@ struct modem_private_data {
329 296
330static struct modem_private_data modem_priv; 297static struct modem_private_data modem_priv;
331 298
332void ams_delta_latch_write(int base, int ngpio, u16 mask, u16 value)
333{
334 int bit = 0;
335 u16 bitpos = 1 << bit;
336
337 for (; bit < ngpio; bit++, bitpos = bitpos << 1) {
338 if (!(mask & bitpos))
339 continue;
340 else
341 gpio_set_value(base + bit, (value & bitpos) != 0);
342 }
343}
344EXPORT_SYMBOL(ams_delta_latch_write);
345
346static struct resource ams_delta_nand_resources[] = { 299static struct resource ams_delta_nand_resources[] = {
347 [0] = { 300 [0] = {
348 .start = OMAP1_MPUIO_BASE, 301 .start = OMAP1_MPUIO_BASE,
@@ -638,6 +591,28 @@ static struct gpiod_hog ams_delta_gpio_hogs[] = {
638 {}, 591 {},
639}; 592};
640 593
594static struct plat_serial8250_port ams_delta_modem_ports[];
595
596/*
597 * Obtain MODEM IRQ GPIO descriptor using its hardware pin
598 * number and assign related IRQ number to the MODEM port.
599 * Keep the GPIO descriptor open so nobody steps in.
600 */
601static void __init modem_assign_irq(struct gpio_chip *chip)
602{
603 struct gpio_desc *gpiod;
604
605 gpiod = gpiochip_request_own_desc(chip, AMS_DELTA_GPIO_PIN_MODEM_IRQ,
606 "modem_irq");
607 if (IS_ERR(gpiod)) {
608 pr_err("%s: modem IRQ GPIO request failed (%ld)\n", __func__,
609 PTR_ERR(gpiod));
610 } else {
611 gpiod_direction_input(gpiod);
612 ams_delta_modem_ports[0].irq = gpiod_to_irq(gpiod);
613 }
614}
615
641/* 616/*
642 * The purpose of this function is to take care of proper initialization of 617 * The purpose of this function is to take care of proper initialization of
643 * devices and data structures which depend on GPIO lines provided by OMAP GPIO 618 * devices and data structures which depend on GPIO lines provided by OMAP GPIO
@@ -657,7 +632,47 @@ static void __init omap_gpio_deps_init(void)
657 return; 632 return;
658 } 633 }
659 634
635 /*
636 * Start with FIQ initialization as it may have to request
637 * and release successfully each OMAP GPIO pin in turn.
638 */
660 ams_delta_init_fiq(chip, &ams_delta_serio_device); 639 ams_delta_init_fiq(chip, &ams_delta_serio_device);
640
641 modem_assign_irq(chip);
642}
643
644/*
645 * Initialize latch2 pins with values which are safe for dependent on-board
646 * devices or useful for their successull initialization even before GPIO
647 * driver takes control over the latch pins:
648 * - LATCH2_PIN_LCD_VBLEN = 0
649 * - LATCH2_PIN_LCD_NDISP = 0 Keep LCD device powered off before its
650 * driver takes control over it.
651 * - LATCH2_PIN_NAND_NCE = 0
652 * - LATCH2_PIN_NAND_NWP = 0 Keep NAND device down and write-
653 * protected before its driver takes
654 * control over it.
655 * - LATCH2_PIN_KEYBRD_PWR = 0 Keep keyboard powered off before serio
656 * driver takes control over it.
657 * - LATCH2_PIN_KEYBRD_DATAOUT = 0 Keep low to avoid corruption of first
658 * byte of data received from attached
659 * keyboard when serio device is probed;
660 * the pin is also hogged low by the latch2
661 * GPIO driver as soon as it is ready.
662 * - LATCH2_PIN_MODEM_NRESET = 1 Enable voice MODEM device, allowing for
663 * its successful probe even before a
664 * regulator it depends on, which in turn
665 * takes control over the pin, is set up.
666 * - LATCH2_PIN_MODEM_CODEC = 1 Attach voice MODEM CODEC data port
667 * to the MODEM so the CODEC is under
668 * control even if audio driver doesn't
669 * take it over.
670 */
671static void __init ams_delta_latch2_init(void)
672{
673 u16 latch2 = 1 << LATCH2_PIN_MODEM_NRESET | 1 << LATCH2_PIN_MODEM_CODEC;
674
675 __raw_writew(latch2, LATCH2_VIRT);
661} 676}
662 677
663static void __init ams_delta_init(void) 678static void __init ams_delta_init(void)
@@ -681,6 +696,7 @@ static void __init ams_delta_init(void)
681 omap_cfg_reg(J18_1610_CAM_D7); 696 omap_cfg_reg(J18_1610_CAM_D7);
682 697
683 omap_gpio_deps_init(); 698 omap_gpio_deps_init();
699 ams_delta_latch2_init();
684 gpiod_add_hogs(ams_delta_gpio_hogs); 700 gpiod_add_hogs(ams_delta_gpio_hogs);
685 701
686 omap_serial_init(); 702 omap_serial_init();
@@ -821,7 +837,6 @@ static void __init ams_delta_led_init(struct gpio_chip *chip)
821static int __init ams_delta_gpio_init(void) 837static int __init ams_delta_gpio_init(void)
822{ 838{
823 struct gpio_chip *chip; 839 struct gpio_chip *chip;
824 int err;
825 840
826 if (!machine_is_ams_delta()) 841 if (!machine_is_ams_delta())
827 return -ENODEV; 842 return -ENODEV;
@@ -832,11 +847,7 @@ static int __init ams_delta_gpio_init(void)
832 else 847 else
833 ams_delta_led_init(chip); 848 ams_delta_led_init(chip);
834 849
835 err = gpio_request_array(latch_gpios, ARRAY_SIZE(latch_gpios)); 850 return 0;
836 if (err)
837 pr_err("Couldn't take over latch1/latch2 GPIO pins\n");
838
839 return err;
840} 851}
841device_initcall_sync(ams_delta_gpio_init); 852device_initcall_sync(ams_delta_gpio_init);
842 853
@@ -852,33 +863,44 @@ static int __init modem_nreset_init(void)
852} 863}
853 864
854 865
866/*
867 * This function expects MODEM IRQ number already assigned to the port
868 * and fails if it's not.
869 * The MODEM device requires its RESET# pin kept high during probe.
870 * That requirement can be fulfilled in several ways:
871 * - with a descriptor of already functional modem_nreset regulator
872 * assigned to the MODEM private data,
873 * - with the regulator not yet controlled by modem_pm function but
874 * already enabled by default on probe,
875 * - before the modem_nreset regulator is probed, with the pin already
876 * set high explicitly.
877 * The last one is already guaranteed by ams_delta_latch2_init() called
878 * from machine_init.
879 * In order to avoid taking over ttyS0 device slot, the MODEM device
880 * should be registered after OMAP serial ports. Since those ports
881 * are registered at arch_initcall, this function can be called safely
882 * at arch_initcall_sync earliest.
883 */
855static int __init ams_delta_modem_init(void) 884static int __init ams_delta_modem_init(void)
856{ 885{
857 int err; 886 int err;
858 887
859 omap_cfg_reg(M14_1510_GPIO2); 888 if (!machine_is_ams_delta())
860 ams_delta_modem_ports[0].irq = 889 return -ENODEV;
861 gpio_to_irq(AMS_DELTA_GPIO_PIN_MODEM_IRQ);
862 890
863 err = gpio_request(AMS_DELTA_GPIO_PIN_MODEM_IRQ, "modem"); 891 if (ams_delta_modem_ports[0].irq < 0)
864 if (err) { 892 return ams_delta_modem_ports[0].irq;
865 pr_err("Couldn't request gpio pin for modem\n"); 893
866 return err; 894 omap_cfg_reg(M14_1510_GPIO2);
867 }
868 gpio_direction_input(AMS_DELTA_GPIO_PIN_MODEM_IRQ);
869 895
870 /* Initialize the modem_nreset regulator consumer before use */ 896 /* Initialize the modem_nreset regulator consumer before use */
871 modem_priv.regulator = ERR_PTR(-ENODEV); 897 modem_priv.regulator = ERR_PTR(-ENODEV);
872 898
873 ams_delta_latch2_write(AMS_DELTA_LATCH2_MODEM_CODEC,
874 AMS_DELTA_LATCH2_MODEM_CODEC);
875
876 err = platform_device_register(&ams_delta_modem_device); 899 err = platform_device_register(&ams_delta_modem_device);
877 if (err)
878 gpio_free(AMS_DELTA_GPIO_PIN_MODEM_IRQ);
879 900
880 return err; 901 return err;
881} 902}
903arch_initcall_sync(ams_delta_modem_init);
882 904
883static int __init late_init(void) 905static int __init late_init(void)
884{ 906{
@@ -888,10 +910,6 @@ static int __init late_init(void)
888 if (err) 910 if (err)
889 return err; 911 return err;
890 912
891 err = ams_delta_modem_init();
892 if (err)
893 return err;
894
895 /* 913 /*
896 * Once the modem device is registered, the modem_nreset 914 * Once the modem device is registered, the modem_nreset
897 * regulator can be requested on behalf of that device. 915 * regulator can be requested on behalf of that device.
@@ -906,7 +924,6 @@ static int __init late_init(void)
906 924
907unregister: 925unregister:
908 platform_device_unregister(&ams_delta_modem_device); 926 platform_device_unregister(&ams_delta_modem_device);
909 gpio_free(AMS_DELTA_GPIO_PIN_MODEM_IRQ);
910 return err; 927 return err;
911} 928}
912 929
diff --git a/arch/arm/mach-omap1/include/mach/board-ams-delta.h b/arch/arm/mach-omap1/include/mach/board-ams-delta.h
index ad6f865d1f16..3b2d8019238a 100644
--- a/arch/arm/mach-omap1/include/mach/board-ams-delta.h
+++ b/arch/arm/mach-omap1/include/mach/board-ams-delta.h
@@ -59,13 +59,6 @@
59#define AMS_DELTA_LATCH2_GPIO_BASE AMS_DELTA_GPIO_PIN_LCD_VBLEN 59#define AMS_DELTA_LATCH2_GPIO_BASE AMS_DELTA_GPIO_PIN_LCD_VBLEN
60#define AMS_DELTA_LATCH2_NGPIO 16 60#define AMS_DELTA_LATCH2_NGPIO 16
61 61
62#ifndef __ASSEMBLY__
63void ams_delta_latch_write(int base, int ngpio, u16 mask, u16 value);
64#define ams_delta_latch2_write(mask, value) \
65 ams_delta_latch_write(AMS_DELTA_LATCH2_GPIO_BASE, \
66 AMS_DELTA_LATCH2_NGPIO, (mask), (value))
67#endif
68
69#endif /* CONFIG_MACH_AMS_DELTA */ 62#endif /* CONFIG_MACH_AMS_DELTA */
70 63
71#endif /* __ASM_ARCH_OMAP_AMS_DELTA_H */ 64#endif /* __ASM_ARCH_OMAP_AMS_DELTA_H */
diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c
index cd65ea4e9c54..56a1fe90d394 100644
--- a/arch/arm/mach-omap2/omap_hwmod.c
+++ b/arch/arm/mach-omap2/omap_hwmod.c
@@ -188,16 +188,16 @@
188 188
189/** 189/**
190 * struct clkctrl_provider - clkctrl provider mapping data 190 * struct clkctrl_provider - clkctrl provider mapping data
191 * @addr: base address for the provider 191 * @num_addrs: number of base address ranges for the provider
192 * @size: size of the provider address space 192 * @addr: base address(es) for the provider
193 * @offset: offset of the provider from PRCM instance base 193 * @size: size(s) of the provider address space(s)
194 * @node: device node associated with the provider 194 * @node: device node associated with the provider
195 * @link: list link 195 * @link: list link
196 */ 196 */
197struct clkctrl_provider { 197struct clkctrl_provider {
198 u32 addr; 198 int num_addrs;
199 u32 size; 199 u32 *addr;
200 u16 offset; 200 u32 *size;
201 struct device_node *node; 201 struct device_node *node;
202 struct list_head link; 202 struct list_head link;
203}; 203};
@@ -724,23 +724,34 @@ static int __init _setup_clkctrl_provider(struct device_node *np)
724 const __be32 *addrp; 724 const __be32 *addrp;
725 struct clkctrl_provider *provider; 725 struct clkctrl_provider *provider;
726 u64 size; 726 u64 size;
727 int i;
727 728
728 provider = memblock_virt_alloc(sizeof(*provider), 0); 729 provider = memblock_virt_alloc(sizeof(*provider), 0);
729 if (!provider) 730 if (!provider)
730 return -ENOMEM; 731 return -ENOMEM;
731 732
732 addrp = of_get_address(np, 0, &size, NULL);
733 provider->addr = (u32)of_translate_address(np, addrp);
734 addrp = of_get_address(np->parent, 0, NULL, NULL);
735 provider->offset = provider->addr -
736 (u32)of_translate_address(np->parent, addrp);
737 provider->addr &= ~0xff;
738 provider->size = size | 0xff;
739 provider->node = np; 733 provider->node = np;
740 734
741 pr_debug("%s: %s: %x...%x [+%x]\n", __func__, np->parent->name, 735 provider->num_addrs =
742 provider->addr, provider->addr + provider->size, 736 of_property_count_elems_of_size(np, "reg", sizeof(u32)) / 2;
743 provider->offset); 737
738 provider->addr =
739 memblock_virt_alloc(sizeof(void *) * provider->num_addrs, 0);
740 if (!provider->addr)
741 return -ENOMEM;
742
743 provider->size =
744 memblock_virt_alloc(sizeof(u32) * provider->num_addrs, 0);
745 if (!provider->size)
746 return -ENOMEM;
747
748 for (i = 0; i < provider->num_addrs; i++) {
749 addrp = of_get_address(np, i, &size, NULL);
750 provider->addr[i] = (u32)of_translate_address(np, addrp);
751 provider->size[i] = size;
752 pr_debug("%s: %pOF: %x...%x\n", __func__, np, provider->addr[i],
753 provider->addr[i] + provider->size[i]);
754 }
744 755
745 list_add(&provider->link, &clkctrl_providers); 756 list_add(&provider->link, &clkctrl_providers);
746 757
@@ -787,23 +798,26 @@ static struct clk *_lookup_clkctrl_clk(struct omap_hwmod *oh)
787 pr_debug("%s: %s: addr=%x\n", __func__, oh->name, addr); 798 pr_debug("%s: %s: addr=%x\n", __func__, oh->name, addr);
788 799
789 list_for_each_entry(provider, &clkctrl_providers, link) { 800 list_for_each_entry(provider, &clkctrl_providers, link) {
790 if (provider->addr <= addr && 801 int i;
791 provider->addr + provider->size >= addr) {
792 struct of_phandle_args clkspec;
793 802
794 clkspec.np = provider->node; 803 for (i = 0; i < provider->num_addrs; i++) {
795 clkspec.args_count = 2; 804 if (provider->addr[i] <= addr &&
796 clkspec.args[0] = addr - provider->addr - 805 provider->addr[i] + provider->size[i] > addr) {
797 provider->offset; 806 struct of_phandle_args clkspec;
798 clkspec.args[1] = 0;
799 807
800 clk = of_clk_get_from_provider(&clkspec); 808 clkspec.np = provider->node;
809 clkspec.args_count = 2;
810 clkspec.args[0] = addr - provider->addr[0];
811 clkspec.args[1] = 0;
801 812
802 pr_debug("%s: %s got %p (offset=%x, provider=%s)\n", 813 clk = of_clk_get_from_provider(&clkspec);
803 __func__, oh->name, clk, clkspec.args[0],
804 provider->node->parent->name);
805 814
806 return clk; 815 pr_debug("%s: %s got %p (offset=%x, provider=%pOF)\n",
816 __func__, oh->name, clk,
817 clkspec.args[0], provider->node);
818
819 return clk;
820 }
807 } 821 }
808 } 822 }
809 823
@@ -2107,8 +2121,8 @@ static int of_dev_find_hwmod(struct device_node *np,
2107 if (res) 2121 if (res)
2108 continue; 2122 continue;
2109 if (!strcmp(p, oh->name)) { 2123 if (!strcmp(p, oh->name)) {
2110 pr_debug("omap_hwmod: dt %s[%i] uses hwmod %s\n", 2124 pr_debug("omap_hwmod: dt %pOFn[%i] uses hwmod %s\n",
2111 np->name, i, oh->name); 2125 np, i, oh->name);
2112 return i; 2126 return i;
2113 } 2127 }
2114 } 2128 }
@@ -2241,8 +2255,8 @@ int omap_hwmod_parse_module_range(struct omap_hwmod *oh,
2241 return -ENOENT; 2255 return -ENOENT;
2242 2256
2243 if (nr_addr != 1 || nr_size != 1) { 2257 if (nr_addr != 1 || nr_size != 1) {
2244 pr_err("%s: invalid range for %s->%s\n", __func__, 2258 pr_err("%s: invalid range for %s->%pOFn\n", __func__,
2245 oh->name, np->name); 2259 oh->name, np);
2246 return -EINVAL; 2260 return -EINVAL;
2247 } 2261 }
2248 2262
@@ -2250,8 +2264,8 @@ int omap_hwmod_parse_module_range(struct omap_hwmod *oh,
2250 base = of_translate_address(np, ranges++); 2264 base = of_translate_address(np, ranges++);
2251 size = be32_to_cpup(ranges); 2265 size = be32_to_cpup(ranges);
2252 2266
2253 pr_debug("omap_hwmod: %s %s at 0x%llx size 0x%llx\n", 2267 pr_debug("omap_hwmod: %s %pOFn at 0x%llx size 0x%llx\n",
2254 oh ? oh->name : "", np->name, base, size); 2268 oh->name, np, base, size);
2255 2269
2256 if (oh && oh->mpu_rt_idx) { 2270 if (oh && oh->mpu_rt_idx) {
2257 omap_hwmod_fix_mpu_rt_idx(oh, np, res); 2271 omap_hwmod_fix_mpu_rt_idx(oh, np, res);
@@ -2359,8 +2373,8 @@ static int __init _init(struct omap_hwmod *oh, void *data)
2359 if (r) 2373 if (r)
2360 pr_debug("omap_hwmod: %s missing dt data\n", oh->name); 2374 pr_debug("omap_hwmod: %s missing dt data\n", oh->name);
2361 else if (np && index) 2375 else if (np && index)
2362 pr_warn("omap_hwmod: %s using broken dt data from %s\n", 2376 pr_warn("omap_hwmod: %s using broken dt data from %pOFn\n",
2363 oh->name, np->name); 2377 oh->name, np);
2364 2378
2365 r = _init_mpu_rt_base(oh, NULL, index, np); 2379 r = _init_mpu_rt_base(oh, NULL, index, np);
2366 if (r < 0) { 2380 if (r < 0) {
diff --git a/arch/arm/mach-shmobile/Kconfig b/arch/arm/mach-shmobile/Kconfig
index 94e9431d92b8..b100c26a858f 100644
--- a/arch/arm/mach-shmobile/Kconfig
+++ b/arch/arm/mach-shmobile/Kconfig
@@ -1,6 +1,4 @@
1config ARCH_SHMOBILE 1# SPDX-License-Identifier: GPL-2.0
2 bool
3
4config PM_RMOBILE 2config PM_RMOBILE
5 bool 3 bool
6 select PM 4 select PM
@@ -30,7 +28,6 @@ config ARCH_RMOBILE
30menuconfig ARCH_RENESAS 28menuconfig ARCH_RENESAS
31 bool "Renesas ARM SoCs" 29 bool "Renesas ARM SoCs"
32 depends on ARCH_MULTI_V7 && MMU 30 depends on ARCH_MULTI_V7 && MMU
33 select ARCH_SHMOBILE
34 select ARM_GIC 31 select ARM_GIC
35 select GPIOLIB 32 select GPIOLIB
36 select HAVE_ARM_SCU if SMP 33 select HAVE_ARM_SCU if SMP
@@ -78,6 +75,11 @@ config ARCH_R8A7743
78 select ARCH_RCAR_GEN2 75 select ARCH_RCAR_GEN2
79 select ARM_ERRATA_798181 if SMP 76 select ARM_ERRATA_798181 if SMP
80 77
78config ARCH_R8A7744
79 bool "RZ/G1N (R8A77440)"
80 select ARCH_RCAR_GEN2
81 select ARM_ERRATA_798181 if SMP
82
81config ARCH_R8A7745 83config ARCH_R8A7745
82 bool "RZ/G1E (R8A77450)" 84 bool "RZ/G1E (R8A77450)"
83 select ARCH_RCAR_GEN2 85 select ARCH_RCAR_GEN2
diff --git a/arch/arm/mach-shmobile/headsmp-scu.S b/arch/arm/mach-shmobile/headsmp-scu.S
index 936d7011c314..d0234296ae62 100644
--- a/arch/arm/mach-shmobile/headsmp-scu.S
+++ b/arch/arm/mach-shmobile/headsmp-scu.S
@@ -1,17 +1,8 @@
1/* 1/* SPDX-License-Identifier: GPL-2.0+
2 *
2 * Shared SCU setup for mach-shmobile 3 * Shared SCU setup for mach-shmobile
3 * 4 *
4 * Copyright (C) 2012 Bastian Hecht 5 * Copyright (C) 2012 Bastian Hecht
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as
8 * published by the Free Software Foundation; either version 2 of
9 * the License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR /PURPOSE. See the
14 * GNU General Public License for more details.
15 */ 6 */
16 7
17#include <linux/linkage.h> 8#include <linux/linkage.h>
diff --git a/arch/arm/mach-shmobile/headsmp.S b/arch/arm/mach-shmobile/headsmp.S
index cef8e8c555f8..9466ae61f56a 100644
--- a/arch/arm/mach-shmobile/headsmp.S
+++ b/arch/arm/mach-shmobile/headsmp.S
@@ -1,14 +1,11 @@
1/* 1/* SPDX-License-Identifier: GPL-2.0
2 *
2 * SMP support for R-Mobile / SH-Mobile 3 * SMP support for R-Mobile / SH-Mobile
3 * 4 *
4 * Copyright (C) 2010 Magnus Damm 5 * Copyright (C) 2010 Magnus Damm
5 * Copyright (C) 2010 Takashi Yoshii 6 * Copyright (C) 2010 Takashi Yoshii
6 * 7 *
7 * Based on vexpress, Copyright (c) 2003 ARM Limited, All Rights Reserved 8 * Based on vexpress, Copyright (c) 2003 ARM Limited, All Rights Reserved
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
12 */ 9 */
13#include <linux/init.h> 10#include <linux/init.h>
14#include <linux/linkage.h> 11#include <linux/linkage.h>
diff --git a/arch/arm/mach-shmobile/platsmp-scu.c b/arch/arm/mach-shmobile/platsmp-scu.c
index f1a1efde4beb..fcfcef1d1ae4 100644
--- a/arch/arm/mach-shmobile/platsmp-scu.c
+++ b/arch/arm/mach-shmobile/platsmp-scu.c
@@ -1,11 +1,8 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * SMP support for SoCs with SCU covered by mach-shmobile 3 * SMP support for SoCs with SCU covered by mach-shmobile
3 * 4 *
4 * Copyright (C) 2013 Magnus Damm 5 * Copyright (C) 2013 Magnus Damm
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */ 6 */
10#include <linux/cpu.h> 7#include <linux/cpu.h>
11#include <linux/delay.h> 8#include <linux/delay.h>
diff --git a/arch/arm/mach-shmobile/platsmp.c b/arch/arm/mach-shmobile/platsmp.c
index b23378f3d7e1..7437c01513f6 100644
--- a/arch/arm/mach-shmobile/platsmp.c
+++ b/arch/arm/mach-shmobile/platsmp.c
@@ -1,3 +1,4 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * SMP support for R-Mobile / SH-Mobile 3 * SMP support for R-Mobile / SH-Mobile
3 * 4 *
@@ -5,10 +6,6 @@
5 * Copyright (C) 2011 Paul Mundt 6 * Copyright (C) 2011 Paul Mundt
6 * 7 *
7 * Based on vexpress, Copyright (C) 2002 ARM Ltd, All Rights Reserved 8 * Based on vexpress, Copyright (C) 2002 ARM Ltd, All Rights Reserved
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
12 */ 9 */
13#include <linux/init.h> 10#include <linux/init.h>
14#include <asm/cacheflush.h> 11#include <asm/cacheflush.h>
diff --git a/arch/arm/mach-shmobile/pm-rcar-gen2.c b/arch/arm/mach-shmobile/pm-rcar-gen2.c
index 7efe95bd584f..8c2a20591524 100644
--- a/arch/arm/mach-shmobile/pm-rcar-gen2.c
+++ b/arch/arm/mach-shmobile/pm-rcar-gen2.c
@@ -1,13 +1,10 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * R-Car Generation 2 Power management support 3 * R-Car Generation 2 Power management support
3 * 4 *
4 * Copyright (C) 2013 - 2015 Renesas Electronics Corporation 5 * Copyright (C) 2013 - 2015 Renesas Electronics Corporation
5 * Copyright (C) 2011 Renesas Solutions Corp. 6 * Copyright (C) 2011 Renesas Solutions Corp.
6 * Copyright (C) 2011 Magnus Damm 7 * Copyright (C) 2011 Magnus Damm
7 *
8 * This file is subject to the terms and conditions of the GNU General Public
9 * License. See the file "COPYING" in the main directory of this archive
10 * for more details.
11 */ 8 */
12 9
13#include <linux/kernel.h> 10#include <linux/kernel.h>
diff --git a/arch/arm/mach-shmobile/pm-rmobile.c b/arch/arm/mach-shmobile/pm-rmobile.c
index 94fdeef11b81..c6a11b5ec6db 100644
--- a/arch/arm/mach-shmobile/pm-rmobile.c
+++ b/arch/arm/mach-shmobile/pm-rmobile.c
@@ -1,3 +1,4 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * rmobile power management support 3 * rmobile power management support
3 * 4 *
@@ -7,10 +8,6 @@
7 * 8 *
8 * based on pm-sh7372.c 9 * based on pm-sh7372.c
9 * Copyright (C) 2011 Magnus Damm 10 * Copyright (C) 2011 Magnus Damm
10 *
11 * This file is subject to the terms and conditions of the GNU General Public
12 * License. See the file "COPYING" in the main directory of this archive
13 * for more details.
14 */ 11 */
15#include <linux/clk/renesas.h> 12#include <linux/clk/renesas.h>
16#include <linux/console.h> 13#include <linux/console.h>
@@ -189,7 +186,7 @@ static void __init add_special_pd(struct device_node *np, enum pd_types type)
189 return; 186 return;
190 } 187 }
191 188
192 pr_debug("Special PM domain %s type %d for %pOF\n", pd->name, type, np); 189 pr_debug("Special PM domain %pOFn type %d for %pOF\n", pd, type, np);
193 190
194 special_pds[num_special_pds].pd = pd; 191 special_pds[num_special_pds].pd = pd;
195 special_pds[num_special_pds].type = type; 192 special_pds[num_special_pds].type = type;
diff --git a/arch/arm/mach-shmobile/pm-rmobile.h b/arch/arm/mach-shmobile/pm-rmobile.h
index 8146bb6d7237..69f839259b09 100644
--- a/arch/arm/mach-shmobile/pm-rmobile.h
+++ b/arch/arm/mach-shmobile/pm-rmobile.h
@@ -1,11 +1,8 @@
1/* 1/* SPDX-License-Identifier: GPL-2.0
2 *
2 * Copyright (C) 2012 Renesas Solutions Corp. 3 * Copyright (C) 2012 Renesas Solutions Corp.
3 * 4 *
4 * Kuninori Morimoto <morimoto.kuninori@renesas.com> 5 * Kuninori Morimoto <morimoto.kuninori@renesas.com>
5 *
6 * This file is subject to the terms and conditions of the GNU General Public
7 * License. See the file "COPYING" in the main directory of this archive
8 * for more details.
9 */ 6 */
10#ifndef PM_RMOBILE_H 7#ifndef PM_RMOBILE_H
11#define PM_RMOBILE_H 8#define PM_RMOBILE_H
diff --git a/arch/arm/mach-shmobile/regulator-quirk-rcar-gen2.c b/arch/arm/mach-shmobile/regulator-quirk-rcar-gen2.c
index 21ebc7678ffd..8e50daa99151 100644
--- a/arch/arm/mach-shmobile/regulator-quirk-rcar-gen2.c
+++ b/arch/arm/mach-shmobile/regulator-quirk-rcar-gen2.c
@@ -23,11 +23,12 @@
23#include <linux/i2c.h> 23#include <linux/i2c.h>
24#include <linux/init.h> 24#include <linux/init.h>
25#include <linux/io.h> 25#include <linux/io.h>
26#include <linux/list.h>
26#include <linux/notifier.h> 27#include <linux/notifier.h>
27#include <linux/of.h> 28#include <linux/of.h>
29#include <linux/of_irq.h>
28#include <linux/mfd/da9063/registers.h> 30#include <linux/mfd/da9063/registers.h>
29 31
30
31#define IRQC_BASE 0xe61c0000 32#define IRQC_BASE 0xe61c0000
32#define IRQC_MONITOR 0x104 /* IRQn Signal Level Monitor Register */ 33#define IRQC_MONITOR 0x104 /* IRQn Signal Level Monitor Register */
33 34
@@ -36,34 +37,45 @@
36/* start of DA9210 System Control and Event Registers */ 37/* start of DA9210 System Control and Event Registers */
37#define DA9210_REG_MASK_A 0x54 38#define DA9210_REG_MASK_A 0x54
38 39
40struct regulator_quirk {
41 struct list_head list;
42 const struct of_device_id *id;
43 struct of_phandle_args irq_args;
44 struct i2c_msg i2c_msg;
45 bool shared; /* IRQ line is shared */
46};
47
48static LIST_HEAD(quirk_list);
39static void __iomem *irqc; 49static void __iomem *irqc;
40 50
41/* first byte sets the memory pointer, following are consecutive reg values */ 51/* first byte sets the memory pointer, following are consecutive reg values */
42static u8 da9063_irq_clr[] = { DA9063_REG_IRQ_MASK_A, 0xff, 0xff, 0xff, 0xff }; 52static u8 da9063_irq_clr[] = { DA9063_REG_IRQ_MASK_A, 0xff, 0xff, 0xff, 0xff };
43static u8 da9210_irq_clr[] = { DA9210_REG_MASK_A, 0xff, 0xff }; 53static u8 da9210_irq_clr[] = { DA9210_REG_MASK_A, 0xff, 0xff };
44 54
45static struct i2c_msg da9xxx_msgs[3] = { 55static struct i2c_msg da9063_msg = {
46 { 56 .len = ARRAY_SIZE(da9063_irq_clr),
47 .addr = 0x58, 57 .buf = da9063_irq_clr,
48 .len = ARRAY_SIZE(da9063_irq_clr), 58};
49 .buf = da9063_irq_clr, 59
50 }, { 60static struct i2c_msg da9210_msg = {
51 .addr = 0x68, 61 .len = ARRAY_SIZE(da9210_irq_clr),
52 .len = ARRAY_SIZE(da9210_irq_clr), 62 .buf = da9210_irq_clr,
53 .buf = da9210_irq_clr, 63};
54 }, { 64
55 .addr = 0x70, 65static const struct of_device_id rcar_gen2_quirk_match[] = {
56 .len = ARRAY_SIZE(da9210_irq_clr), 66 { .compatible = "dlg,da9063", .data = &da9063_msg },
57 .buf = da9210_irq_clr, 67 { .compatible = "dlg,da9210", .data = &da9210_msg },
58 }, 68 {},
59}; 69};
60 70
61static int regulator_quirk_notify(struct notifier_block *nb, 71static int regulator_quirk_notify(struct notifier_block *nb,
62 unsigned long action, void *data) 72 unsigned long action, void *data)
63{ 73{
74 struct regulator_quirk *pos, *tmp;
64 struct device *dev = data; 75 struct device *dev = data;
65 struct i2c_client *client; 76 struct i2c_client *client;
66 static bool done; 77 static bool done;
78 int ret;
67 u32 mon; 79 u32 mon;
68 80
69 if (done) 81 if (done)
@@ -80,17 +92,20 @@ static int regulator_quirk_notify(struct notifier_block *nb,
80 client = to_i2c_client(dev); 92 client = to_i2c_client(dev);
81 dev_dbg(dev, "Detected %s\n", client->name); 93 dev_dbg(dev, "Detected %s\n", client->name);
82 94
83 if ((client->addr == 0x58 && !strcmp(client->name, "da9063")) || 95 /*
84 (client->addr == 0x68 && !strcmp(client->name, "da9210")) || 96 * Send message to all PMICs that share an IRQ line to deassert it.
85 (client->addr == 0x70 && !strcmp(client->name, "da9210"))) { 97 *
86 int ret, len; 98 * WARNING: This works only if all the PMICs are on the same I2C bus.
99 */
100 list_for_each_entry(pos, &quirk_list, list) {
101 if (!pos->shared)
102 continue;
87 103
88 /* There are two DA9210 on Stout, one on the other boards. */ 104 dev_info(&client->dev, "clearing %s@0x%02x interrupts\n",
89 len = of_machine_is_compatible("renesas,stout") ? 3 : 2; 105 pos->id->compatible, pos->i2c_msg.addr);
90 106
91 dev_info(&client->dev, "clearing da9063/da9210 interrupts\n"); 107 ret = i2c_transfer(client->adapter, &pos->i2c_msg, 1);
92 ret = i2c_transfer(client->adapter, da9xxx_msgs, len); 108 if (ret != 1)
93 if (ret != len)
94 dev_err(&client->dev, "i2c error %d\n", ret); 109 dev_err(&client->dev, "i2c error %d\n", ret);
95 } 110 }
96 111
@@ -103,6 +118,11 @@ static int regulator_quirk_notify(struct notifier_block *nb,
103remove: 118remove:
104 dev_info(dev, "IRQ2 is not asserted, removing quirk\n"); 119 dev_info(dev, "IRQ2 is not asserted, removing quirk\n");
105 120
121 list_for_each_entry_safe(pos, tmp, &quirk_list, list) {
122 list_del(&pos->list);
123 kfree(pos);
124 }
125
106 done = true; 126 done = true;
107 iounmap(irqc); 127 iounmap(irqc);
108 return 0; 128 return 0;
@@ -114,7 +134,12 @@ static struct notifier_block regulator_quirk_nb = {
114 134
115static int __init rcar_gen2_regulator_quirk(void) 135static int __init rcar_gen2_regulator_quirk(void)
116{ 136{
117 u32 mon; 137 struct regulator_quirk *quirk, *pos, *tmp;
138 struct of_phandle_args *argsa, *argsb;
139 const struct of_device_id *id;
140 struct device_node *np;
141 u32 mon, addr;
142 int ret;
118 143
119 if (!of_machine_is_compatible("renesas,koelsch") && 144 if (!of_machine_is_compatible("renesas,koelsch") &&
120 !of_machine_is_compatible("renesas,lager") && 145 !of_machine_is_compatible("renesas,lager") &&
@@ -122,22 +147,78 @@ static int __init rcar_gen2_regulator_quirk(void)
122 !of_machine_is_compatible("renesas,gose")) 147 !of_machine_is_compatible("renesas,gose"))
123 return -ENODEV; 148 return -ENODEV;
124 149
150 for_each_matching_node_and_match(np, rcar_gen2_quirk_match, &id) {
151 if (!of_device_is_available(np))
152 break;
153
154 ret = of_property_read_u32(np, "reg", &addr);
155 if (ret) /* Skip invalid entry and continue */
156 continue;
157
158 quirk = kzalloc(sizeof(*quirk), GFP_KERNEL);
159 if (!quirk) {
160 ret = -ENOMEM;
161 goto err_mem;
162 }
163
164 argsa = &quirk->irq_args;
165 memcpy(&quirk->i2c_msg, id->data, sizeof(quirk->i2c_msg));
166
167 quirk->id = id;
168 quirk->i2c_msg.addr = addr;
169
170 ret = of_irq_parse_one(np, 0, argsa);
171 if (ret) { /* Skip invalid entry and continue */
172 kfree(quirk);
173 continue;
174 }
175
176 list_for_each_entry(pos, &quirk_list, list) {
177 argsb = &pos->irq_args;
178
179 if (argsa->args_count != argsb->args_count)
180 continue;
181
182 ret = memcmp(argsa->args, argsb->args,
183 argsa->args_count *
184 sizeof(argsa->args[0]));
185 if (!ret) {
186 pos->shared = true;
187 quirk->shared = true;
188 }
189 }
190
191 list_add_tail(&quirk->list, &quirk_list);
192 }
193
125 irqc = ioremap(IRQC_BASE, PAGE_SIZE); 194 irqc = ioremap(IRQC_BASE, PAGE_SIZE);
126 if (!irqc) 195 if (!irqc) {
127 return -ENOMEM; 196 ret = -ENOMEM;
197 goto err_mem;
198 }
128 199
129 mon = ioread32(irqc + IRQC_MONITOR); 200 mon = ioread32(irqc + IRQC_MONITOR);
130 if (mon & REGULATOR_IRQ_MASK) { 201 if (mon & REGULATOR_IRQ_MASK) {
131 pr_debug("%s: IRQ2 is not asserted, not installing quirk\n", 202 pr_debug("%s: IRQ2 is not asserted, not installing quirk\n",
132 __func__); 203 __func__);
133 iounmap(irqc); 204 ret = 0;
134 return 0; 205 goto err_free;
135 } 206 }
136 207
137 pr_info("IRQ2 is asserted, installing da9063/da9210 regulator quirk\n"); 208 pr_info("IRQ2 is asserted, installing da9063/da9210 regulator quirk\n");
138 209
139 bus_register_notifier(&i2c_bus_type, &regulator_quirk_nb); 210 bus_register_notifier(&i2c_bus_type, &regulator_quirk_nb);
140 return 0; 211 return 0;
212
213err_free:
214 iounmap(irqc);
215err_mem:
216 list_for_each_entry_safe(pos, tmp, &quirk_list, list) {
217 list_del(&pos->list);
218 kfree(pos);
219 }
220
221 return ret;
141} 222}
142 223
143arch_initcall(rcar_gen2_regulator_quirk); 224arch_initcall(rcar_gen2_regulator_quirk);
diff --git a/arch/arm/mach-shmobile/setup-r8a7779.c b/arch/arm/mach-shmobile/setup-r8a7779.c
index d589326099e0..b13ec9088ce5 100644
--- a/arch/arm/mach-shmobile/setup-r8a7779.c
+++ b/arch/arm/mach-shmobile/setup-r8a7779.c
@@ -7,9 +7,7 @@
7 * Copyright (C) 2013 Cogent Embedded, Inc. 7 * Copyright (C) 2013 Cogent Embedded, Inc.
8 */ 8 */
9#include <linux/init.h> 9#include <linux/init.h>
10#include <linux/irq.h>
11#include <linux/irqchip.h> 10#include <linux/irqchip.h>
12#include <linux/irqchip/arm-gic.h>
13 11
14#include <asm/mach/arch.h> 12#include <asm/mach/arch.h>
15#include <asm/mach/map.h> 13#include <asm/mach/map.h>
diff --git a/arch/arm/mach-shmobile/setup-rcar-gen2.c b/arch/arm/mach-shmobile/setup-rcar-gen2.c
index 013acc97795c..eea60b20c6b4 100644
--- a/arch/arm/mach-shmobile/setup-rcar-gen2.c
+++ b/arch/arm/mach-shmobile/setup-rcar-gen2.c
@@ -25,6 +25,7 @@
25static const struct of_device_id cpg_matches[] __initconst = { 25static const struct of_device_id cpg_matches[] __initconst = {
26 { .compatible = "renesas,rcar-gen2-cpg-clocks", }, 26 { .compatible = "renesas,rcar-gen2-cpg-clocks", },
27 { .compatible = "renesas,r8a7743-cpg-mssr", .data = "extal" }, 27 { .compatible = "renesas,r8a7743-cpg-mssr", .data = "extal" },
28 { .compatible = "renesas,r8a7744-cpg-mssr", .data = "extal" },
28 { .compatible = "renesas,r8a7790-cpg-mssr", .data = "extal" }, 29 { .compatible = "renesas,r8a7790-cpg-mssr", .data = "extal" },
29 { .compatible = "renesas,r8a7791-cpg-mssr", .data = "extal" }, 30 { .compatible = "renesas,r8a7791-cpg-mssr", .data = "extal" },
30 { .compatible = "renesas,r8a7793-cpg-mssr", .data = "extal" }, 31 { .compatible = "renesas,r8a7793-cpg-mssr", .data = "extal" },
@@ -193,6 +194,7 @@ MACHINE_END
193 194
194static const char * const rz_g1_boards_compat_dt[] __initconst = { 195static const char * const rz_g1_boards_compat_dt[] __initconst = {
195 "renesas,r8a7743", 196 "renesas,r8a7743",
197 "renesas,r8a7744",
196 "renesas,r8a7745", 198 "renesas,r8a7745",
197 "renesas,r8a77470", 199 "renesas,r8a77470",
198 NULL, 200 NULL,
diff --git a/arch/arm/mach-shmobile/smp-sh73a0.c b/arch/arm/mach-shmobile/smp-sh73a0.c
index 41137404382e..9bc543faba96 100644
--- a/arch/arm/mach-shmobile/smp-sh73a0.c
+++ b/arch/arm/mach-shmobile/smp-sh73a0.c
@@ -1,17 +1,9 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * SMP support for R-Mobile / SH-Mobile - sh73a0 portion 3 * SMP support for R-Mobile / SH-Mobile - sh73a0 portion
3 * 4 *
4 * Copyright (C) 2010 Magnus Damm 5 * Copyright (C) 2010 Magnus Damm
5 * Copyright (C) 2010 Takashi Yoshii 6 * Copyright (C) 2010 Takashi Yoshii
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; version 2 of the License.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 */ 7 */
16#include <linux/kernel.h> 8#include <linux/kernel.h>
17#include <linux/init.h> 9#include <linux/init.h>
diff --git a/arch/arm/mach-shmobile/suspend.c b/arch/arm/mach-shmobile/suspend.c
index 74b30bade2c1..3969a499746e 100644
--- a/arch/arm/mach-shmobile/suspend.c
+++ b/arch/arm/mach-shmobile/suspend.c
@@ -1,11 +1,8 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * Suspend-to-RAM support code for SH-Mobile ARM 3 * Suspend-to-RAM support code for SH-Mobile ARM
3 * 4 *
4 * Copyright (C) 2011 Magnus Damm 5 * Copyright (C) 2011 Magnus Damm
5 *
6 * This file is subject to the terms and conditions of the GNU General Public
7 * License. See the file "COPYING" in the main directory of this archive
8 * for more details.
9 */ 6 */
10 7
11#include <linux/pm.h> 8#include <linux/pm.h>
diff --git a/arch/arm/mach-shmobile/timer.c b/arch/arm/mach-shmobile/timer.c
index e48b0939693f..2335311b5f36 100644
--- a/arch/arm/mach-shmobile/timer.c
+++ b/arch/arm/mach-shmobile/timer.c
@@ -1,17 +1,9 @@
1// SPDX-License-Identifier: GPL-2.0
1/* 2/*
2 * SH-Mobile Timer 3 * SH-Mobile Timer
3 * 4 *
4 * Copyright (C) 2010 Magnus Damm 5 * Copyright (C) 2010 Magnus Damm
5 * Copyright (C) 2002 - 2009 Paul Mundt 6 * Copyright (C) 2002 - 2009 Paul Mundt
6 *
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; version 2 of the License.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 */ 7 */
16#include <linux/platform_device.h> 8#include <linux/platform_device.h>
17#include <linux/clocksource.h> 9#include <linux/clocksource.h>
diff --git a/arch/arm/mach-u300/Kconfig b/arch/arm/mach-u300/Kconfig
index 4f43c1cd5db0..c3c8bf54f033 100644
--- a/arch/arm/mach-u300/Kconfig
+++ b/arch/arm/mach-u300/Kconfig
@@ -29,17 +29,4 @@ config U300_DEBUG
29 help 29 help
30 Debug support for U300 in sysfs, procfs etc. 30 Debug support for U300 in sysfs, procfs etc.
31 31
32config MACH_U300_SPIDUMMY
33 depends on ARCH_U300
34 bool "SSP/SPI dummy chip"
35 select SPI
36 select SPI_MASTER
37 select SPI_PL022
38 help
39 This creates a small kernel module that creates a dummy
40 SPI device to be used for loopback tests. Regularly used
41 to test reference designs. If you're not testing SPI,
42 you don't need it. Selecting this will activate the
43 SPI framework and ARM PL022 support.
44
45endif 32endif
diff --git a/arch/arm/mach-u300/Makefile b/arch/arm/mach-u300/Makefile
index 87d37de054b6..5a8804fa8776 100644
--- a/arch/arm/mach-u300/Makefile
+++ b/arch/arm/mach-u300/Makefile
@@ -4,5 +4,4 @@
4 4
5obj-y := core.o 5obj-y := core.o
6 6
7obj-$(CONFIG_MACH_U300_SPIDUMMY) += dummyspichip.o
8obj-$(CONFIG_REGULATOR_AB3100) += regulator.o 7obj-$(CONFIG_REGULATOR_AB3100) += regulator.o
diff --git a/arch/arm/mach-u300/dummyspichip.c b/arch/arm/mach-u300/dummyspichip.c
deleted file mode 100644
index 68fe986ca42e..000000000000
--- a/arch/arm/mach-u300/dummyspichip.c
+++ /dev/null
@@ -1,276 +0,0 @@
1/*
2 * arch/arm/mach-u300/dummyspichip.c
3 *
4 * Copyright (C) 2007-2009 ST-Ericsson AB
5 * License terms: GNU General Public License (GPL) version 2
6 * This is a dummy loopback SPI "chip" used for testing SPI.
7 * Author: Linus Walleij <linus.walleij@stericsson.com>
8 */
9#include <linux/init.h>
10#include <linux/module.h>
11#include <linux/kernel.h>
12#include <linux/device.h>
13#include <linux/err.h>
14#include <linux/sysfs.h>
15#include <linux/mutex.h>
16#include <linux/spi/spi.h>
17#include <linux/dma-mapping.h>
18#include <linux/slab.h>
19/*
20 * WARNING! Do not include this pl022-specific controller header
21 * for any generic driver. It is only done in this dummy chip
22 * because we alter the chip configuration in order to test some
23 * different settings on the loopback device. Normal chip configs
24 * shall be STATIC and not altered by the driver!
25 */
26#include <linux/amba/pl022.h>
27
28struct dummy {
29 struct device *dev;
30 struct mutex lock;
31};
32
33#define DMA_TEST_SIZE 2048
34
35/* When we cat /sys/bus/spi/devices/spi0.0/looptest this will be triggered */
36static ssize_t dummy_looptest(struct device *dev,
37 struct device_attribute *attr, char *buf)
38{
39 struct spi_device *spi = to_spi_device(dev);
40 struct dummy *p_dummy = dev_get_drvdata(&spi->dev);
41
42 /*
43 * WARNING! Do not dereference the chip-specific data in any normal
44 * driver for a chip. It is usually STATIC and shall not be read
45 * or written to. Your chip driver should NOT depend on fields in this
46 * struct, this is just used here to alter the behaviour of the chip
47 * in order to perform tests.
48 */
49 int status;
50 u8 txbuf[14] = {0xDE, 0xAD, 0xBE, 0xEF, 0x2B, 0xAD,
51 0xCA, 0xFE, 0xBA, 0xBE, 0xB1, 0x05,
52 0xF0, 0x0D};
53 u8 rxbuf[14];
54 u8 *bigtxbuf_virtual;
55 u8 *bigrxbuf_virtual;
56
57 if (mutex_lock_interruptible(&p_dummy->lock))
58 return -ERESTARTSYS;
59
60 bigtxbuf_virtual = kmalloc(DMA_TEST_SIZE, GFP_KERNEL);
61 if (bigtxbuf_virtual == NULL) {
62 status = -ENOMEM;
63 goto out;
64 }
65 bigrxbuf_virtual = kmalloc(DMA_TEST_SIZE, GFP_KERNEL);
66
67 /* Fill TXBUF with some happy pattern */
68 memset(bigtxbuf_virtual, 0xAA, DMA_TEST_SIZE);
69
70 /*
71 * Force chip to 8 bit mode
72 * WARNING: NEVER DO THIS IN REAL DRIVER CODE, THIS SHOULD BE STATIC!
73 */
74 spi->bits_per_word = 8;
75 /* You should NOT DO THIS EITHER */
76 spi->master->setup(spi);
77
78 /* Now run the tests for 8bit mode */
79 pr_info("Simple test 1: write 0xAA byte, read back garbage byte "
80 "in 8bit mode\n");
81 status = spi_w8r8(spi, 0xAA);
82 if (status < 0)
83 pr_warn("Simple test 1: FAILURE: spi_write_then_read failed with status %d\n",
84 status);
85 else
86 pr_info("Simple test 1: SUCCESS!\n");
87
88 pr_info("Simple test 2: write 8 bytes, read back 8 bytes garbage "
89 "in 8bit mode (full FIFO)\n");
90 status = spi_write_then_read(spi, &txbuf[0], 8, &rxbuf[0], 8);
91 if (status < 0)
92 pr_warn("Simple test 2: FAILURE: spi_write_then_read() failed with status %d\n",
93 status);
94 else
95 pr_info("Simple test 2: SUCCESS!\n");
96
97 pr_info("Simple test 3: write 14 bytes, read back 14 bytes garbage "
98 "in 8bit mode (see if we overflow FIFO)\n");
99 status = spi_write_then_read(spi, &txbuf[0], 14, &rxbuf[0], 14);
100 if (status < 0)
101 pr_warn("Simple test 3: FAILURE: failed with status %d (probably FIFO overrun)\n",
102 status);
103 else
104 pr_info("Simple test 3: SUCCESS!\n");
105
106 pr_info("Simple test 4: write 8 bytes with spi_write(), read 8 "
107 "bytes garbage with spi_read() in 8bit mode\n");
108 status = spi_write(spi, &txbuf[0], 8);
109 if (status < 0)
110 pr_warn("Simple test 4 step 1: FAILURE: spi_write() failed with status %d\n",
111 status);
112 else
113 pr_info("Simple test 4 step 1: SUCCESS!\n");
114 status = spi_read(spi, &rxbuf[0], 8);
115 if (status < 0)
116 pr_warn("Simple test 4 step 2: FAILURE: spi_read() failed with status %d\n",
117 status);
118 else
119 pr_info("Simple test 4 step 2: SUCCESS!\n");
120
121 pr_info("Simple test 5: write 14 bytes with spi_write(), read "
122 "14 bytes garbage with spi_read() in 8bit mode\n");
123 status = spi_write(spi, &txbuf[0], 14);
124 if (status < 0)
125 pr_warn("Simple test 5 step 1: FAILURE: spi_write() failed with status %d (probably FIFO overrun)\n",
126 status);
127 else
128 pr_info("Simple test 5 step 1: SUCCESS!\n");
129 status = spi_read(spi, &rxbuf[0], 14);
130 if (status < 0)
131 pr_warn("Simple test 5 step 2: FAILURE: spi_read() failed with status %d (probably FIFO overrun)\n",
132 status);
133 else
134 pr_info("Simple test 5: SUCCESS!\n");
135
136 pr_info("Simple test 6: write %d bytes with spi_write(), "
137 "read %d bytes garbage with spi_read() in 8bit mode\n",
138 DMA_TEST_SIZE, DMA_TEST_SIZE);
139 status = spi_write(spi, &bigtxbuf_virtual[0], DMA_TEST_SIZE);
140 if (status < 0)
141 pr_warn("Simple test 6 step 1: FAILURE: spi_write() failed with status %d (probably FIFO overrun)\n",
142 status);
143 else
144 pr_info("Simple test 6 step 1: SUCCESS!\n");
145 status = spi_read(spi, &bigrxbuf_virtual[0], DMA_TEST_SIZE);
146 if (status < 0)
147 pr_warn("Simple test 6 step 2: FAILURE: spi_read() failed with status %d (probably FIFO overrun)\n",
148 status);
149 else
150 pr_info("Simple test 6: SUCCESS!\n");
151
152
153 /*
154 * Force chip to 16 bit mode
155 * WARNING: NEVER DO THIS IN REAL DRIVER CODE, THIS SHOULD BE STATIC!
156 */
157 spi->bits_per_word = 16;
158 /* You should NOT DO THIS EITHER */
159 spi->master->setup(spi);
160
161 pr_info("Simple test 7: write 0xAA byte, read back garbage byte "
162 "in 16bit bus mode\n");
163 status = spi_w8r8(spi, 0xAA);
164 if (status == -EIO)
165 pr_info("Simple test 7: SUCCESS! (expected failure with "
166 "status EIO)\n");
167 else if (status < 0)
168 pr_warn("Simple test 7: FAILURE: spi_write_then_read failed with status %d\n",
169 status);
170 else
171 pr_warn("Simple test 7: FAILURE: spi_write_then_read succeeded but it was expected to fail!\n");
172
173 pr_info("Simple test 8: write 8 bytes, read back 8 bytes garbage "
174 "in 16bit mode (full FIFO)\n");
175 status = spi_write_then_read(spi, &txbuf[0], 8, &rxbuf[0], 8);
176 if (status < 0)
177 pr_warn("Simple test 8: FAILURE: spi_write_then_read() failed with status %d\n",
178 status);
179 else
180 pr_info("Simple test 8: SUCCESS!\n");
181
182 pr_info("Simple test 9: write 14 bytes, read back 14 bytes garbage "
183 "in 16bit mode (see if we overflow FIFO)\n");
184 status = spi_write_then_read(spi, &txbuf[0], 14, &rxbuf[0], 14);
185 if (status < 0)
186 pr_warn("Simple test 9: FAILURE: failed with status %d (probably FIFO overrun)\n",
187 status);
188 else
189 pr_info("Simple test 9: SUCCESS!\n");
190
191 pr_info("Simple test 10: write %d bytes with spi_write(), "
192 "read %d bytes garbage with spi_read() in 16bit mode\n",
193 DMA_TEST_SIZE, DMA_TEST_SIZE);
194 status = spi_write(spi, &bigtxbuf_virtual[0], DMA_TEST_SIZE);
195 if (status < 0)
196 pr_warn("Simple test 10 step 1: FAILURE: spi_write() failed with status %d (probably FIFO overrun)\n",
197 status);
198 else
199 pr_info("Simple test 10 step 1: SUCCESS!\n");
200
201 status = spi_read(spi, &bigrxbuf_virtual[0], DMA_TEST_SIZE);
202 if (status < 0)
203 pr_warn("Simple test 10 step 2: FAILURE: spi_read() failed with status %d (probably FIFO overrun)\n",
204 status);
205 else
206 pr_info("Simple test 10: SUCCESS!\n");
207
208 status = sprintf(buf, "loop test complete\n");
209 kfree(bigrxbuf_virtual);
210 kfree(bigtxbuf_virtual);
211 out:
212 mutex_unlock(&p_dummy->lock);
213 return status;
214}
215
216static DEVICE_ATTR(looptest, S_IRUGO, dummy_looptest, NULL);
217
218static int pl022_dummy_probe(struct spi_device *spi)
219{
220 struct dummy *p_dummy;
221 int status;
222
223 dev_info(&spi->dev, "probing dummy SPI device\n");
224
225 p_dummy = kzalloc(sizeof *p_dummy, GFP_KERNEL);
226 if (!p_dummy)
227 return -ENOMEM;
228
229 dev_set_drvdata(&spi->dev, p_dummy);
230 mutex_init(&p_dummy->lock);
231
232 /* sysfs hook */
233 status = device_create_file(&spi->dev, &dev_attr_looptest);
234 if (status) {
235 dev_dbg(&spi->dev, "device_create_file looptest failure.\n");
236 goto out_dev_create_looptest_failed;
237 }
238
239 return 0;
240
241out_dev_create_looptest_failed:
242 dev_set_drvdata(&spi->dev, NULL);
243 kfree(p_dummy);
244 return status;
245}
246
247static int pl022_dummy_remove(struct spi_device *spi)
248{
249 struct dummy *p_dummy = dev_get_drvdata(&spi->dev);
250
251 dev_info(&spi->dev, "removing dummy SPI device\n");
252 device_remove_file(&spi->dev, &dev_attr_looptest);
253 dev_set_drvdata(&spi->dev, NULL);
254 kfree(p_dummy);
255
256 return 0;
257}
258
259static const struct of_device_id pl022_dummy_dt_match[] = {
260 { .compatible = "arm,pl022-dummy" },
261 {},
262};
263
264static struct spi_driver pl022_dummy_driver = {
265 .driver = {
266 .name = "spi-dummy",
267 .of_match_table = pl022_dummy_dt_match,
268 },
269 .probe = pl022_dummy_probe,
270 .remove = pl022_dummy_remove,
271};
272
273module_spi_driver(pl022_dummy_driver);
274MODULE_AUTHOR("Linus Walleij <linus.walleij@stericsson.com>");
275MODULE_DESCRIPTION("PL022 SSP/SPI DUMMY Linux driver");
276MODULE_LICENSE("GPL");
diff --git a/arch/arm/mach-zynq/slcr.c b/arch/arm/mach-zynq/slcr.c
index f0292a30e6f6..10ef99ce1d90 100644
--- a/arch/arm/mach-zynq/slcr.c
+++ b/arch/arm/mach-zynq/slcr.c
@@ -233,7 +233,7 @@ int __init zynq_early_slcr_init(void)
233 233
234 register_restart_handler(&zynq_slcr_restart_nb); 234 register_restart_handler(&zynq_slcr_restart_nb);
235 235
236 pr_info("%s mapped to %p\n", np->name, zynq_slcr_base); 236 pr_info("%pOFn mapped to %p\n", np, zynq_slcr_base);
237 237
238 of_node_put(np); 238 of_node_put(np);
239 239
diff --git a/arch/arm/plat-samsung/Kconfig b/arch/arm/plat-samsung/Kconfig
index b600e38364eb..377ff9cda667 100644
--- a/arch/arm/plat-samsung/Kconfig
+++ b/arch/arm/plat-samsung/Kconfig
@@ -256,7 +256,7 @@ config S3C_PM_DEBUG_LED_SMDK
256 256
257config SAMSUNG_PM_CHECK 257config SAMSUNG_PM_CHECK
258 bool "S3C2410 PM Suspend Memory CRC" 258 bool "S3C2410 PM Suspend Memory CRC"
259 depends on PM 259 depends on PM && (PLAT_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210)
260 select CRC32 260 select CRC32
261 help 261 help
262 Enable the PM code's memory area checksum over sleep. This option 262 Enable the PM code's memory area checksum over sleep. This option
diff --git a/arch/arm64/Kconfig.platforms b/arch/arm64/Kconfig.platforms
index 138d8eb58374..51bc479334a4 100644
--- a/arch/arm64/Kconfig.platforms
+++ b/arch/arm64/Kconfig.platforms
@@ -3,6 +3,7 @@ menu "Platform selection"
3config ARCH_ACTIONS 3config ARCH_ACTIONS
4 bool "Actions Semi Platforms" 4 bool "Actions Semi Platforms"
5 select OWL_TIMER 5 select OWL_TIMER
6 select PINCTRL
6 help 7 help
7 This enables support for the Actions Semiconductor S900 SoC family. 8 This enables support for the Actions Semiconductor S900 SoC family.
8 9
@@ -67,6 +68,7 @@ config ARCH_EXYNOS
67 select HAVE_S3C_RTC if RTC_CLASS 68 select HAVE_S3C_RTC if RTC_CLASS
68 select PINCTRL 69 select PINCTRL
69 select PINCTRL_EXYNOS 70 select PINCTRL_EXYNOS
71 select PM_GENERIC_DOMAINS if PM
70 select SOC_SAMSUNG 72 select SOC_SAMSUNG
71 help 73 help
72 This enables support for ARMv8 based Samsung Exynos SoC family. 74 This enables support for ARMv8 based Samsung Exynos SoC family.
@@ -153,40 +155,30 @@ config ARCH_REALTEK
153 This enables support for the ARMv8 based Realtek chipsets, 155 This enables support for the ARMv8 based Realtek chipsets,
154 like the RTD1295. 156 like the RTD1295.
155 157
156config ARCH_ROCKCHIP
157 bool "Rockchip Platforms"
158 select ARCH_HAS_RESET_CONTROLLER
159 select GPIOLIB
160 select PINCTRL
161 select PINCTRL_ROCKCHIP
162 select PM
163 select ROCKCHIP_TIMER
164 help
165 This enables support for the ARMv8 based Rockchip chipsets,
166 like the RK3368.
167
168config ARCH_SEATTLE
169 bool "AMD Seattle SoC Family"
170 help
171 This enables support for AMD Seattle SOC Family
172
173config ARCH_SHMOBILE
174 bool
175
176config ARCH_SYNQUACER
177 bool "Socionext SynQuacer SoC Family"
178
179config ARCH_RENESAS 158config ARCH_RENESAS
180 bool "Renesas SoC Platforms" 159 bool "Renesas SoC Platforms"
181 select ARCH_SHMOBILE
182 select PINCTRL 160 select PINCTRL
183 select PM 161 select PM
184 select PM_GENERIC_DOMAINS 162 select PM_GENERIC_DOMAINS
185 select RENESAS_IRQC 163 select RENESAS_IRQC
186 select SOC_BUS 164 select SOC_BUS
165 select SYS_SUPPORTS_SH_CMT
166 select SYS_SUPPORTS_SH_TMU
187 help 167 help
188 This enables support for the ARMv8 based Renesas SoCs. 168 This enables support for the ARMv8 based Renesas SoCs.
189 169
170config ARCH_R8A774A1
171 bool "Renesas RZ/G2M SoC Platform"
172 depends on ARCH_RENESAS
173 help
174 This enables support for the Renesas RZ/G2M SoC.
175
176config ARCH_R8A774C0
177 bool "Renesas RZ/G2E SoC Platform"
178 depends on ARCH_RENESAS
179 help
180 This enables support for the Renesas RZ/G2E SoC.
181
190config ARCH_R8A7795 182config ARCH_R8A7795
191 bool "Renesas R-Car H3 SoC Platform" 183 bool "Renesas R-Car H3 SoC Platform"
192 depends on ARCH_RENESAS 184 depends on ARCH_RENESAS
@@ -229,11 +221,31 @@ config ARCH_R8A77995
229 help 221 help
230 This enables support for the Renesas R-Car D3 SoC. 222 This enables support for the Renesas R-Car D3 SoC.
231 223
224config ARCH_ROCKCHIP
225 bool "Rockchip Platforms"
226 select ARCH_HAS_RESET_CONTROLLER
227 select GPIOLIB
228 select PINCTRL
229 select PINCTRL_ROCKCHIP
230 select PM
231 select ROCKCHIP_TIMER
232 help
233 This enables support for the ARMv8 based Rockchip chipsets,
234 like the RK3368.
235
236config ARCH_SEATTLE
237 bool "AMD Seattle SoC Family"
238 help
239 This enables support for AMD Seattle SOC Family
240
232config ARCH_STRATIX10 241config ARCH_STRATIX10
233 bool "Altera's Stratix 10 SoCFPGA Family" 242 bool "Altera's Stratix 10 SoCFPGA Family"
234 help 243 help
235 This enables support for Altera's Stratix 10 SoCFPGA Family. 244 This enables support for Altera's Stratix 10 SoCFPGA Family.
236 245
246config ARCH_SYNQUACER
247 bool "Socionext SynQuacer SoC Family"
248
237config ARCH_TEGRA 249config ARCH_TEGRA
238 bool "NVIDIA Tegra SoC Family" 250 bool "NVIDIA Tegra SoC Family"
239 select ARCH_HAS_RESET_CONTROLLER 251 select ARCH_HAS_RESET_CONTROLLER
diff --git a/include/linux/platform_data/gpio-omap.h b/include/linux/platform_data/gpio-omap.h
index 8485c6a9a383..6d07eebb3f75 100644
--- a/include/linux/platform_data/gpio-omap.h
+++ b/include/linux/platform_data/gpio-omap.h
@@ -24,8 +24,10 @@
24#ifndef __ASM_ARCH_OMAP_GPIO_H 24#ifndef __ASM_ARCH_OMAP_GPIO_H
25#define __ASM_ARCH_OMAP_GPIO_H 25#define __ASM_ARCH_OMAP_GPIO_H
26 26
27#ifndef __ASSEMBLER__
27#include <linux/io.h> 28#include <linux/io.h>
28#include <linux/platform_device.h> 29#include <linux/platform_device.h>
30#endif
29 31
30#define OMAP1_MPUIO_BASE 0xfffb5000 32#define OMAP1_MPUIO_BASE 0xfffb5000
31 33
@@ -157,6 +159,7 @@
157#define OMAP_MPUIO(nr) (OMAP_MAX_GPIO_LINES + (nr)) 159#define OMAP_MPUIO(nr) (OMAP_MAX_GPIO_LINES + (nr))
158#define OMAP_GPIO_IS_MPUIO(nr) ((nr) >= OMAP_MAX_GPIO_LINES) 160#define OMAP_GPIO_IS_MPUIO(nr) ((nr) >= OMAP_MAX_GPIO_LINES)
159 161
162#ifndef __ASSEMBLER__
160struct omap_gpio_reg_offs { 163struct omap_gpio_reg_offs {
161 u16 revision; 164 u16 revision;
162 u16 direction; 165 u16 direction;
@@ -205,4 +208,6 @@ struct omap_gpio_platform_data {
205 int (*get_context_loss_count)(struct device *dev); 208 int (*get_context_loss_count)(struct device *dev);
206}; 209};
207 210
211#endif /* __ASSEMBLER__ */
212
208#endif 213#endif