]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
Merge branch 'omap/dt' into next/late
authorArnd Bergmann <arnd@arndb.de>
Wed, 15 Apr 2015 19:35:22 +0000 (21:35 +0200)
committerArnd Bergmann <arnd@arndb.de>
Wed, 15 Apr 2015 19:41:13 +0000 (21:41 +0200)
As pointed out by Stephen Rothwell, commit e52117638b79 ("ARM: dts:
omap3: Add DT entries for OMAP 3 ISP") conflicts with b8845074cfbb
("ARM: dts: omap3: add minimal l4 bus layout with control module support")
in non-obvious ways, causing a build failure when both patches
are present.

This merges the two branches that introduce the respective changes
into the next/late branch to resolve the way that Stephen suggested,
as confirmed by Tony.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Link: https://lkml.org/lkml/2015/4/6/436
Acked-by: Tony Lindgren <tony@atomide.com>
171 files changed:
Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-cpucfg.txt [new file with mode: 0644]
Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-ir.txt [new file with mode: 0644]
Documentation/devicetree/bindings/arm/omap/ctrl.txt [new file with mode: 0644]
Documentation/devicetree/bindings/arm/omap/l4.txt [new file with mode: 0644]
Documentation/devicetree/bindings/arm/omap/prcm.txt
Documentation/devicetree/bindings/bus/omap-ocp2scp.txt
Documentation/devicetree/bindings/power/fsl,imx-gpc.txt [new file with mode: 0644]
MAINTAINERS
arch/arm/boot/dts/Makefile
arch/arm/boot/dts/am33xx-clocks.dtsi
arch/arm/boot/dts/am33xx.dtsi
arch/arm/boot/dts/am3517.dtsi
arch/arm/boot/dts/am35xx-clocks.dtsi
arch/arm/boot/dts/am4372.dtsi
arch/arm/boot/dts/am43x-epos-evm.dts
arch/arm/boot/dts/am43xx-clocks.dtsi
arch/arm/boot/dts/am57xx-beagle-x15.dts
arch/arm/boot/dts/dra7.dtsi
arch/arm/boot/dts/dra72x.dtsi
arch/arm/boot/dts/dra74x.dtsi
arch/arm/boot/dts/imx25-pdk.dts
arch/arm/boot/dts/imx25-pinfunc.h
arch/arm/boot/dts/imx27.dtsi
arch/arm/boot/dts/imx28-apf28.dts
arch/arm/boot/dts/imx28-apf28dev.dts
arch/arm/boot/dts/imx28.dtsi
arch/arm/boot/dts/imx35.dtsi
arch/arm/boot/dts/imx50.dtsi
arch/arm/boot/dts/imx51.dtsi
arch/arm/boot/dts/imx53.dtsi
arch/arm/boot/dts/imx6dl-aristainetos_4.dts
arch/arm/boot/dts/imx6dl-aristainetos_7.dts
arch/arm/boot/dts/imx6dl-cubox-i.dts
arch/arm/boot/dts/imx6dl-hummingboard.dts
arch/arm/boot/dts/imx6q-cubox-i.dts
arch/arm/boot/dts/imx6q-hummingboard.dts
arch/arm/boot/dts/imx6q.dtsi
arch/arm/boot/dts/imx6qdl-cubox-i.dtsi
arch/arm/boot/dts/imx6qdl-hummingboard.dtsi
arch/arm/boot/dts/imx6qdl-microsom-ar8035.dtsi
arch/arm/boot/dts/imx6qdl-microsom.dtsi
arch/arm/boot/dts/imx6qdl-sabreauto.dtsi
arch/arm/boot/dts/imx6qdl.dtsi
arch/arm/boot/dts/imx6sl-warp.dts [new file with mode: 0644]
arch/arm/boot/dts/imx6sl.dtsi
arch/arm/boot/dts/imx6sx-sdb-reva.dts [new file with mode: 0644]
arch/arm/boot/dts/imx6sx-sdb.dts
arch/arm/boot/dts/imx6sx-sdb.dtsi [new file with mode: 0644]
arch/arm/boot/dts/imx6sx.dtsi
arch/arm/boot/dts/omap2420.dtsi
arch/arm/boot/dts/omap2430-clocks.dtsi
arch/arm/boot/dts/omap2430.dtsi
arch/arm/boot/dts/omap24xx-clocks.dtsi
arch/arm/boot/dts/omap3.dtsi
arch/arm/boot/dts/omap34xx.dtsi
arch/arm/boot/dts/omap36xx.dtsi
arch/arm/boot/dts/omap3xxx-clocks.dtsi
arch/arm/boot/dts/omap4-cpu-thermal.dtsi
arch/arm/boot/dts/omap4.dtsi
arch/arm/boot/dts/omap5.dtsi
arch/arm/boot/dts/vf-colibri-eval-v3.dtsi
arch/arm/boot/dts/vf-colibri.dtsi
arch/arm/boot/dts/vf500.dtsi
arch/arm/boot/dts/vfxxx.dtsi
arch/arm/configs/imx_v4_v5_defconfig
arch/arm/configs/multi_v5_defconfig
arch/arm/mach-imx/Kconfig
arch/arm/mach-imx/Makefile
arch/arm/mach-imx/clk-imx25.c
arch/arm/mach-imx/clk-imx6q.c
arch/arm/mach-imx/common.h
arch/arm/mach-imx/cpu-imx25.c
arch/arm/mach-imx/devices-imx25.h [deleted file]
arch/arm/mach-imx/devices/Kconfig
arch/arm/mach-imx/devices/Makefile
arch/arm/mach-imx/devices/platform-fec.c
arch/arm/mach-imx/devices/platform-fsl-usb2-udc.c
arch/arm/mach-imx/devices/platform-imx-fb.c
arch/arm/mach-imx/devices/platform-imx-i2c.c
arch/arm/mach-imx/devices/platform-imx-keypad.c
arch/arm/mach-imx/devices/platform-imx-ssi.c
arch/arm/mach-imx/devices/platform-imx-uart.c
arch/arm/mach-imx/devices/platform-imx2-wdt.c
arch/arm/mach-imx/devices/platform-imxdi_rtc.c [deleted file]
arch/arm/mach-imx/devices/platform-mx2-camera.c
arch/arm/mach-imx/devices/platform-mxc-ehci.c
arch/arm/mach-imx/devices/platform-mxc_nand.c
arch/arm/mach-imx/devices/platform-spi_imx.c
arch/arm/mach-imx/ehci-imx25.c [deleted file]
arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c [deleted file]
arch/arm/mach-imx/eukrea_mbimxsd35-baseboard.c
arch/arm/mach-imx/gpc.c
arch/arm/mach-imx/hardware.h
arch/arm/mach-imx/iomux-mx25.h [deleted file]
arch/arm/mach-imx/iomux-mx3.h
arch/arm/mach-imx/iomux-v3.c
arch/arm/mach-imx/iomux-v3.h
arch/arm/mach-imx/mach-cpuimx35.c
arch/arm/mach-imx/mach-eukrea_cpuimx25.c [deleted file]
arch/arm/mach-imx/mach-imx25.c [moved from arch/arm/mach-imx/imx25-dt.c with 68% similarity]
arch/arm/mach-imx/mach-imx6q.c
arch/arm/mach-imx/mach-imx6sl.c
arch/arm/mach-imx/mach-imx6sx.c
arch/arm/mach-imx/mach-mx25_3ds.c [deleted file]
arch/arm/mach-imx/mach-mx35_3ds.c
arch/arm/mach-imx/mach-pcm043.c
arch/arm/mach-imx/mach-vpr200.c
arch/arm/mach-imx/mm-imx25.c [deleted file]
arch/arm/mach-imx/mx25.h [deleted file]
arch/arm/mach-imx/pm-imx6.c
arch/arm/mach-omap1/pm.c
arch/arm/mach-omap2/Kconfig
arch/arm/mach-omap2/clock.c
arch/arm/mach-omap2/clock.h
arch/arm/mach-omap2/cm.h
arch/arm/mach-omap2/cm2xxx.c
arch/arm/mach-omap2/cm2xxx.h
arch/arm/mach-omap2/cm33xx.c
arch/arm/mach-omap2/cm33xx.h
arch/arm/mach-omap2/cm3xxx.c
arch/arm/mach-omap2/cm3xxx.h
arch/arm/mach-omap2/cm44xx.h
arch/arm/mach-omap2/cm_common.c
arch/arm/mach-omap2/cminst44xx.c
arch/arm/mach-omap2/common.c
arch/arm/mach-omap2/common.h
arch/arm/mach-omap2/control.c
arch/arm/mach-omap2/control.h
arch/arm/mach-omap2/display.c
arch/arm/mach-omap2/id.c
arch/arm/mach-omap2/io.c
arch/arm/mach-omap2/mux.c
arch/arm/mach-omap2/omap-secure.h
arch/arm/mach-omap2/omap4-common.c
arch/arm/mach-omap2/pm24xx.c
arch/arm/mach-omap2/pm34xx.c
arch/arm/mach-omap2/prcm-common.h
arch/arm/mach-omap2/prm.h
arch/arm/mach-omap2/prm2xxx.c
arch/arm/mach-omap2/prm2xxx.h
arch/arm/mach-omap2/prm33xx.c
arch/arm/mach-omap2/prm33xx.h
arch/arm/mach-omap2/prm3xxx.c
arch/arm/mach-omap2/prm3xxx.h
arch/arm/mach-omap2/prm44xx.c
arch/arm/mach-omap2/prm44xx.h
arch/arm/mach-omap2/prm44xx_54xx.h
arch/arm/mach-omap2/prm54xx.h
arch/arm/mach-omap2/prm7xx.h
arch/arm/mach-omap2/prm_common.c
arch/arm/mach-omap2/prminst44xx.c
arch/arm/mach-omap2/prminst44xx.h
arch/arm/mach-omap2/sleep44xx.S
arch/arm/mach-omap2/vp.h
arch/arm/mach-omap2/vp3xxx_data.c
arch/arm/mach-omap2/vp44xx_data.c
drivers/bus/imx-weim.c
drivers/bus/omap-ocp2scp.c
drivers/clk/ti/apll.c
drivers/clk/ti/autoidle.c
drivers/clk/ti/clk.c
drivers/clk/ti/divider.c
drivers/clk/ti/dpll.c
drivers/clk/ti/gate.c
drivers/clk/ti/interface.c
drivers/clk/ti/mux.c
drivers/irqchip/Makefile
drivers/irqchip/irq-vf610-mscm-ir.c [new file with mode: 0644]
include/dt-bindings/clock/imx6qdl-clock.h
include/linux/clk/ti.h
include/linux/mfd/syscon/imx6q-iomuxc-gpr.h

diff --git a/Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-cpucfg.txt b/Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-cpucfg.txt
new file mode 100644 (file)
index 0000000..44aa3c4
--- /dev/null
@@ -0,0 +1,14 @@
+Freescale Vybrid Miscellaneous System Control - CPU Configuration
+
+The MSCM IP contains multiple sub modules, this binding describes the first
+block of registers which contains CPU configuration information.
+
+Required properties:
+- compatible:  "fsl,vf610-mscm-cpucfg", "syscon"
+- reg:         the register range of the MSCM CPU configuration registers
+
+Example:
+       mscm_cpucfg: cpucfg@40001000 {
+               compatible = "fsl,vf610-mscm-cpucfg", "syscon";
+               reg = <0x40001000 0x800>;
+       }
diff --git a/Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-ir.txt b/Documentation/devicetree/bindings/arm/freescale/fsl,vf610-mscm-ir.txt
new file mode 100644 (file)
index 0000000..669808b
--- /dev/null
@@ -0,0 +1,33 @@
+Freescale Vybrid Miscellaneous System Control - Interrupt Router
+
+The MSCM IP contains multiple sub modules, this binding describes the second
+block of registers which control the interrupt router. The interrupt router
+allows to configure the recipient of each peripheral interrupt. Furthermore
+it controls the directed processor interrupts. The module is available in all
+Vybrid SoC's but is only really useful in dual core configurations (VF6xx
+which comes with a Cortex-A5/Cortex-M4 combination).
+
+Required properties:
+- compatible:          "fsl,vf610-mscm-ir"
+- reg:                 the register range of the MSCM Interrupt Router
+- fsl,cpucfg:          The handle to the MSCM CPU configuration node, required
+                       to get the current CPU ID
+- interrupt-controller:        Identifies the node as an interrupt controller
+- #interrupt-cells:    Two cells, interrupt number and cells.
+                       The hardware interrupt number according to interrupt
+                       assignment of the interrupt router is required.
+                       Flags get passed only when using GIC as parent. Flags
+                       encoding as documented by the GIC bindings.
+- interrupt-parent:    Should be the phandle for the interrupt controller of
+                       the CPU the device tree is intended to be used on. This
+                       is either the node of the GIC or NVIC controller.
+
+Example:
+       mscm_ir: interrupt-controller@40001800 {
+               compatible = "fsl,vf610-mscm-ir";
+               reg = <0x40001800 0x400>;
+               fsl,cpucfg = <&mscm_cpucfg>;
+               interrupt-controller;
+               #interrupt-cells = <2>;
+               interrupt-parent = <&intc>;
+       }
diff --git a/Documentation/devicetree/bindings/arm/omap/ctrl.txt b/Documentation/devicetree/bindings/arm/omap/ctrl.txt
new file mode 100644 (file)
index 0000000..3a4e590
--- /dev/null
@@ -0,0 +1,79 @@
+OMAP Control Module bindings
+
+Control Module contains miscellaneous features under it based on SoC type.
+Pincontrol is one common feature, and it has a specialized support
+described in [1]. Typically some clock nodes are also under control module.
+Syscon is used to share register level access to drivers external to
+control module driver itself.
+
+See [2] for documentation about clock/clockdomain nodes.
+
+[1] Documentation/devicetree/bindings/pinctrl/pinctrl-single.txt
+[2] Documentation/devicetree/bindings/clock/ti/*
+
+Required properties:
+- compatible:  Must be one of:
+               "ti,am3-scm"
+               "ti,am4-scm"
+               "ti,dm814-scrm"
+               "ti,dm816-scrm"
+               "ti,omap2-scm"
+               "ti,omap3-scm"
+               "ti,omap4-scm-core"
+               "ti,omap4-scm-padconf-core"
+               "ti,omap5-scm-core"
+               "ti,omap5-scm-padconf-core"
+               "ti,dra7-scm-core"
+- reg:         Contains Control Module register address range
+               (base address and length)
+
+Optional properties:
+- clocks:      clocks for this module
+- clockdomains:        clockdomains for this module
+
+Examples:
+
+scm: scm@2000 {
+       compatible = "ti,omap3-scm", "simple-bus";
+       reg = <0x2000 0x2000>;
+       #address-cells = <1>;
+       #size-cells = <1>;
+       ranges = <0 0x2000 0x2000>;
+
+       omap3_pmx_core: pinmux@30 {
+               compatible = "ti,omap3-padconf",
+                            "pinctrl-single";
+               reg = <0x30 0x230>;
+               #address-cells = <1>;
+               #size-cells = <0>;
+               #interrupt-cells = <1>;
+               interrupt-controller;
+               pinctrl-single,register-width = <16>;
+               pinctrl-single,function-mask = <0xff1f>;
+       };
+
+       scm_conf: scm_conf@270 {
+               compatible = "syscon";
+               reg = <0x270 0x330>;
+               #address-cells = <1>;
+               #size-cells = <1>;
+
+               scm_clocks: clocks {
+                       #address-cells = <1>;
+                       #size-cells = <0>;
+               };
+       };
+
+       scm_clockdomains: clockdomains {
+       };
+}
+
+&scm_clocks {
+       mcbsp5_mux_fck: mcbsp5_mux_fck {
+               #clock-cells = <0>;
+               compatible = "ti,composite-mux-clock";
+               clocks = <&core_96m_fck>, <&mcbsp_clks>;
+               ti,bit-shift = <4>;
+               reg = <0x02d8>;
+       };
+};
diff --git a/Documentation/devicetree/bindings/arm/omap/l4.txt b/Documentation/devicetree/bindings/arm/omap/l4.txt
new file mode 100644 (file)
index 0000000..b4f8a16
--- /dev/null
@@ -0,0 +1,26 @@
+L4 interconnect bindings
+
+These bindings describe the OMAP SoCs L4 interconnect bus.
+
+Required properties:
+- compatible : Should be "ti,omap2-l4" for OMAP2 family l4 core bus
+              Should be "ti,omap2-l4-wkup" for OMAP2 family l4 wkup bus
+              Should be "ti,omap3-l4-core" for OMAP3 family l4 core bus
+              Should be "ti,omap4-l4-cfg" for OMAP4 family l4 cfg bus
+              Should be "ti,omap4-l4-wkup" for OMAP4 family l4 wkup bus
+              Should be "ti,omap5-l4-cfg" for OMAP5 family l4 cfg bus
+              Should be "ti,omap5-l4-wkup" for OMAP5 family l4 wkup bus
+              Should be "ti,dra7-l4-cfg" for DRA7 family l4 cfg bus
+              Should be "ti,dra7-l4-wkup" for DRA7 family l4 wkup bus
+              Should be "ti,am3-l4-wkup" for AM33xx family l4 wkup bus
+              Should be "ti,am4-l4-wkup" for AM43xx family l4 wkup bus
+- ranges : contains the IO map range for the bus
+
+Examples:
+
+l4: l4@48000000 {
+       compatible "ti,omap2-l4", "simple-bus";
+       #address-cells = <1>;
+       #size-cells = <1>;
+       ranges = <0 0x48000000 0x100000>;
+};
index 79074dac684abfd6eec2239ef2a128955cd1641f..3eb6d7afff14395229b36e349f13c52e87a96be8 100644 (file)
@@ -10,14 +10,10 @@ documentation about the individual clock/clockdomain nodes.
 Required properties:
 - compatible:  Must be one of:
                "ti,am3-prcm"
-               "ti,am3-scrm"
                "ti,am4-prcm"
-               "ti,am4-scrm"
                "ti,omap2-prcm"
-               "ti,omap2-scrm"
                "ti,omap3-prm"
                "ti,omap3-cm"
-               "ti,omap3-scrm"
                "ti,omap4-cm1"
                "ti,omap4-prm"
                "ti,omap4-cm2"
@@ -29,6 +25,8 @@ Required properties:
                "ti,dra7-prm"
                "ti,dra7-cm-core-aon"
                "ti,dra7-cm-core"
+               "ti,dm814-prcm"
+               "ti,dm816-prcm"
 - reg:         Contains PRCM module register address range
                (base address and length)
 - clocks:      clocks for this module
index 63dd8051521c32d3674db1044ab75d01535ee074..18729f6fe1e5fbc5dea3e36c98715b4c22e4315f 100644 (file)
@@ -1,7 +1,8 @@
 * OMAP OCP2SCP - ocp interface to scp interface
 
 properties:
-- compatible : Should be "ti,omap-ocp2scp"
+- compatible : Should be "ti,am437x-ocp2scp" for AM437x processor
+              Should be "ti,omap-ocp2scp" for all others
 - reg : Address and length of the register set for the device
 - #address-cells, #size-cells : Must be present if the device has sub-nodes
 - ranges : the child address space are mapped 1:1 onto the parent address space
diff --git a/Documentation/devicetree/bindings/power/fsl,imx-gpc.txt b/Documentation/devicetree/bindings/power/fsl,imx-gpc.txt
new file mode 100644 (file)
index 0000000..65cc034
--- /dev/null
@@ -0,0 +1,59 @@
+Freescale i.MX General Power Controller
+=======================================
+
+The i.MX6Q General Power Control (GPC) block contains DVFS load tracking
+counters and Power Gating Control (PGC) for the CPU and PU (GPU/VPU) power
+domains.
+
+Required properties:
+- compatible: Should be "fsl,imx6q-gpc" or "fsl,imx6sl-gpc"
+- reg: should be register base and length as documented in the
+  datasheet
+- interrupts: Should contain GPC interrupt request 1
+- pu-supply: Link to the LDO regulator powering the PU power domain
+- clocks: Clock phandles to devices in the PU power domain that need
+         to be enabled during domain power-up for reset propagation.
+- #power-domain-cells: Should be 1, see below:
+
+The gpc node is a power-controller as documented by the generic power domain
+bindings in Documentation/devicetree/bindings/power/power_domain.txt.
+
+Example:
+
+       gpc: gpc@020dc000 {
+               compatible = "fsl,imx6q-gpc";
+               reg = <0x020dc000 0x4000>;
+               interrupts = <0 89 IRQ_TYPE_LEVEL_HIGH>,
+                            <0 90 IRQ_TYPE_LEVEL_HIGH>;
+               pu-supply = <&reg_pu>;
+               clocks = <&clks IMX6QDL_CLK_GPU3D_CORE>,
+                        <&clks IMX6QDL_CLK_GPU3D_SHADER>,
+                        <&clks IMX6QDL_CLK_GPU2D_CORE>,
+                        <&clks IMX6QDL_CLK_GPU2D_AXI>,
+                        <&clks IMX6QDL_CLK_OPENVG_AXI>,
+                        <&clks IMX6QDL_CLK_VPU_AXI>;
+               #power-domain-cells = <1>;
+       };
+
+
+Specifying power domain for IP modules
+======================================
+
+IP cores belonging to a power domain should contain a 'power-domains' property
+that is a phandle pointing to the gpc device node and a DOMAIN_INDEX specifying
+the power domain the device belongs to.
+
+Example of a device that is part of the PU power domain:
+
+       vpu: vpu@02040000 {
+               reg = <0x02040000 0x3c000>;
+               /* ... */
+               power-domains = <&gpc 1>;
+               /* ... */
+       };
+
+The following DOMAIN_INDEX values are valid for i.MX6Q:
+ARM_DOMAIN     0
+PU_DOMAIN      1
+The following additional DOMAIN_INDEX value is valid for i.MX6SL:
+DISPLAY_DOMAIN 2
index 6a271a6ff903a055eb45e66cc40db098e2319ea9..1668b52c44a1fe849158ee5cf2c51a50a308d7df 100644 (file)
@@ -6947,6 +6947,8 @@ Q:        http://patchwork.kernel.org/project/linux-omap/list/
 T:     git git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap.git
 S:     Maintained
 F:     arch/arm/*omap*/
+F:     arch/arm/configs/omap1_defconfig
+F:     arch/arm/configs/omap2plus_defconfig
 F:     drivers/i2c/busses/i2c-omap.c
 F:     drivers/irqchip/irq-omap-intc.c
 F:     drivers/mfd/*omap*.c
index a533f72ac05aaa2f34ae89752613cd921e748d78..fb1ee1c07021eb01531f6ed544a1c8c59b3f5f2e 100644 (file)
@@ -299,9 +299,11 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
        imx6q-wandboard.dtb \
        imx6q-wandboard-revb1.dtb
 dtb-$(CONFIG_SOC_IMX6SL) += \
-       imx6sl-evk.dtb
+       imx6sl-evk.dtb \
+       imx6sl-warp.dtb
 dtb-$(CONFIG_SOC_IMX6SX) += \
        imx6sx-sabreauto.dtb \
+       imx6sx-sdb-reva.dtb \
        imx6sx-sdb.dtb
 dtb-$(CONFIG_SOC_LS1021A) += \
        ls1021a-qds.dtb \
index 712edce7d6fb12904f7063d38e57e36ab051346a..236c78a3c6cadb88a23a5b754091f049912044c4 100644 (file)
@@ -7,7 +7,7 @@
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
-&scrm_clocks {
+&scm_clocks {
        sys_clkin_ck: sys_clkin_ck {
                #clock-cells = <0>;
                compatible = "ti,mux-clock";
index acd37057bca94377e5f092a754ee9cece5dede8a..21fcc440fc1a9d886d408701a705ad4daabd2325 100644 (file)
                };
        };
 
-       am33xx_control_module: control_module@4a002000 {
-               compatible = "syscon";
-               reg = <0x44e10000 0x7fc>;
-       };
-
-       am33xx_pinmux: pinmux@44e10800 {
-               compatible = "pinctrl-single";
-               reg = <0x44e10800 0x0238>;
-               #address-cells = <1>;
-               #size-cells = <0>;
-               pinctrl-single,register-width = <32>;
-               pinctrl-single,function-mask = <0x7f>;
-       };
-
        /*
         * XXX: Use a flat representation of the AM33XX interconnect.
         * The real AM33XX interconnect network is quite complex. Since
                ranges;
                ti,hwmods = "l3_main";
 
-               prcm: prcm@44e00000 {
-                       compatible = "ti,am3-prcm";
-                       reg = <0x44e00000 0x4000>;
-
-                       prcm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+               l4_wkup: l4_wkup@44c00000 {
+                       compatible = "ti,am3-l4-wkup", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x44c00000 0x280000>;
 
-                       prcm_clockdomains: clockdomains {
-                       };
-               };
+                       prcm: prcm@200000 {
+                               compatible = "ti,am3-prcm";
+                               reg = <0x200000 0x4000>;
 
-               scrm: scrm@44e10000 {
-                       compatible = "ti,am3-scrm";
-                       reg = <0x44e10000 0x2000>;
+                               prcm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       scrm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                               prcm_clockdomains: clockdomains {
+                               };
                        };
 
-                       scrm_clockdomains: clockdomains {
+                       scm: scm@210000 {
+                               compatible = "ti,am3-scm", "simple-bus";
+                               reg = <0x210000 0x2000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x210000 0x2000>;
+
+                               am33xx_pinmux: pinmux@800 {
+                                       compatible = "pinctrl-single";
+                                       reg = <0x800 0x238>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       pinctrl-single,register-width = <32>;
+                                       pinctrl-single,function-mask = <0x7f>;
+                               };
+
+                               scm_conf: scm_conf@0 {
+                                       compatible = "syscon";
+                                       reg = <0x0 0x800>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       scm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+                               };
+
+                               scm_clockdomains: clockdomains {
+                               };
                        };
                };
 
-               cm: syscon@44e10000 {
-                       compatible = "ti,am33xx-controlmodule", "syscon";
-                       reg = <0x44e10000 0x800>;
-               };
-
                intc: interrupt-controller@48200000 {
                        compatible = "ti,am33xx-intc";
                        interrupt-controller;
                        reg = <0x481cc000 0x2000>;
                        clocks = <&dcan0_fck>;
                        clock-names = "fck";
-                       syscon-raminit = <&am33xx_control_module 0x644 0>;
+                       syscon-raminit = <&scm_conf 0x644 0>;
                        interrupts = <52>;
                        status = "disabled";
                };
                        reg = <0x481d0000 0x2000>;
                        clocks = <&dcan1_fck>;
                        clock-names = "fck";
-                       syscon-raminit = <&am33xx_control_module 0x644 1>;
+                       syscon-raminit = <&scm_conf 0x644 1>;
                        interrupts = <55>;
                        status = "disabled";
                };
                         */
                        interrupts = <40 41 42 43>;
                        ranges;
-                       syscon = <&cm>;
+                       syscon = <&scm_conf>;
                        status = "disabled";
 
                        davinci_mdio: mdio@4a101000 {
index c90724bded1081b7ea6e22461451e39d48828cec..f164dce08755cc5866b79133050db9f808cafce9 100644 (file)
@@ -31,7 +31,7 @@
                        status = "disabled";
                        reg = <0x5c000000 0x30000>;
                        interrupts = <67 68 69 70>;
-                       syscon = <&omap3_scm_general>;
+                       syscon = <&scm_conf>;
                        ti,davinci-ctrl-reg-offset = <0x10000>;
                        ti,davinci-ctrl-mod-reg-offset = <0>;
                        ti,davinci-ctrl-ram-offset = <0x20000>;
index df489d310b50aa0ad01f7750cb6fb17ea36da540..518b8fde88b0c87005fe68e413cfee769befac07 100644 (file)
@@ -7,7 +7,7 @@
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
-&scrm_clocks {
+&scm_clocks {
        emac_ick: emac_ick {
                #clock-cells = <0>;
                compatible = "ti,am35xx-gate-clock";
index ae0e8c15a6dfcbba76bb5634bfc3c4ce3e9c4dfa..48c9bea8df103369416c4b7bc9830869f9602571 100644 (file)
                cache-level = <2>;
        };
 
-       am43xx_control_module: control_module@4a002000 {
-               compatible = "syscon";
-               reg = <0x44e10000 0x7f4>;
-       };
-
-       am43xx_pinmux: pinmux@44e10800 {
-               compatible = "ti,am437-padconf", "pinctrl-single";
-               reg = <0x44e10800 0x31c>;
-               #address-cells = <1>;
-               #size-cells = <0>;
-               #interrupt-cells = <1>;
-               interrupt-controller;
-               pinctrl-single,register-width = <32>;
-               pinctrl-single,function-mask = <0xffffffff>;
-       };
-
        ocp {
                compatible = "ti,am4372-l3-noc", "simple-bus";
                #address-cells = <1>;
                interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>,
                             <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
 
-               prcm: prcm@44df0000 {
-                       compatible = "ti,am4-prcm";
-                       reg = <0x44df0000 0x11000>;
-
-                       prcm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+               l4_wkup: l4_wkup@44c00000 {
+                       compatible = "ti,am4-l4-wkup", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x44c00000 0x287000>;
 
-                       prcm_clockdomains: clockdomains {
-                       };
-               };
+                       prcm: prcm@1f0000 {
+                               compatible = "ti,am4-prcm";
+                               reg = <0x1f0000 0x11000>;
 
-               scrm: scrm@44e10000 {
-                       compatible = "ti,am4-scrm";
-                       reg = <0x44e10000 0x2000>;
+                               prcm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       scrm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                               prcm_clockdomains: clockdomains {
+                               };
                        };
 
-                       scrm_clockdomains: clockdomains {
+                       scm: scm@210000 {
+                               compatible = "ti,am4-scm", "simple-bus";
+                               reg = <0x210000 0x4000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x210000 0x4000>;
+
+                               am43xx_pinmux: pinmux@800 {
+                                       compatible = "ti,am437-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x800 0x31c>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <32>;
+                                       pinctrl-single,function-mask = <0xffffffff>;
+                               };
+
+                               scm_conf: scm_conf@0 {
+                                       compatible = "syscon";
+                                       reg = <0x0 0x800>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       scm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+                               };
+
+                               scm_clockdomains: clockdomains {
+                               };
                        };
                };
 
                };
 
                ocp2scp0: ocp2scp@483a8000 {
-                       compatible = "ti,omap-ocp2scp";
+                       compatible = "ti,am437x-ocp2scp", "ti,omap-ocp2scp";
                        #address-cells = <1>;
                        #size-cells = <1>;
                        ranges;
                };
 
                ocp2scp1: ocp2scp@483e8000 {
-                       compatible = "ti,omap-ocp2scp";
+                       compatible = "ti,am437x-ocp2scp", "ti,omap-ocp2scp";
                        #address-cells = <1>;
                        #size-cells = <1>;
                        ranges;
                        clocks = <&dcan0_fck>;
                        clock-names = "fck";
                        reg = <0x481cc000 0x2000>;
-                       syscon-raminit = <&am43xx_control_module 0x644 0>;
+                       syscon-raminit = <&scm_conf 0x644 0>;
                        interrupts = <GIC_SPI 52 IRQ_TYPE_LEVEL_HIGH>;
                        status = "disabled";
                };
                        clocks = <&dcan1_fck>;
                        clock-names = "fck";
                        reg = <0x481d0000 0x2000>;
-                       syscon-raminit = <&am43xx_control_module 0x644 1>;
+                       syscon-raminit = <&scm_conf 0x644 1>;
                        interrupts = <GIC_SPI 49 IRQ_TYPE_LEVEL_HIGH>;
                        status = "disabled";
                };
index 257c099c347e422b9dcde514355172958f14fb3f..72f01bb5d61c2b757e975419478decafd639211f 100644 (file)
                };
        };
 
-       am43xx_pinmux: pinmux@44e10800 {
+       matrix_keypad: matrix_keypad@0 {
+               compatible = "gpio-matrix-keypad";
+               debounce-delay-ms = <5>;
+               col-scan-delay-us = <2>;
+
+               row-gpios = <&gpio0 12 GPIO_ACTIVE_HIGH         /* Bank0, pin12 */
+                            &gpio0 13 GPIO_ACTIVE_HIGH         /* Bank0, pin13 */
+                            &gpio0 14 GPIO_ACTIVE_HIGH         /* Bank0, pin14 */
+                            &gpio0 15 GPIO_ACTIVE_HIGH>;       /* Bank0, pin15 */
+
+               col-gpios = <&gpio3 9 GPIO_ACTIVE_HIGH          /* Bank3, pin9 */
+                            &gpio3 10 GPIO_ACTIVE_HIGH         /* Bank3, pin10 */
+                            &gpio2 18 GPIO_ACTIVE_HIGH         /* Bank2, pin18 */
+                            &gpio2 19 GPIO_ACTIVE_HIGH>;       /* Bank2, pin19 */
+
+               linux,keymap = <0x00000201      /* P1 */
+                       0x01000204      /* P4 */
+                       0x02000207      /* P7 */
+                       0x0300020a      /* NUMERIC_STAR */
+                       0x00010202      /* P2 */
+                       0x01010205      /* P5 */
+                       0x02010208      /* P8 */
+                       0x03010200      /* P0 */
+                       0x00020203      /* P3 */
+                       0x01020206      /* P6 */
+                       0x02020209      /* P9 */
+                       0x0302020b      /* NUMERIC_POUND */
+                       0x00030067      /* UP */
+                       0x0103006a      /* RIGHT */
+                       0x0203006c      /* DOWN */
+                       0x03030069>;    /* LEFT */
+       };
+
+       backlight {
+               compatible = "pwm-backlight";
+               pwms = <&ecap0 0 50000 PWM_POLARITY_INVERTED>;
+               brightness-levels = <0 51 53 56 62 75 101 152 255>;
+               default-brightness-level = <8>;
+       };
+};
+
+&am43xx_pinmux {
                cpsw_default: cpsw_default {
                        pinctrl-single,pins = <
                                /* Slave 1 */
                                0x204 (DS0_PULL_UP_DOWN_EN | INPUT_EN | MUX_MODE7)
                        >;
                };
-       };
-
-       matrix_keypad: matrix_keypad@0 {
-                       compatible = "gpio-matrix-keypad";
-                       debounce-delay-ms = <5>;
-                       col-scan-delay-us = <2>;
-
-                       row-gpios = <&gpio0 12 GPIO_ACTIVE_HIGH         /* Bank0, pin12 */
-                                    &gpio0 13 GPIO_ACTIVE_HIGH         /* Bank0, pin13 */
-                                    &gpio0 14 GPIO_ACTIVE_HIGH         /* Bank0, pin14 */
-                                    &gpio0 15 GPIO_ACTIVE_HIGH>;       /* Bank0, pin15 */
-
-                       col-gpios = <&gpio3 9 GPIO_ACTIVE_HIGH          /* Bank3, pin9 */
-                                    &gpio3 10 GPIO_ACTIVE_HIGH         /* Bank3, pin10 */
-                                    &gpio2 18 GPIO_ACTIVE_HIGH         /* Bank2, pin18 */
-                                    &gpio2 19 GPIO_ACTIVE_HIGH>;       /* Bank2, pin19 */
-
-                       linux,keymap = <0x00000201      /* P1 */
-                               0x01000204      /* P4 */
-                               0x02000207      /* P7 */
-                               0x0300020a      /* NUMERIC_STAR */
-                               0x00010202      /* P2 */
-                               0x01010205      /* P5 */
-                               0x02010208      /* P8 */
-                               0x03010200      /* P0 */
-                               0x00020203      /* P3 */
-                               0x01020206      /* P6 */
-                               0x02020209      /* P9 */
-                               0x0302020b      /* NUMERIC_POUND */
-                               0x00030067      /* UP */
-                               0x0103006a      /* RIGHT */
-                               0x0203006c      /* DOWN */
-                               0x03030069>;    /* LEFT */
-               };
-
-       backlight {
-               compatible = "pwm-backlight";
-               pwms = <&ecap0 0 50000 PWM_POLARITY_INVERTED>;
-               brightness-levels = <0 51 53 56 62 75 101 152 255>;
-               default-brightness-level = <8>;
-       };
 };
 
 &mmc1 {
index c7dc9dab93a45eaf779497071cb9968027f5e163..44869aa7264297aa8285e926c0a327ad5d99c62a 100644 (file)
@@ -7,7 +7,7 @@
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
-&scrm_clocks {
+&scm_clocks {
        sys_clkin_ck: sys_clkin_ck {
                #clock-cells = <0>;
                compatible = "ti,mux-clock";
index 41642fe770a148a179de5aa495a00878f6d3a0be..6a3621c23017ba3f0d3ac9256c538c083a36709d 100644 (file)
@@ -86,6 +86,7 @@
                gpios =  <&tps659038_gpio 1 GPIO_ACTIVE_HIGH>;
                gpio-fan,speed-map = <0     0>,
                                     <13000 1>;
+               #cooling-cells = <2>;
        };
 
        extcon_usb1: extcon_usb1 {
                pinctrl-0 = <&tmp102_pins_default>;
                interrupt-parent = <&gpio7>;
                interrupts = <16 IRQ_TYPE_LEVEL_LOW>;
+               #thermal-sensor-cells = <1>;
        };
 };
 
 &usb2 {
        dr_mode = "peripheral";
 };
+
+&cpu_trips {
+       cpu_alert1: cpu_alert1 {
+               temperature = <50000>; /* millicelsius */
+               hysteresis = <2000>; /* millicelsius */
+               type = "active";
+       };
+};
+
+&cpu_cooling_maps {
+       map1 {
+               trip = <&cpu_alert1>;
+               cooling-device = <&gpio_fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+       };
+};
+
+&thermal_zones {
+       board_thermal: board_thermal {
+               polling-delay-passive = <1250>; /* milliseconds */
+               polling-delay = <1500>; /* milliseconds */
+
+                               /* sensor       ID */
+               thermal-sensors = <&tmp102     0>;
+
+               board_trips: trips {
+                       board_alert0: board_alert {
+                               temperature = <40000>; /* millicelsius */
+                               hysteresis = <2000>; /* millicelsius */
+                               type = "active";
+                       };
+
+                       board_crit: board_crit {
+                               temperature = <105000>; /* millicelsius */
+                               hysteresis = <0>; /* millicelsius */
+                               type = "critical";
+                       };
+               };
+
+               board_cooling_maps: cooling-maps {
+                       map0 {
+                               trip = <&board_alert0>;
+                               cooling-device =
+                                 <&gpio_fan THERMAL_NO_LIMIT THERMAL_NO_LIMIT>;
+                       };
+               };
+       };
+};
index eea4a54d6cb330467ce47dd9b1f5acb6a87ca047..a3c32e8ee90fb34c4b2243d588c233d49496df48 100644 (file)
                interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>,
                             <GIC_SPI DIRECT_IRQ(10) IRQ_TYPE_LEVEL_HIGH>;
 
-               prm: prm@4ae06000 {
-                       compatible = "ti,dra7-prm";
-                       reg = <0x4ae06000 0x3000>;
-                       interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
+               l4_cfg: l4@4a000000 {
+                       compatible = "ti,dra7-l4-cfg", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x4a000000 0x22c000>;
 
-                       prm_clocks: clocks {
+                       scm: scm@2000 {
+                               compatible = "ti,dra7-scm-core", "simple-bus";
+                               reg = <0x2000 0x2000>;
                                #address-cells = <1>;
-                               #size-cells = <0>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2000 0x2000>;
+
+                               scm_conf: scm_conf@0 {
+                                       compatible = "syscon";
+                                       reg = <0x0 0x1400>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       pbias_regulator: pbias_regulator {
+                                               compatible = "ti,pbias-omap";
+                                               reg = <0xe00 0x4>;
+                                               syscon = <&scm_conf>;
+                                               pbias_mmc_reg: pbias_mmc_omap5 {
+                                                       regulator-name = "pbias_mmc_omap5";
+                                                       regulator-min-microvolt = <1800000>;
+                                                       regulator-max-microvolt = <3000000>;
+                                               };
+                                       };
+                               };
+
+                               dra7_pmx_core: pinmux@1400 {
+                                       compatible = "ti,dra7-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x1400 0x0464>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <32>;
+                                       pinctrl-single,function-mask = <0x3fffffff>;
+                               };
+                       };
+
+                       cm_core_aon: cm_core_aon@5000 {
+                               compatible = "ti,dra7-cm-core-aon";
+                               reg = <0x5000 0x2000>;
+
+                               cm_core_aon_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
+
+                               cm_core_aon_clockdomains: clockdomains {
+                               };
+                       };
+
+                       cm_core: cm_core@8000 {
+                               compatible = "ti,dra7-cm-core";
+                               reg = <0x8000 0x3000>;
+
+                               cm_core_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
+
+                               cm_core_clockdomains: clockdomains {
+                               };
                        };
+               };
 
-                       prm_clockdomains: clockdomains {
+               l4_wkup: l4@4ae00000 {
+                       compatible = "ti,dra7-l4-wkup", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x4ae00000 0x3f000>;
+
+                       counter32k: counter@4000 {
+                               compatible = "ti,omap-counter32k";
+                               reg = <0x4000 0x40>;
+                               ti,hwmods = "counter_32k";
+                       };
+
+                       prm: prm@6000 {
+                               compatible = "ti,dra7-prm";
+                               reg = <0x6000 0x3000>;
+                               interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
+
+                               prm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
+
+                               prm_clockdomains: clockdomains {
+                               };
                        };
                };
 
                        };
                };
 
-               cm_core_aon: cm_core_aon@4a005000 {
-                       compatible = "ti,dra7-cm-core-aon";
-                       reg = <0x4a005000 0x2000>;
-
-                       cm_core_aon_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
-
-                       cm_core_aon_clockdomains: clockdomains {
-                       };
-               };
-
-               cm_core: cm_core@4a008000 {
-                       compatible = "ti,dra7-cm-core";
-                       reg = <0x4a008000 0x3000>;
-
-                       cm_core_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
-
-                       cm_core_clockdomains: clockdomains {
-                       };
-               };
-
-               counter32k: counter@4ae04000 {
-                       compatible = "ti,omap-counter32k";
-                       reg = <0x4ae04000 0x40>;
-                       ti,hwmods = "counter_32k";
+               bandgap: bandgap@4a0021e0 {
+                       reg = <0x4a0021e0 0xc
+                               0x4a00232c 0xc
+                               0x4a002380 0x2c
+                               0x4a0023C0 0x3c
+                               0x4a002564 0x8
+                               0x4a002574 0x50>;
+                               compatible = "ti,dra752-bandgap";
+                               interrupts = <GIC_SPI 121 IRQ_TYPE_LEVEL_HIGH>;
+                               #thermal-sensor-cells = <1>;
                };
 
                dra7_ctrl_core: ctrl_core@4a002000 {
                        reg = <0x4a002e00 0x7c>;
                };
 
-               pbias_regulator: pbias_regulator {
-                       compatible = "ti,pbias-omap";
-                       reg = <0 0x4>;
-                       syscon = <&dra7_ctrl_general>;
-                       pbias_mmc_reg: pbias_mmc_omap5 {
-                               regulator-name = "pbias_mmc_omap5";
-                               regulator-min-microvolt = <1800000>;
-                               regulator-max-microvolt = <3000000>;
-                       };
-               };
-
-               dra7_pmx_core: pinmux@4a003400 {
-                       compatible = "ti,dra7-padconf", "pinctrl-single";
-                       reg = <0x4a003400 0x0464>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <32>;
-                       pinctrl-single,function-mask = <0x3fffffff>;
-               };
-
                sdma: dma-controller@4a056000 {
                        compatible = "ti,omap4430-sdma";
                        reg = <0x4a056000 0x1000>;
                        compatible = "ti,dra7-d_can";
                        ti,hwmods = "dcan1";
                        reg = <0x4ae3c000 0x2000>;
-                       syscon-raminit = <&dra7_ctrl_core 0x558 0>;
+                       syscon-raminit = <&scm_conf 0x558 0>;
                        interrupts = <GIC_SPI 222 IRQ_TYPE_LEVEL_HIGH>;
                        clocks = <&dcan1_sys_clk_mux>;
                        status = "disabled";
                        compatible = "ti,dra7-d_can";
                        ti,hwmods = "dcan2";
                        reg = <0x48480000 0x2000>;
-                       syscon-raminit = <&dra7_ctrl_core 0x558 1>;
+                       syscon-raminit = <&scm_conf 0x558 1>;
                        interrupts = <GIC_SPI 225 IRQ_TYPE_LEVEL_HIGH>;
                        clocks = <&sys_clkin1>;
                        status = "disabled";
                };
        };
+
+       thermal_zones: thermal-zones {
+               #include "omap4-cpu-thermal.dtsi"
+               #include "omap5-gpu-thermal.dtsi"
+               #include "omap5-core-thermal.dtsi"
+       };
+
+};
+
+&cpu_thermal {
+       polling-delay = <500>; /* milliseconds */
 };
 
 /include/ "dra7xx-clocks.dtsi"
index e5a3d23a3df122895fc0672667e3cc41ac2b25e6..6ac8e36014999991d9ccc08c6ba39771de9cc289 100644 (file)
                        device_type = "cpu";
                        compatible = "arm,cortex-a15";
                        reg = <0>;
+
+                       /* cooling options */
+                       cooling-min-level = <0>;
+                       cooling-max-level = <2>;
+                       #cooling-cells = <2>; /* min followed by max */
                };
        };
 
index 10173fab1a15b72983d43fddf453ed5d4105f73a..eef981f4bcd5a6f68c7e739b0650d76cc5f78a4b 100644 (file)
                        clock-names = "cpu";
 
                        clock-latency = <300000>; /* From omap-cpufreq driver */
+
+                       /* cooling options */
+                       cooling-min-level = <0>;
+                       cooling-max-level = <2>;
+                       #cooling-cells = <2>; /* min followed by max */
                };
                cpu@1 {
                        device_type = "cpu";
index 9c21b15837627fcf2a98032183d77e2a8be153db..dd45e6971bc35061a3b9d5b4579c6e6697ca9eca 100644 (file)
                mux-int-port = <1>;
                mux-ext-port = <4>;
        };
+
+       wvga: display {
+               model = "CLAA057VC01CW";
+               bits-per-pixel = <16>;
+               fsl,pcr = <0xfa208b80>;
+               bus-width = <18>;
+               native-mode = <&wvga_timings>;
+               display-timings {
+                       wvga_timings: 640x480 {
+                               hactive = <640>;
+                               vactive = <480>;
+                               hback-porch = <45>;
+                               hfront-porch = <114>;
+                               hsync-len = <1>;
+                               vback-porch = <33>;
+                               vfront-porch = <11>;
+                               vsync-len = <1>;
+                               clock-frequency = <25200000>;
+                       };
+               };
+       };
 };
 
 &audmux {
                        >;
                };
 
+               pinctrl_lcd: lcdgrp {
+                       fsl,pins = <
+                               MX25_PAD_LD0__LD0               0xe0
+                               MX25_PAD_LD1__LD1               0xe0
+                               MX25_PAD_LD2__LD2               0xe0
+                               MX25_PAD_LD3__LD3               0xe0
+                               MX25_PAD_LD4__LD4               0xe0
+                               MX25_PAD_LD5__LD5               0xe0
+                               MX25_PAD_LD6__LD6               0xe0
+                               MX25_PAD_LD7__LD7               0xe0
+                               MX25_PAD_LD8__LD8               0xe0
+                               MX25_PAD_LD9__LD9               0xe0
+                               MX25_PAD_LD10__LD10             0xe0
+                               MX25_PAD_LD11__LD11             0xe0
+                               MX25_PAD_LD12__LD12             0xe0
+                               MX25_PAD_LD13__LD13             0xe0
+                               MX25_PAD_LD14__LD14             0xe0
+                               MX25_PAD_LD15__LD15             0xe0
+                               MX25_PAD_GPIO_E__LD16           0xe0
+                               MX25_PAD_GPIO_F__LD17           0xe0
+                               MX25_PAD_HSYNC__HSYNC           0xe0
+                               MX25_PAD_VSYNC__VSYNC           0xe0
+                               MX25_PAD_LSCLK__LSCLK           0xe0
+                               MX25_PAD_OE_ACD__OE_ACD         0xe0
+                               MX25_PAD_CONTRAST__CONTRAST     0xe0
+                       >;
+               };
 
                pinctrl_uart1: uart1grp {
                        fsl,pins = <
        };
 };
 
+&lcdc {
+       display = <&wvga>;
+       fsl,lpccr = <0x00a903ff>;
+       fsl,lscr1 = <0x00120300>;
+       fsl,dmacr = <0x00020010>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lcd>;
+       status = "okay";
+};
+
 &nfc {
        nand-on-flash-bbt;
        status = "okay";
index 88eebb15da6a9ed45586e2ddfba37e9e28d85336..7c4b9f2f9aad8a31214ba2627be1fcb180884220 100644 (file)
  * <mux_reg conf_reg input_reg mux_mode input_val>
  */
 
+#define MX25_PAD_TDO__TDO                      0x000 0x3e8 0x000 0x00 0x000
+
 #define MX25_PAD_A10__A10                      0x008 0x000 0x000 0x00 0x000
 #define MX25_PAD_A10__GPIO_4_0                 0x008 0x000 0x000 0x05 0x000
 
 #define MX25_PAD_A13__A13                      0x00c 0x22C 0x000 0x00 0x000
 #define MX25_PAD_A13__GPIO_4_1                 0x00c 0x22C 0x000 0x05 0x000
+#define MX25_PAD_A13__LCDC_CLS                 0x00c 0x22C 0x000 0x07 0x000
 
 #define MX25_PAD_A14__A14                      0x010 0x230 0x000 0x10 0x000
 #define MX25_PAD_A14__GPIO_2_0                 0x010 0x230 0x000 0x15 0x000
+#define MX25_PAD_A14__SIM1_CLK1                        0x010 0x230 0x000 0x16 0x000
+#define MX25_PAD_A14__LCDC_SPL                 0x010 0x230 0x000 0x17 0x000
 
 #define MX25_PAD_A15__A15                      0x014 0x234 0x000 0x10 0x000
 #define MX25_PAD_A15__GPIO_2_1                 0x014 0x234 0x000 0x15 0x000
+#define MX25_PAD_A15__SIM1_RST1                        0x014 0x234 0x000 0x16 0x000
+#define MX25_PAD_A15__LCDC_PS                  0x014 0x234 0x000 0x17 0x000
 
 #define MX25_PAD_A16__A16                      0x018 0x000 0x000 0x10 0x000
 #define MX25_PAD_A16__GPIO_2_2                 0x018 0x000 0x000 0x15 0x000
+#define MX25_PAD_A16__SIM1_VEN1                        0x018 0x000 0x000 0x16 0x000
+#define MX25_PAD_A16__LCDC_REV                 0x018 0x000 0x000 0x17 0x000
 
 #define MX25_PAD_A17__A17                      0x01c 0x238 0x000 0x10 0x000
 #define MX25_PAD_A17__GPIO_2_3                 0x01c 0x238 0x000 0x15 0x000
+#define MX25_PAD_A17__SIM1_TX                  0x01c 0x238 0x554 0x16 0x000
+#define MX25_PAD_A17__FEC_TX_ERR               0x01c 0x238 0x000 0x17 0x000
 
 #define MX25_PAD_A18__A18                      0x020 0x23c 0x000 0x10 0x000
 #define MX25_PAD_A18__GPIO_2_4                 0x020 0x23c 0x000 0x15 0x000
+#define MX25_PAD_A18__SIM1_PD1                 0x020 0x23c 0x550 0x16 0x000
 #define MX25_PAD_A18__FEC_COL                  0x020 0x23c 0x504 0x17 0x000
 
 #define MX25_PAD_A19__A19                      0x024 0x240 0x000 0x10 0x000
-#define MX25_PAD_A19__FEC_RX_ER                        0x024 0x240 0x518 0x17 0x000
 #define MX25_PAD_A19__GPIO_2_5                 0x024 0x240 0x000 0x15 0x000
+#define MX25_PAD_A19__SIM1_RX1                 0x024 0x240 0x54c 0x16 0x000
+#define MX25_PAD_A19__FEC_RX_ERR               0x024 0x240 0x518 0x17 0x000
 
 #define MX25_PAD_A20__A20                      0x028 0x244 0x000 0x10 0x000
 #define MX25_PAD_A20__GPIO_2_6                 0x028 0x244 0x000 0x15 0x000
+#define MX25_PAD_A20__SIM2_CLK1                        0x028 0x244 0x000 0x16 0x000
 #define MX25_PAD_A20__FEC_RDATA2               0x028 0x244 0x50c 0x17 0x000
 
 #define MX25_PAD_A21__A21                      0x02c 0x248 0x000 0x10 0x000
 #define MX25_PAD_A21__GPIO_2_7                 0x02c 0x248 0x000 0x15 0x000
+#define MX25_PAD_A21__SIM2_RST1                        0x02c 0x248 0x000 0x16 0x000
 #define MX25_PAD_A21__FEC_RDATA3               0x02c 0x248 0x510 0x17 0x000
 
 #define MX25_PAD_A22__A22                      0x030 0x000 0x000 0x10 0x000
 #define MX25_PAD_A22__GPIO_2_8                 0x030 0x000 0x000 0x15 0x000
+#define MX25_PAD_A22__FEC_TDATA2               0x030 0x000 0x000 0x17 0x000
+#define MX25_PAD_A22__SIM2_VEN1                        0x030 0x000 0x000 0x16 0x000
+#define MX25_PAD_A22__FEC_TDATA2               0x030 0x000 0x000 0x17 0x000
 
 #define MX25_PAD_A23__A23                      0x034 0x24c 0x000 0x10 0x000
 #define MX25_PAD_A23__GPIO_2_9                 0x034 0x24c 0x000 0x15 0x000
+#define MX25_PAD_A23__SIM2_TX1                 0x034 0x24c 0x560 0x16 0x000
+#define MX25_PAD_A23__FEC_TDATA3               0x034 0x24c 0x000 0x17 0x000
 
 #define MX25_PAD_A24__A24                      0x038 0x250 0x000 0x10 0x000
 #define MX25_PAD_A24__GPIO_2_10                        0x038 0x250 0x000 0x15 0x000
+#define MX25_PAD_A24__SIM2_PD1                 0x038 0x250 0x55c 0x16 0x000
 #define MX25_PAD_A24__FEC_RX_CLK               0x038 0x250 0x514 0x17 0x000
 
 #define MX25_PAD_A25__A25                      0x03c 0x254 0x000 0x10 0x000
 #define MX25_PAD_D15__D15                      0x088 0x280 0x000 0x00 0x000
 #define MX25_PAD_D15__LD16                     0x088 0x280 0x000 0x01 0x000
 #define MX25_PAD_D15__GPIO_4_5                 0x088 0x280 0x000 0x05 0x000
+#define MX25_PAD_D15__SDHC1_DAT7               0x088 0x280 0x4d8 0x06 0x000
 
 #define MX25_PAD_D14__D14                      0x08c 0x284 0x000 0x00 0x000
 #define MX25_PAD_D14__LD17                     0x08c 0x284 0x000 0x01 0x000
 #define MX25_PAD_D14__GPIO_4_6                 0x08c 0x284 0x000 0x05 0x000
+#define MX25_PAD_D14__SDHC1_DAT6               0x08c 0x284 0x4d4 0x06 0x000
 
 #define MX25_PAD_D13__D13                      0x090 0x288 0x000 0x00 0x000
 #define MX25_PAD_D13__LD18                     0x090 0x288 0x000 0x01 0x000
 #define MX25_PAD_D13__GPIO_4_7                 0x090 0x288 0x000 0x05 0x000
+#define MX25_PAD_D13__SDHC1_DAT5               0x090 0x288 0x4d0 0x06 0x000
 
 #define MX25_PAD_D12__D12                      0x094 0x28c 0x000 0x00 0x000
 #define MX25_PAD_D12__GPIO_4_8                 0x094 0x28c 0x000 0x05 0x000
+#define MX25_PAD_D12__SDHC1_DAT4               0x094 0x28c 0x4cc 0x06 0x000
 
 #define MX25_PAD_D11__D11                      0x098 0x290 0x000 0x00 0x000
 #define MX25_PAD_D11__GPIO_4_9                 0x098 0x290 0x000 0x05 0x000
+#define MX25_PAD_D11__USBOTG_PWR               0x098 0x290 0x000 0x06 0x000
 
 #define MX25_PAD_D10__D10                      0x09c 0x294 0x000 0x00 0x000
 #define MX25_PAD_D10__GPIO_4_10                        0x09c 0x294 0x000 0x05 0x000
 
 #define MX25_PAD_LD8__LD8                      0x0e8 0x2e0 0x000 0x10 0x000
 #define MX25_PAD_LD8__FEC_TX_ERR               0x0e8 0x2e0 0x000 0x15 0x000
+#define MX25_PAD_LD8__SDHC2_CMD                        0x0e8 0x2e0 0x4e0 0x06 0x000
 
 #define MX25_PAD_LD9__LD9                      0x0ec 0x2e4 0x000 0x10 0x000
 #define MX25_PAD_LD9__FEC_COL                  0x0ec 0x2e4 0x504 0x15 0x001
+#define MX25_PAD_LD9__SDHC2_CLK                        0x0ec 0x2e4 0x4dc 0x06 0x000
 
 #define MX25_PAD_LD10__LD10                    0x0f0 0x2e8 0x000 0x10 0x000
-#define MX25_PAD_LD10__FEC_RX_ER               0x0f0 0x2e8 0x518 0x15 0x001
+#define MX25_PAD_LD10__FEC_RX_ERR              0x0f0 0x2e8 0x518 0x15 0x001
 
 #define MX25_PAD_LD11__LD11                    0x0f4 0x2ec 0x000 0x10 0x000
 #define MX25_PAD_LD11__FEC_RDATA2              0x0f4 0x2ec 0x50c 0x15 0x001
+#define MX25_PAD_LD11__SDHC2_DAT1              0x0f4 0x2ec 0x4e8 0x06 0x000
 
 #define MX25_PAD_LD12__LD12                    0x0f8 0x2f0 0x000 0x10 0x000
+#define MX25_PAD_LD12__CSPI2_MOSI              0x0f8 0x2f0 0x4a0 0x02 0x000
 #define MX25_PAD_LD12__FEC_RDATA3              0x0f8 0x2f0 0x510 0x15 0x001
 
 #define MX25_PAD_LD13__LD13                    0x0fc 0x2f4 0x000 0x10 0x000
+#define MX25_PAD_LD13__CSPI2_MISO              0x0fc 0x2f4 0x49c 0x02 0x000
 #define MX25_PAD_LD13__FEC_TDATA2              0x0fc 0x2f4 0x000 0x15 0x000
 
 #define MX25_PAD_LD14__LD14                    0x100 0x2f8 0x000 0x10 0x000
+#define MX25_PAD_LD14__CSPI2_SCLK              0x100 0x2f8 0x494 0x02 0x000
 #define MX25_PAD_LD14__FEC_TDATA3              0x100 0x2f8 0x000 0x15 0x000
 
 #define MX25_PAD_LD15__LD15                    0x104 0x2fc 0x000 0x10 0x000
+#define MX25_PAD_LD15__CSPI2_RDY               0x104 0x2fc 0x498 0x02 0x000
 #define MX25_PAD_LD15__FEC_RX_CLK              0x104 0x2fc 0x514 0x15 0x001
 
 #define MX25_PAD_HSYNC__HSYNC                  0x108 0x300 0x000 0x10 0x000
 #define MX25_PAD_LSCLK__GPIO_1_24              0x110 0x308 0x000 0x15 0x000
 
 #define MX25_PAD_OE_ACD__OE_ACD                        0x114 0x30c 0x000 0x10 0x000
+#define MX25_PAD_OE_ACD__CSPI2_SS0             0x114 0x30c 0x4a4 0x02 0x000
 #define MX25_PAD_OE_ACD__GPIO_1_25             0x114 0x30c 0x000 0x15 0x000
 
 #define MX25_PAD_CONTRAST__CONTRAST            0x118 0x310 0x000 0x10 0x000
 
 #define MX25_PAD_CSI_D2__CSI_D2                        0x120 0x318 0x000 0x10 0x000
 #define MX25_PAD_CSI_D2__UART5_RXD_MUX         0x120 0x318 0x578 0x11 0x001
+#define MX25_PAD_CSI_D2__SIM1_CLK0             0x120 0x318 0x000 0x04 0x000
 #define MX25_PAD_CSI_D2__GPIO_1_27             0x120 0x318 0x000 0x15 0x000
 #define MX25_PAD_CSI_D2__CSPI3_MOSI            0x120 0x318 0x000 0x17 0x000
 
 #define MX25_PAD_CSI_D3__CSI_D3                        0x124 0x31c 0x000 0x10 0x000
 #define MX25_PAD_CSI_D3__UART5_TXD_MUX         0x124 0x31c 0x000 0x11 0x000
+#define MX25_PAD_CSI_D3__SIM1_RST0             0x124 0x31c 0x000 0x04 0x000
 #define MX25_PAD_CSI_D3__GPIO_1_28             0x124 0x31c 0x000 0x15 0x000
 #define MX25_PAD_CSI_D3__CSPI3_MISO            0x124 0x31c 0x4b4 0x17 0x001
 
 #define MX25_PAD_CSI_D4__CSI_D4                        0x128 0x320 0x000 0x10 0x000
 #define MX25_PAD_CSI_D4__UART5_RTS             0x128 0x320 0x574 0x11 0x001
+#define MX25_PAD_CSI_D4__SIM1_VEN0             0x128 0x320 0x000 0x04 0x000
 #define MX25_PAD_CSI_D4__GPIO_1_29             0x128 0x320 0x000 0x15 0x000
 #define MX25_PAD_CSI_D4__CSPI3_SCLK            0x128 0x320 0x000 0x17 0x000
 
 #define MX25_PAD_CSI_D5__CSI_D5                        0x12c 0x324 0x000 0x10 0x000
-#define MX25_PAD_CSI_D5__UART5_CTS             0x12c 0x324 0x000 0x11 0x001
+#define MX25_PAD_CSI_D5__UART5_CTS             0x12c 0x324 0x000 0x11 0x000
+#define MX25_PAD_CSI_D5__SIM1_TX0              0x12c 0x324 0x000 0x04 0x000
 #define MX25_PAD_CSI_D5__GPIO_1_30             0x12c 0x324 0x000 0x15 0x000
 #define MX25_PAD_CSI_D5__CSPI3_RDY             0x12c 0x324 0x000 0x17 0x000
 
 #define MX25_PAD_CSI_D6__CSI_D6                        0x130 0x328 0x000 0x10 0x000
 #define MX25_PAD_CSI_D6__SDHC2_CMD             0x130 0x328 0x4e0 0x12 0x001
+#define MX25_PAD_CSI_D6__SIM1_PD0              0x130 0x328 0x000 0x04 0x000
 #define MX25_PAD_CSI_D6__GPIO_1_31             0x130 0x328 0x000 0x15 0x000
 
 #define MX25_PAD_CSI_D7__CSI_D7                        0x134 0x32c 0x000 0x10 0x000
 #define MX25_PAD_CSI_D7__GPIO_1_6              0x134 0x32c 0x000 0x15 0x000
 
 #define MX25_PAD_CSI_D8__CSI_D8                        0x138 0x330 0x000 0x10 0x000
-#define MX25_PAD_CSI_D8__AUD6_RXC              0x138 0x330 0x000 0x12 0x001
+#define MX25_PAD_CSI_D8__AUD6_RXC              0x138 0x330 0x000 0x12 0x000
 #define MX25_PAD_CSI_D8__GPIO_1_7              0x138 0x330 0x000 0x15 0x000
 #define MX25_PAD_CSI_D8__CSPI3_SS2             0x138 0x330 0x4c4 0x17 0x000
 
 #define MX25_PAD_CSI_D9__CSI_D9                        0x13c 0x334 0x000 0x10 0x000
-#define MX25_PAD_CSI_D9__AUD6_RXFS             0x13c 0x334 0x000 0x12 0x001
+#define MX25_PAD_CSI_D9__AUD6_RXFS             0x13c 0x334 0x000 0x12 0x000
 #define MX25_PAD_CSI_D9__GPIO_4_21             0x13c 0x334 0x000 0x15 0x000
 #define MX25_PAD_CSI_D9__CSPI3_SS3             0x13c 0x334 0x4c8 0x17 0x000
 
 #define MX25_PAD_CSI_MCLK__CSI_MCLK            0x140 0x338 0x000 0x10 0x000
-#define MX25_PAD_CSI_MCLK__AUD6_TXD            0x140 0x338 0x000 0x11 0x001
+#define MX25_PAD_CSI_MCLK__AUD6_TXD            0x140 0x338 0x000 0x11 0x000
 #define MX25_PAD_CSI_MCLK__SDHC2_DAT0          0x140 0x338 0x4e4 0x12 0x001
 #define MX25_PAD_CSI_MCLK__GPIO_1_8            0x140 0x338 0x000 0x15 0x000
 
 #define MX25_PAD_CSI_VSYNC__CSI_VSYNC          0x144 0x33c 0x000 0x10 0x000
-#define MX25_PAD_CSI_VSYNC__AUD6_RXD           0x144 0x33c 0x000 0x11 0x001
+#define MX25_PAD_CSI_VSYNC__AUD6_RXD           0x144 0x33c 0x000 0x11 0x000
 #define MX25_PAD_CSI_VSYNC__SDHC2_DAT1         0x144 0x33c 0x4e8 0x12 0x001
 #define MX25_PAD_CSI_VSYNC__GPIO_1_9           0x144 0x33c 0x000 0x15 0x000
 
 #define MX25_PAD_CSI_HSYNC__CSI_HSYNC          0x148 0x340 0x000 0x10 0x000
-#define MX25_PAD_CSI_HSYNC__AUD6_TXC           0x148 0x340 0x000 0x11 0x001
+#define MX25_PAD_CSI_HSYNC__AUD6_TXC           0x148 0x340 0x000 0x11 0x000
 #define MX25_PAD_CSI_HSYNC__SDHC2_DAT2         0x148 0x340 0x4ec 0x12 0x001
 #define MX25_PAD_CSI_HSYNC__GPIO_1_10          0x148 0x340 0x000 0x15 0x000
 
 #define MX25_PAD_CSI_PIXCLK__CSI_PIXCLK                0x14c 0x344 0x000 0x10 0x000
-#define MX25_PAD_CSI_PIXCLK__AUD6_TXFS         0x14c 0x344 0x000 0x11 0x001
+#define MX25_PAD_CSI_PIXCLK__AUD6_TXFS         0x14c 0x344 0x000 0x11 0x000
 #define MX25_PAD_CSI_PIXCLK__SDHC2_DAT3                0x14c 0x344 0x4f0 0x12 0x001
 #define MX25_PAD_CSI_PIXCLK__GPIO_1_11         0x14c 0x344 0x000 0x15 0x000
 
 #define MX25_PAD_UART2_RTS__CC1                        0x188 0x380 0x000 0x13 0x000
 #define MX25_PAD_UART2_RTS__GPIO_4_28          0x188 0x380 0x000 0x15 0x000
 
-#define MX25_PAD_UART2_CTS__FEC_RX_ER          0x18c 0x384 0x518 0x12 0x002
 #define MX25_PAD_UART2_CTS__UART2_CTS          0x18c 0x384 0x000 0x10 0x000
+#define MX25_PAD_UART2_CTS__FEC_RX_ERR         0x18c 0x384 0x518 0x12 0x002
 #define MX25_PAD_UART2_CTS__GPIO_4_29          0x18c 0x384 0x000 0x15 0x000
 
 #define MX25_PAD_SD1_CMD__SD1_CMD              0x190 0x388 0x000 0x10 0x000
 #define MX25_PAD_SD1_DATA1__GPIO_2_26          0x19c 0x394 0x000 0x15 0x000
 
 #define MX25_PAD_SD1_DATA2__SD1_DATA2          0x1a0 0x398 0x000 0x10 0x000
-#define MX25_PAD_SD1_DATA2__FEC_RX_CLK         0x1a0 0x398 0x514 0x15 0x002
+#define MX25_PAD_SD1_DATA2__FEC_RX_CLK         0x1a0 0x398 0x514 0x12 0x002
 #define MX25_PAD_SD1_DATA2__GPIO_2_27          0x1a0 0x398 0x000 0x15 0x000
 
 #define MX25_PAD_SD1_DATA3__SD1_DATA3          0x1a4 0x39c 0x000 0x10 0x000
-#define MX25_PAD_SD1_DATA3__FEC_CRS            0x1a4 0x39c 0x508 0x10 0x002
+#define MX25_PAD_SD1_DATA3__FEC_CRS            0x1a4 0x39c 0x508 0x12 0x002
 #define MX25_PAD_SD1_DATA3__GPIO_2_28          0x1a4 0x39c 0x000 0x15 0x000
 
 #define MX25_PAD_KPP_ROW0__KPP_ROW0            0x1a8 0x3a0 0x000 0x10 0x000
 #define MX25_PAD_KPP_ROW2__GPIO_2_31           0x1b0 0x3a8 0x000 0x15 0x000
 
 #define MX25_PAD_KPP_ROW3__KPP_ROW3            0x1b4 0x3ac 0x000 0x10 0x000
-#define MX25_PAD_KPP_ROW3__CSI_LD1             0x1b4 0x3ac 0x48c 0x13 0x002
+#define MX25_PAD_KPP_ROW3__CSI_D1              0x1b4 0x3ac 0x48c 0x13 0x002
 #define MX25_PAD_KPP_ROW3__GPIO_3_0            0x1b4 0x3ac 0x000 0x15 0x000
 
 #define MX25_PAD_KPP_COL0__KPP_COL0            0x1b8 0x3b0 0x000 0x10 0x000
 #define MX25_PAD_FEC_RDATA0__GPIO_3_10         0x1dc 0x3d4 0x000 0x15 0x000
 
 #define MX25_PAD_FEC_RDATA1__FEC_RDATA1                0x1e0 0x3d8 0x000 0x10 0x000
+/*
+ * According to the i.MX25 Reference manual (IMX25RM, Rev. 2,
+ * 01/2011) this is CAN1_TX but that's wrong.
+ */
+#define MX25_PAD_FEC_RDATA1__CAN2_TX           0x1e0 0x3d8 0x000 0x14 0x000
 #define MX25_PAD_FEC_RDATA1__GPIO_3_11         0x1e0 0x3d8 0x000 0x15 0x000
 
 #define MX25_PAD_FEC_RX_DV__FEC_RX_DV          0x1e4 0x3dc 0x000 0x10 0x000
+/*
+ * According to the i.MX25 Reference manual (IMX25RM, Rev. 2,
+ * 01/2011) this is CAN1_RX but that's wrong.
+ */
 #define MX25_PAD_FEC_RX_DV__CAN2_RX            0x1e4 0x3dc 0x484 0x14 0x000
 #define MX25_PAD_FEC_RX_DV__GPIO_3_12          0x1e4 0x3dc 0x000 0x15 0x000
 
 #define MX25_PAD_DE_B__DE_B                    0x1f0 0x3ec 0x000 0x10 0x000
 #define MX25_PAD_DE_B__GPIO_2_20               0x1f0 0x3ec 0x000 0x15 0x000
 
-#define MX25_PAD_TDO__TDO                      0x000 0x3e8 0x000 0x00 0x000
-
 #define MX25_PAD_GPIO_A__GPIO_A                        0x1f4 0x3f0 0x000 0x10 0x000
 #define MX25_PAD_GPIO_A__CAN1_TX               0x1f4 0x3f0 0x000 0x16 0x000
 #define MX25_PAD_GPIO_A__USBOTG_PWR            0x1f4 0x3f0 0x000 0x12 0x000
 
 #define MX25_PAD_GPIO_B__GPIO_B                        0x1f8 0x3f4 0x000 0x10 0x000
-#define MX25_PAD_GPIO_B__CAN1_RX               0x1f8 0x3f4 0x480 0x16 0x001
 #define MX25_PAD_GPIO_B__USBOTG_OC             0x1f8 0x3f4 0x57c 0x12 0x001
+#define MX25_PAD_GPIO_B__CAN1_RX               0x1f8 0x3f4 0x480 0x16 0x001
 
 #define MX25_PAD_GPIO_C__GPIO_C                        0x1fc 0x3f8 0x000 0x10 0x000
+#define MX25_PAD_GPIO_C__PWM4_PWMO             0x1fc 0x3f8 0x000 0x11 0x000
+#define MX25_PAD_GPIO_C__I2C2_SCL              0x1fc 0x3f8 0x51c 0x12 0x001
+#define MX25_PAD_GPIO_C__KPP_COL4              0x1fc 0x3f8 0x52c 0x13 0x001
 #define MX25_PAD_GPIO_C__CAN2_TX               0x1fc 0x3f8 0x000 0x16 0x000
 
 #define MX25_PAD_GPIO_D__GPIO_D                        0x200 0x3fc 0x000 0x10 0x000
+#define MX25_PAD_GPIO_D__I2C2_SDA              0x200 0x3fc 0x520 0x12 0x001
 #define MX25_PAD_GPIO_D__CAN2_RX               0x200 0x3fc 0x484 0x16 0x001
 
 #define MX25_PAD_GPIO_E__GPIO_E                        0x204 0x400 0x000 0x10 0x000
 #define MX25_PAD_GPIO_E__I2C3_CLK              0x204 0x400 0x524 0x11 0x002
 #define MX25_PAD_GPIO_E__LD16                  0x204 0x400 0x000 0x12 0x000
 #define MX25_PAD_GPIO_E__AUD7_TXD              0x204 0x400 0x000 0x14 0x000
+#define MX25_PAD_GPIO_E__UART4_RXD             0x204 0x400 0x570 0x16 0x002
 
 #define MX25_PAD_GPIO_F__GPIO_F                        0x208 0x404 0x000 0x10 0x000
 #define MX25_PAD_GPIO_F__LD17                  0x208 0x404 0x000 0x12 0x000
 #define MX25_PAD_GPIO_F__AUD7_TXC              0x208 0x404 0x000 0x14 0x000
+#define MX25_PAD_GPIO_F__UART4_TXD             0x208 0x404 0x000 0x16 0x000
 
 #define MX25_PAD_EXT_ARMCLK__EXT_ARMCLK                0x20c 0x000 0x000 0x10 0x000
 #define MX25_PAD_EXT_ARMCLK__GPIO_3_15         0x20c 0x000 0x000 0x15 0x000
 #define MX25_PAD_VSTBY_REQ__VSTBY_REQ          0x214 0x408 0x000 0x10 0x000
 #define MX25_PAD_VSTBY_REQ__AUD7_TXFS          0x214 0x408 0x000 0x14 0x000
 #define MX25_PAD_VSTBY_REQ__GPIO_3_17          0x214 0x408 0x000 0x15 0x000
+
 #define MX25_PAD_VSTBY_ACK__VSTBY_ACK          0x218 0x40c 0x000 0x10 0x000
 #define MX25_PAD_VSTBY_ACK__GPIO_3_18          0x218 0x40c 0x000 0x15 0x000
 
 
 #define MX25_PAD_BOOT_MODE0__BOOT_MODE0                0x224 0x000 0x000 0x00 0x000
 #define MX25_PAD_BOOT_MODE0__GPIO_4_30         0x224 0x000 0x000 0x05 0x000
+
 #define MX25_PAD_BOOT_MODE1__BOOT_MODE1                0x228 0x000 0x000 0x00 0x000
 #define MX25_PAD_BOOT_MODE1__GPIO_4_31         0x228 0x000 0x000 0x05 0x000
 
index 4b063b68db44cbd1f99c3b63bcdb5463a0236baa..6951b66d1ab7b4cbe37dcf8944a7626213979827 100644 (file)
                                interrupts = <54>;
                                clocks = <&clks IMX27_CLK_USB_IPG_GATE>;
                                fsl,usbmisc = <&usbmisc 1>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <55>;
                                clocks = <&clks IMX27_CLK_USB_IPG_GATE>;
                                fsl,usbmisc = <&usbmisc 2>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index 7198fe3798c62b52c2c86f5d2f895cc5179571fe..070e59cbdd8b76659506cf45a078a1e302bbe942 100644 (file)
@@ -78,7 +78,7 @@
                        phy-mode = "rmii";
                        pinctrl-names = "default";
                        pinctrl-0 = <&mac0_pins_a>;
-                       phy-reset-gpios = <&gpio4 13 0>;
+                       phy-reset-gpios = <&gpio4 13 GPIO_ACTIVE_LOW>;
                        status = "okay";
                };
        };
index 1f38a052ad4b0d8767b712994d3c97ca110ca8ff..7ac4f1af16ac856d243674c630b9207da71d8335 100644 (file)
                                        };
                                };
                        };
+
+                       can0: can@80032000 {
+                               pinctrl-names = "default";
+                               pinctrl-0 = <&can0_pins_a>;
+                               xceiver-supply = <&reg_can0_vcc>;
+                               status = "okay";
+                       };
                };
 
                apbx@80040000 {
                                status = "okay";
                        };
 
+                       auart0: serial@8006a000 {
+                               pinctrl-names = "default";
+                               pinctrl-0 = <&auart0_pins_a>;
+                               fsl,uart-has-rtscts;
+                               status = "okay";
+                       };
+
                        usbphy0: usbphy@8007c000 {
                                status = "okay";
                        };
        ahb@80080000 {
                usb0: usb@80080000 {
                        pinctrl-names = "default";
-                       pinctrl-0 = <&usb0_otg_apf28dev>;
+                       pinctrl-0 = <&usb0_otg_apf28dev
+                                       &usb0_id_pins_b>;
                        vbus-supply = <&reg_usb0_vbus>;
                        status = "okay";
                };
                        phy-mode = "rmii";
                        pinctrl-names = "default";
                        pinctrl-0 = <&mac1_pins_a>;
-                       phy-reset-gpios = <&gpio0 23 0>;
+                       phy-reset-gpios = <&gpio1 29 GPIO_ACTIVE_LOW>;
                        status = "okay";
                };
        };
                        gpio = <&gpio1 23 1>;
                        enable-active-high;
                };
+
+               reg_can0_vcc: regulator@1 {
+                       compatible = "regulator-fixed";
+                       reg = <1>;
+                       regulator-name = "can0_vcc";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+               };
        };
 
        leds {
 
                user-button {
                        label = "User button";
-                       gpios = <&gpio0 17 0>;
+                       gpios = <&gpio0 17 GPIO_ACTIVE_LOW>;
                        linux,code = <0x100>;
+                       gpio-key,wakeup;
                };
        };
 };
index 47f68ac868d4b6ab20751d5d2d457a31f10a7ef6..25e25f82fbaea4d9cc5bafa62ec93d1e0ba3f1c4 100644 (file)
                                        fsl,pull-up = <MXS_PULL_DISABLE>;
                                };
 
+                               spi3_pins_b: spi3@1 {
+                                       reg = <1>;
+                                       fsl,pinmux-ids = <
+                                               MX28_PAD_SSP3_SCK__SSP3_SCK
+                                               MX28_PAD_SSP3_MOSI__SSP3_CMD
+                                               MX28_PAD_SSP3_MISO__SSP3_D0
+                                               MX28_PAD_SSP3_SS0__SSP3_D3
+                                       >;
+                                       fsl,drive-strength = <MXS_DRIVE_8mA>;
+                                       fsl,voltage = <MXS_VOLTAGE_HIGH>;
+                                       fsl,pull-up = <MXS_PULL_ENABLE>;
+                               };
+
                                usb0_pins_a: usb0@0 {
                                        reg = <0>;
                                        fsl,pinmux-ids = <
                        interrupts = <92>;
                        clocks = <&clks 61>;
                        fsl,usbphy = <&usbphy1>;
+                       dr_mode = "host";
                        status = "disabled";
                };
 
index 6932928f3b45c99cc4d807edacf9475e55650056..b6478e97d6a7eb8cbb6478470d4a5e10794afaff 100644 (file)
                                clocks = <&clks 73>;
                                fsl,usbmisc = <&usbmisc 1>;
                                fsl,usbphy = <&usbphy1>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index 620b0f030591209f26dc0ad19af226b9a8310ed8..e2457138311f8661fd063da8be351a84cef49ced 100644 (file)
                                reg = <0x53f80200 0x0200>;
                                interrupts = <14>;
                                clocks = <&clks IMX5_CLK_USB_PHY2_GATE>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                reg = <0x53f80400 0x0200>;
                                interrupts = <16>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                reg = <0x53f80600 0x0200>;
                                interrupts = <17>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index c0116cffc513436d54584ee9d1c9d8ad933ebb83..f46fe9bf0bcb37a903d7ee05d67cc3289516acac 100644 (file)
                                interrupts = <14>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 1>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <16>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 2>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <17>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 3>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index ff4fa7ecacd86ef1ddc7f4a63f23e32af5d2808c..c3e3ca9362fbb78b6b2ecb8ec0125b83abdb7352 100644 (file)
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 1>;
                                fsl,usbphy = <&usbphy1>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <16>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 2>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <17>;
                                clocks = <&clks IMX5_CLK_USBOH3_GATE>;
                                fsl,usbmisc = <&usbmisc 3>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index 9cd06e5e59f00e35b579c07118eed164872330b9..d4c4a22db4888269c26a2294add2421dd4349c7e 100644 (file)
@@ -83,3 +83,7 @@
 &ipu1_di0_disp0 {
        remote-endpoint = <&display0_in>;
 };
+
+&pwm1 {
+       status = "okay";
+};
index b413e24288dcb08b5ba5b73d461eaf67c3e2b175..15203f0e9725cb775dac06399ab212d12479e536 100644 (file)
@@ -72,3 +72,7 @@
 &ipu1_di0_disp0 {
        remote-endpoint = <&display0_in>;
 };
+
+&pwm3 {
+       status = "okay";
+};
index 58aa8f2b0f260f7613da2890cfce01a0fac25096..e0b7fe8e18f886608e7dd302409f0d045e1ebb29 100644 (file)
@@ -1,5 +1,43 @@
 /*
  * Copyright (C) 2014 Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 /dts-v1/;
 
index 44a0e6736bb1217369b3c45e32ad4dbb007cea03..7369d2d7da3e545904d84175f353e220d267fef0 100644 (file)
@@ -1,6 +1,44 @@
 /*
  * Copyright (C) 2014 Rabeeh Khoury (rabeeh@solid-run.com)
  * Based on dt work by Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 /dts-v1/;
 
index 9efd8b0c8011fea501c0033e3da5dd5cfed3e849..670bd8c4c847514f11bc3118f2b561b86fc8099d 100644 (file)
@@ -1,5 +1,43 @@
 /*
  * Copyright (C) 2014 Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 /dts-v1/;
 
index c2bf8476ce45f8c496ea18e389bebc7839cb0d85..0f6044553a2490106c413b86bba4c5bbf515f6c9 100644 (file)
@@ -1,6 +1,44 @@
 /*
  * Copyright (C) 2014 Rabeeh Khoury (rabeeh@solid-run.com)
  * Based on dt work by Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 /dts-v1/;
 
index 93ec79bb6b35c54b451ff8ccb9775387f8574aa4..399103b8e2c948110154fa0b109e917a192061b0 100644 (file)
 };
 
 &mipi_dsi {
-       port@2 {
-               reg = <2>;
+       ports {
+               port@2 {
+                       reg = <2>;
 
-               mipi_mux_2: endpoint {
-                       remote-endpoint = <&ipu2_di0_mipi>;
+                       mipi_mux_2: endpoint {
+                               remote-endpoint = <&ipu2_di0_mipi>;
+                       };
                };
-       };
 
-       port@3 {
-               reg = <3>;
+               port@3 {
+                       reg = <3>;
 
-               mipi_mux_3: endpoint {
-                       remote-endpoint = <&ipu2_di1_mipi>;
+                       mipi_mux_3: endpoint {
+                               remote-endpoint = <&ipu2_di1_mipi>;
+                       };
                };
        };
 };
index 6a524ca011e70df048939fbc5ef0659c88a660e9..d033bb1820602773c9c0beaf661f779381344221 100644 (file)
@@ -1,8 +1,48 @@
 /*
  * Copyright (C) 2014 Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 #include "imx6qdl-microsom.dtsi"
 #include "imx6qdl-microsom-ar8035.dtsi"
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/gpio/gpio.h>
 
 / {
        ir_recv: ir-receiver {
                spdif-controller = <&spdif>;
                spdif-out;
        };
+
+       gpio-keys {
+               compatible = "gpio-keys";
+               pinctrl-0 = <&pinctrl_gpio_key>;
+               pinctrl-names = "default";
+
+               button_0 {
+                       label = "Button 0";
+                       gpios = <&gpio3 8 GPIO_ACTIVE_LOW>;
+                       linux,code = <BTN_0>;
+               };
+       };
 };
 
 &hdmi {
                                MX6QDL_PAD_SD2_DAT3__SD2_DATA3 0x13059
                        >;
                };
+
+               pinctrl_gpio_key: gpio-key {
+                       fsl,pins = <
+                               MX6QDL_PAD_EIM_DA8__GPIO3_IO08  0x17059
+                       >;
+               };
        };
 };
 
+&pwm1 {
+       status = "okay";
+};
+
 &spdif {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_cubox_i_spdif>;
index 62841e85a91e45d38e71c6e7a65d2d8f8b024154..151a3db2aea957f39d4437812e06a46455e117cb 100644 (file)
@@ -1,5 +1,43 @@
 /*
  * Copyright (C) 2013,2014 Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 #include "imx6qdl-microsom.dtsi"
 #include "imx6qdl-microsom-ar8035.dtsi"
                };
        };
 
+       sound-sgtl5000 {
+               audio-codec = <&sgtl5000>;
+               audio-routing =
+                       "MIC_IN", "Mic Jack",
+                       "Mic Jack", "Mic Bias",
+                       "Headphone Jack", "HP_OUT";
+               compatible = "fsl,imx-audio-sgtl5000";
+               model = "On-board Codec";
+               mux-ext-port = <5>;
+               mux-int-port = <1>;
+               ssi-controller = <&ssi1>;
+       };
+
        sound-spdif {
                compatible = "fsl,imx-audio-spdif";
                model = "On-board SPDIF";
        };
 };
 
+&audmux {
+       status = "okay";
+};
+
 &can1 {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_hummingboard_flexcan1>;
 &i2c1 {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_hummingboard_i2c1>;
-
-       /*
-        * Not fitted on Carrier-1 board... yet
        status = "okay";
 
+       /* Pro baseboard model */
        rtc: pcf8523@68 {
                compatible = "nxp,pcf8523";
                reg = <0x68>;
        };
-        */
+
+       /* Pro baseboard model */
+       sgtl5000: sgtl5000@0a {
+               clocks = <&clks IMX6QDL_CLK_CKO>;
+               compatible = "fsl,sgtl5000";
+               pinctrl-names = "default";
+               pinctrl-0 = <&pinctrl_hummingboard_sgtl5000>;
+               reg = <0x0a>;
+               VDDA-supply = <&reg_3p3v>;
+               VDDIO-supply = <&reg_3p3v>;
+       };
 };
 
 &i2c2 {
                        >;
                };
 
+               pinctrl_hummingboard_pwm1: pwm1grp {
+                       fsl,pins = <MX6QDL_PAD_DISP0_DAT8__PWM1_OUT 0x1b0b1>;
+               };
+
+               pinctrl_hummingboard_sgtl5000: hummingboard-sgtl5000 {
+                       fsl,pins = <
+                               MX6QDL_PAD_DISP0_DAT19__AUD5_RXD 0x130b0
+                               MX6QDL_PAD_KEY_COL0__AUD5_TXC 0x130b0
+                               MX6QDL_PAD_KEY_ROW0__AUD5_TXD 0x110b0
+                               MX6QDL_PAD_KEY_COL1__AUD5_TXFS 0x130b0
+                               MX6QDL_PAD_GPIO_5__CCM_CLKO1 0x130b0
+                       >;
+               };
+
                pinctrl_hummingboard_spdif: hummingboard-spdif {
                        fsl,pins = <MX6QDL_PAD_GPIO_17__SPDIF_OUT 0x13091>;
                };
        };
 };
 
+&pwm1 {
+        pinctrl-names = "default";
+        pinctrl-0 = <&pinctrl_hummingboard_pwm1>;
+        status = "okay";
+};
+
+&pwm2 {
+        pinctrl-names = "default";
+        status = "okay";
+};
+
 &spdif {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_hummingboard_spdif>;
        status = "okay";
 };
 
+&ssi1 {
+       fsl,mode = "i2s-slave";
+       status = "okay";
+};
+
 &usbh1 {
        disable-over-current;
        vbus-supply = <&reg_usbh1_vbus>;
index db9f45b2c57304603a78db4c20ca50a0f133c247..4a1820309cdb82e1ac0c9dcdb8fd5b11aa306a02 100644 (file)
@@ -3,6 +3,44 @@
  *
  * This describes the hookup for an AR8035 to the iMX6 on the SolidRun
  * MicroSOM.
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 &fec {
        pinctrl-names = "default";
index 79eac6849d4c9d8964882d1e64435d868c2c7c01..349f82be816eb77c0119cdeeba4eb424711b9bb0 100644 (file)
@@ -1,5 +1,43 @@
 /*
  * Copyright (C) 2013,2014 Russell King
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of the
+ *     License.
+ *
+ *     This file is distributed in the hope that it will be useful
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
  */
 
 &iomuxc {
index 009abd69385d854c15c4b35bc98aca87a1ef8d84..46b2fed7c319c891dde01d415521b7207702b45b 100644 (file)
        };
 };
 
+&i2c3 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_i2c3>;
+       pinctrl-assert-gpios = <&gpio5 4 GPIO_ACTIVE_HIGH>;
+       status = "okay";
+
+       max7310_a: gpio@30 {
+               compatible = "maxim,max7310";
+               reg = <0x30>;
+               gpio-controller;
+               #gpio-cells = <2>;
+       };
+
+       max7310_b: gpio@32 {
+               compatible = "maxim,max7310";
+               reg = <0x32>;
+               gpio-controller;
+               #gpio-cells = <2>;
+       };
+
+       max7310_c: gpio@34 {
+               compatible = "maxim,max7310";
+               reg = <0x34>;
+               gpio-controller;
+               #gpio-cells = <2>;
+       };
+};
+
 &iomuxc {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_hog>;
                        >;
                };
 
+               pinctrl_i2c3: i2c3grp {
+                       fsl,pins = <
+                               MX6QDL_PAD_GPIO_3__I2C3_SCL  0x4001b8b1
+                               MX6QDL_PAD_EIM_D18__I2C3_SDA 0x4001b8b1
+                       >;
+               };
+
                pinctrl_pwm3: pwm1grp {
                        fsl,pins = <
                                MX6QDL_PAD_SD4_DAT1__PWM3_OUT           0x1b0b1
index d6c69ec443149da28012034ceea65ac2ba522539..f74a8ded515f22b9985b8d48b370a45c34e9d88e 100644 (file)
@@ -53,6 +53,7 @@
                interrupt-controller;
                reg = <0x00a01000 0x1000>,
                      <0x00a00100 0x100>;
+               interrupt-parent = <&intc>;
        };
 
        clocks {
@@ -82,7 +83,7 @@
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "simple-bus";
-               interrupt-parent = <&intc>;
+               interrupt-parent = <&gpc>;
                ranges;
 
                dma_apbh: dma-apbh@00110000 {
                        compatible = "arm,cortex-a9-twd-timer";
                        reg = <0x00a00600 0x20>;
                        interrupts = <1 13 0xf01>;
+                       interrupt-parent = <&intc>;
                        clocks = <&clks IMX6QDL_CLK_TWD>;
                };
 
                                clocks = <&clks IMX6QDL_CLK_IPG>,
                                         <&clks IMX6QDL_CLK_PWM1>;
                                clock-names = "ipg", "per";
+                               status = "disabled";
                        };
 
                        pwm2: pwm@02084000 {
                                clocks = <&clks IMX6QDL_CLK_IPG>,
                                         <&clks IMX6QDL_CLK_PWM2>;
                                clock-names = "ipg", "per";
+                               status = "disabled";
                        };
 
                        pwm3: pwm@02088000 {
                                clocks = <&clks IMX6QDL_CLK_IPG>,
                                         <&clks IMX6QDL_CLK_PWM3>;
                                clock-names = "ipg", "per";
+                               status = "disabled";
                        };
 
                        pwm4: pwm@0208c000 {
                                clocks = <&clks IMX6QDL_CLK_IPG>,
                                         <&clks IMX6QDL_CLK_PWM4>;
                                clock-names = "ipg", "per";
+                               status = "disabled";
                        };
 
                        can1: flexcan@02090000 {
                                        regulator-name = "vddpu";
                                        regulator-min-microvolt = <725000>;
                                        regulator-max-microvolt = <1450000>;
-                                       regulator-always-on;
+                                       regulator-enable-ramp-delay = <150>;
                                        anatop-reg-offset = <0x140>;
                                        anatop-vol-bit-shift = <9>;
                                        anatop-vol-bit-width = <5>;
                                #size-cells = <1>;
                                ranges = <0 0x020cc000 0x4000>;
 
-                               snvs-rtc-lp@34 {
+                               snvs_rtc: snvs-rtc-lp@34 {
                                        compatible = "fsl,sec-v4.0-mon-rtc-lp";
                                        reg = <0x34 0x58>;
                                        interrupts = <0 19 IRQ_TYPE_LEVEL_HIGH>,
                        gpc: gpc@020dc000 {
                                compatible = "fsl,imx6q-gpc";
                                reg = <0x020dc000 0x4000>;
+                               interrupt-controller;
+                               #interrupt-cells = <3>;
                                interrupts = <0 89 IRQ_TYPE_LEVEL_HIGH>,
                                             <0 90 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-parent = <&intc>;
+                               pu-supply = <&reg_pu>;
+                               clocks = <&clks IMX6QDL_CLK_GPU3D_CORE>,
+                                        <&clks IMX6QDL_CLK_GPU3D_SHADER>,
+                                        <&clks IMX6QDL_CLK_GPU2D_CORE>,
+                                        <&clks IMX6QDL_CLK_GPU2D_AXI>,
+                                        <&clks IMX6QDL_CLK_OPENVG_AXI>,
+                                        <&clks IMX6QDL_CLK_VPU_AXI>;
+                               #power-domain-cells = <1>;
                        };
 
                        gpr: iomuxc-gpr@020e0000 {
                                clocks = <&clks IMX6QDL_CLK_USBOH3>;
                                fsl,usbphy = <&usbphy2>;
                                fsl,usbmisc = <&usbmisc 1>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <0 41 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks IMX6QDL_CLK_USBOH3>;
                                fsl,usbmisc = <&usbmisc 2>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                interrupts = <0 42 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks IMX6QDL_CLK_USBOH3>;
                                fsl,usbmisc = <&usbmisc 3>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
                                reg = <0x021e0000 0x4000>;
                                status = "disabled";
 
-                               port@0 {
-                                       reg = <0>;
+                               ports {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+
+                                       port@0 {
+                                               reg = <0>;
 
-                                       mipi_mux_0: endpoint {
-                                               remote-endpoint = <&ipu1_di0_mipi>;
+                                               mipi_mux_0: endpoint {
+                                                       remote-endpoint = <&ipu1_di0_mipi>;
+                                               };
                                        };
-                               };
 
-                               port@1 {
-                                       reg = <1>;
+                                       port@1 {
+                                               reg = <1>;
 
-                                       mipi_mux_1: endpoint {
-                                               remote-endpoint = <&ipu1_di1_mipi>;
+                                               mipi_mux_1: endpoint {
+                                                       remote-endpoint = <&ipu1_di1_mipi>;
+                                               };
                                        };
                                };
                        };
diff --git a/arch/arm/boot/dts/imx6sl-warp.dts b/arch/arm/boot/dts/imx6sl-warp.dts
new file mode 100644 (file)
index 0000000..64f7dec
--- /dev/null
@@ -0,0 +1,262 @@
+/*
+ * Copyright 2014, 2015 O.S. Systems Software LTDA.
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of
+ *     the License, or (at your option) any later version.
+ *
+ *     This file is distributed in the hope that it will be useful,
+ *     but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *     GNU General Public License for more details.
+ *
+ *     You should have received a copy of the GNU General Public
+ *     License along with this file; if not, write to the Free
+ *     Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+ *     MA 02110-1301 USA
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ *     obtaining a copy of this software and associated documentation
+ *     files (the "Software"), to deal in the Software without
+ *     restriction, including without limitation the rights to use,
+ *     copy, modify, merge, publish, distribute, sublicense, and/or
+ *     sell copies of the Software, and to permit persons to whom the
+ *     Software is furnished to do so, subject to the following
+ *     conditions:
+ *
+ *     The above copyright notice and this permission notice shall be
+ *     included in all copies or substantial portions of the Software.
+ *
+ *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ *     OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include "imx6sl.dtsi"
+
+/ {
+       model = "WaRP Board";
+       compatible = "warp,imx6sl-warp", "fsl,imx6sl";
+
+       memory {
+               reg = <0x80000000 0x20000000>;
+       };
+
+       regulators {
+               compatible = "simple-bus";
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               reg_usb_otg1_vbus: regulator@0 {
+                       compatible = "regulator-fixed";
+                       reg = <0>;
+                       regulator-name = "usb_otg1_vbus";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+                       gpio = <&gpio4 0 0>;
+                       enable-active-high;
+               };
+
+               reg_usb_otg2_vbus: regulator@1 {
+                       compatible = "regulator-fixed";
+                       reg = <1>;
+                       regulator-name = "usb_otg2_vbus";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+                       gpio = <&gpio4 2 0>;
+                       enable-active-high;
+               };
+
+               reg_1p8v: regulator@2 {
+                       compatible = "regulator-fixed";
+                       reg = <2>;
+                       regulator-name = "1P8V";
+                       regulator-min-microvolt = <1800000>;
+                       regulator-max-microvolt = <1800000>;
+               };
+       };
+
+       usdhc3_pwrseq: usdhc3_pwrseq {
+               compatible = "mmc-pwrseq-simple";
+               reset-gpios = <&gpio4 5 GPIO_ACTIVE_LOW>,       /* WL_REG_ON */
+                             <&gpio3 25 GPIO_ACTIVE_LOW>,      /* BT_REG_ON */
+                             <&gpio4 4 GPIO_ACTIVE_LOW>,       /* BT_WAKE */
+                             <&gpio4 6 GPIO_ACTIVE_LOW>;       /* BT_RST_N */
+       };
+};
+
+&uart1 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_uart1>;
+       status = "okay";
+};
+
+&uart2 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_uart2>;
+       fsl,uart-has-rtscts;
+       status = "okay";
+};
+
+&uart3 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_uart3>;
+       status = "okay";
+};
+
+&usbotg1 {
+       vbus-supply = <&reg_usb_otg1_vbus>;
+       dr_mode = "host";
+       disable-over-current;
+       status = "okay";
+};
+
+&usbotg2 {
+       vbus-supply = <&reg_usb_otg2_vbus>;
+       disable-over-current;
+       status = "okay";
+};
+
+&usdhc2 {
+       pinctrl-names = "default", "state_100mhz", "state_200mhz";
+       pinctrl-0 = <&pinctrl_usdhc2>;
+       pinctrl-1 = <&pinctrl_usdhc2_100mhz>;
+       pinctrl-2 = <&pinctrl_usdhc2_200mhz>;
+       bus-width = <8>;
+       non-removable;
+       status = "okay";
+};
+
+&usdhc3 {
+       pinctrl-names = "default", "state_100mhz", "state_200mhz";
+       pinctrl-0 = <&pinctrl_usdhc3>;
+       pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
+       pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
+       bus-width = <4>;
+       non-removable;
+       keep-power-in-suspend;
+       enable-sdio-wakeup;
+       mmc-pwrseq = <&usdhc3_pwrseq>;
+       status = "okay";
+};
+
+&iomuxc {
+       imx6sl-warp {
+               pinctrl_uart1: uart1grp {
+                       fsl,pins = <
+                               MX6SL_PAD_UART1_RXD__UART1_RX_DATA      0x41b0b1
+                               MX6SL_PAD_UART1_TXD__UART1_TX_DATA      0x41b0b1
+                       >;
+               };
+
+               pinctrl_uart2: uart2grp {
+                       fsl,pins = <
+                               MX6SL_PAD_EPDC_D12__UART2_RX_DATA       0x41b0b1
+                               MX6SL_PAD_EPDC_D13__UART2_TX_DATA       0x41b0b1
+                               MX6SL_PAD_EPDC_D14__UART2_RTS_B         0x4130B1
+                               MX6SL_PAD_EPDC_D15__UART2_CTS_B         0x4130B1
+                       >;
+               };
+
+               pinctrl_uart3: uart3grp {
+                       fsl,pins = <
+                               MX6SL_PAD_AUD_RXC__UART3_RX_DATA        0x41b0b1
+                               MX6SL_PAD_AUD_RXC__UART3_TX_DATA        0x41b0b1
+                       >;
+               };
+
+               pinctrl_usdhc2: usdhc2grp {
+                       fsl,pins = <
+                               MX6SL_PAD_SD2_CMD__SD2_CMD              0x417059
+                               MX6SL_PAD_SD2_CLK__SD2_CLK              0x410059
+                               MX6SL_PAD_SD2_DAT0__SD2_DATA0           0x417059
+                               MX6SL_PAD_SD2_DAT1__SD2_DATA1           0x417059
+                               MX6SL_PAD_SD2_DAT2__SD2_DATA2           0x417059
+                               MX6SL_PAD_SD2_DAT3__SD2_DATA3           0x417059
+                               MX6SL_PAD_SD2_DAT4__SD2_DATA4           0x417059
+                               MX6SL_PAD_SD2_DAT5__SD2_DATA5           0x417059
+                               MX6SL_PAD_SD2_DAT6__SD2_DATA6           0x417059
+                               MX6SL_PAD_SD2_DAT7__SD2_DATA7           0x417059
+                       >;
+               };
+
+               pinctrl_usdhc2_100mhz: usdhc2grp100mhz {
+                       fsl,pins = <
+                               MX6SL_PAD_SD2_CMD__SD2_CMD              0x4170b9
+                               MX6SL_PAD_SD2_CLK__SD2_CLK              0x4100b9
+                               MX6SL_PAD_SD2_DAT0__SD2_DATA0           0x4170b9
+                               MX6SL_PAD_SD2_DAT1__SD2_DATA1           0x4170b9
+                               MX6SL_PAD_SD2_DAT2__SD2_DATA2           0x4170b9
+                               MX6SL_PAD_SD2_DAT3__SD2_DATA3           0x4170b9
+                               MX6SL_PAD_SD2_DAT4__SD2_DATA4           0x4170b9
+                               MX6SL_PAD_SD2_DAT5__SD2_DATA5           0x4170b9
+                               MX6SL_PAD_SD2_DAT6__SD2_DATA6           0x4170b9
+                               MX6SL_PAD_SD2_DAT7__SD2_DATA7           0x4170b9
+                       >;
+               };
+
+               pinctrl_usdhc2_200mhz: usdhc2grp200mhz {
+                       fsl,pins = <
+                               MX6SL_PAD_SD2_CMD__SD2_CMD              0x4170f9
+                               MX6SL_PAD_SD2_CLK__SD2_CLK              0x4100f9
+                               MX6SL_PAD_SD2_DAT0__SD2_DATA0           0x4170f9
+                               MX6SL_PAD_SD2_DAT1__SD2_DATA1           0x4170f9
+                               MX6SL_PAD_SD2_DAT2__SD2_DATA2           0x4170f9
+                               MX6SL_PAD_SD2_DAT3__SD2_DATA3           0x4170f9
+                               MX6SL_PAD_SD2_DAT4__SD2_DATA4           0x4170f9
+                               MX6SL_PAD_SD2_DAT5__SD2_DATA5           0x4170f9
+                               MX6SL_PAD_SD2_DAT6__SD2_DATA6           0x4170f9
+                               MX6SL_PAD_SD2_DAT7__SD2_DATA7           0x4170f9
+                       >;
+               };
+
+               pinctrl_usdhc3: usdhc3grp {
+                       fsl,pins = <
+                               MX6SL_PAD_SD3_CMD__SD3_CMD              0x417059
+                               MX6SL_PAD_SD3_CLK__SD3_CLK              0x410059
+                               MX6SL_PAD_SD3_DAT0__SD3_DATA0           0x417059
+                               MX6SL_PAD_SD3_DAT1__SD3_DATA1           0x417059
+                               MX6SL_PAD_SD3_DAT2__SD3_DATA2           0x417059
+                               MX6SL_PAD_SD3_DAT3__SD3_DATA3           0x417059
+                       >;
+               };
+
+               pinctrl_usdhc3_100mhz: usdhc3grp100mhz {
+                       fsl,pins = <
+                               MX6SL_PAD_SD3_CMD__SD3_CMD              0x4170b9
+                               MX6SL_PAD_SD3_CLK__SD3_CLK              0x4100b9
+                               MX6SL_PAD_SD3_DAT0__SD3_DATA0           0x4170b9
+                               MX6SL_PAD_SD3_DAT1__SD3_DATA1           0x4170b9
+                               MX6SL_PAD_SD3_DAT2__SD3_DATA2           0x4170b9
+                               MX6SL_PAD_SD3_DAT3__SD3_DATA3           0x4170b9
+                       >;
+               };
+
+               pinctrl_usdhc3_200mhz: usdhc3grp200mhz {
+                       fsl,pins = <
+                               MX6SL_PAD_SD3_CMD__SD3_CMD              0x4170f9
+                               MX6SL_PAD_SD3_CLK__SD3_CLK              0x4100f9
+                               MX6SL_PAD_SD3_DAT0__SD3_DATA0           0x4170f9
+                               MX6SL_PAD_SD3_DAT1__SD3_DATA1           0x4170f9
+                               MX6SL_PAD_SD3_DAT2__SD3_DATA2           0x4170f9
+                               MX6SL_PAD_SD3_DAT3__SD3_DATA3           0x4170f9
+                       >;
+               };
+       };
+};
index 36ab8e054cee0a8ff5fcc1fb6938dc1d62a1e09f..a78e715e3982f7f821d01f386cc592e046e172f5 100644 (file)
@@ -72,6 +72,7 @@
                interrupt-controller;
                reg = <0x00a01000 0x1000>,
                      <0x00a00100 0x100>;
+               interrupt-parent = <&intc>;
        };
 
        clocks {
@@ -95,7 +96,7 @@
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "simple-bus";
-               interrupt-parent = <&intc>;
+               interrupt-parent = <&gpc>;
                ranges;
 
                ocram: sram@00900000 {
                                #size-cells = <1>;
                                ranges = <0 0x020cc000 0x4000>;
 
-                               snvs-rtc-lp@34 {
+                               snvs_rtc: snvs-rtc-lp@34 {
                                        compatible = "fsl,sec-v4.0-mon-rtc-lp";
                                        reg = <0x34 0x58>;
                                        interrupts = <0 19 IRQ_TYPE_LEVEL_HIGH>,
                        gpc: gpc@020dc000 {
                                compatible = "fsl,imx6sl-gpc", "fsl,imx6q-gpc";
                                reg = <0x020dc000 0x4000>;
+                               interrupt-controller;
+                               #interrupt-cells = <3>;
                                interrupts = <0 89 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-parent = <&intc>;
+                               pu-supply = <&reg_pu>;
+                               clocks = <&clks IMX6SL_CLK_GPU2D_OVG>,
+                                        <&clks IMX6SL_CLK_GPU2D_PODF>;
+                               #power-domain-cells = <1>;
                        };
 
                        gpr: iomuxc-gpr@020e0000 {
                                interrupts = <0 40 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks IMX6SL_CLK_USBOH3>;
                                fsl,usbmisc = <&usbmisc 2>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
diff --git a/arch/arm/boot/dts/imx6sx-sdb-reva.dts b/arch/arm/boot/dts/imx6sx-sdb-reva.dts
new file mode 100644 (file)
index 0000000..c76b87c
--- /dev/null
@@ -0,0 +1,143 @@
+/*
+ * Copyright (C) 2015 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include "imx6sx-sdb.dtsi"
+
+/ {
+       model = "Freescale i.MX6 SoloX SDB RevA Board";
+};
+
+&i2c1 {
+       clock-frequency = <100000>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_i2c1>;
+       status = "okay";
+
+       pmic: pfuze100@08 {
+               compatible = "fsl,pfuze100";
+               reg = <0x08>;
+
+               regulators {
+                       sw1a_reg: sw1ab {
+                               regulator-min-microvolt = <300000>;
+                               regulator-max-microvolt = <1875000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                               regulator-ramp-delay = <6250>;
+                       };
+
+                       sw1c_reg: sw1c {
+                               regulator-min-microvolt = <300000>;
+                               regulator-max-microvolt = <1875000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                               regulator-ramp-delay = <6250>;
+                       };
+
+                       sw2_reg: sw2 {
+                               regulator-min-microvolt = <800000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                       };
+
+                       sw3a_reg: sw3a {
+                               regulator-min-microvolt = <400000>;
+                               regulator-max-microvolt = <1975000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                       };
+
+                       sw3b_reg: sw3b {
+                               regulator-min-microvolt = <400000>;
+                               regulator-max-microvolt = <1975000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                       };
+
+                       sw4_reg: sw4 {
+                               regulator-min-microvolt = <800000>;
+                               regulator-max-microvolt = <3300000>;
+                       };
+
+                       swbst_reg: swbst {
+                               regulator-min-microvolt = <5000000>;
+                               regulator-max-microvolt = <5150000>;
+                       };
+
+                       snvs_reg: vsnvs {
+                               regulator-min-microvolt = <1000000>;
+                               regulator-max-microvolt = <3000000>;
+                               regulator-boot-on;
+                               regulator-always-on;
+                       };
+
+                       vref_reg: vrefddr {
+                               regulator-boot-on;
+                               regulator-always-on;
+                       };
+
+                       vgen1_reg: vgen1 {
+                               regulator-min-microvolt = <800000>;
+                               regulator-max-microvolt = <1550000>;
+                               regulator-always-on;
+                       };
+
+                       vgen2_reg: vgen2 {
+                               regulator-min-microvolt = <800000>;
+                               regulator-max-microvolt = <1550000>;
+                       };
+
+                       vgen3_reg: vgen3 {
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-always-on;
+                       };
+
+                       vgen4_reg: vgen4 {
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-always-on;
+                       };
+
+                       vgen5_reg: vgen5 {
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-always-on;
+                       };
+
+                       vgen6_reg: vgen6 {
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-always-on;
+                       };
+               };
+       };
+};
+
+&qspi2 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_qspi2>;
+       status = "okay";
+
+       flash0: s25fl128s@0 {
+               reg = <0>;
+               #address-cells = <1>;
+               #size-cells = <1>;
+               compatible = "spansion,s25fl128s";
+               spi-max-frequency = <66000000>;
+       };
+
+       flash1: s25fl128s@1 {
+               reg = <1>;
+               #address-cells = <1>;
+               #size-cells = <1>;
+               compatible = "spansion,s25fl128s";
+               spi-max-frequency = <66000000>;
+       };
+};
index 32f07d6b404239afd3c58c43ae2cb032478a37b5..0bfc4e7865b2995fcd009fe6abc9f83f5129cb5d 100644 (file)
 /*
- * Copyright (C) 2014 Freescale Semiconductor, Inc.
+ * Copyright (C) 2015 Freescale Semiconductor, Inc.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
 
-/dts-v1/;
-
-#include <dt-bindings/gpio/gpio.h>
-#include <dt-bindings/input/input.h>
-#include "imx6sx.dtsi"
+#include "imx6sx-sdb.dtsi"
 
 / {
-       model = "Freescale i.MX6 SoloX SDB Board";
-       compatible = "fsl,imx6sx-sdb", "fsl,imx6sx";
-
-       chosen {
-               stdout-path = &uart1;
-       };
-
-       memory {
-               reg = <0x80000000 0x40000000>;
-       };
-
-       backlight {
-               compatible = "pwm-backlight";
-               pwms = <&pwm3 0 5000000>;
-               brightness-levels = <0 4 8 16 32 64 128 255>;
-               default-brightness-level = <6>;
-       };
-
-       gpio-keys {
-               compatible = "gpio-keys";
-               pinctrl-names = "default";
-               pinctrl-0 = <&pinctrl_gpio_keys>;
-
-               volume-up {
-                       label = "Volume Up";
-                       gpios = <&gpio1 18 GPIO_ACTIVE_LOW>;
-                       linux,code = <KEY_VOLUMEUP>;
-               };
-
-               volume-down {
-                       label = "Volume Down";
-                       gpios = <&gpio1 19 GPIO_ACTIVE_LOW>;
-                       linux,code = <KEY_VOLUMEDOWN>;
-               };
-       };
-
-       regulators {
-               compatible = "simple-bus";
-               #address-cells = <1>;
-               #size-cells = <0>;
-
-               vcc_sd3: regulator@0 {
-                       compatible = "regulator-fixed";
-                       reg = <0>;
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&pinctrl_vcc_sd3>;
-                       regulator-name = "VCC_SD3";
-                       regulator-min-microvolt = <3000000>;
-                       regulator-max-microvolt = <3000000>;
-                       gpio = <&gpio2 11 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-               };
-
-               reg_usb_otg1_vbus: regulator@1 {
-                       compatible = "regulator-fixed";
-                       reg = <1>;
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&pinctrl_usb_otg1>;
-                       regulator-name = "usb_otg1_vbus";
-                       regulator-min-microvolt = <5000000>;
-                       regulator-max-microvolt = <5000000>;
-                       gpio = <&gpio1 9 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-               };
-
-               reg_usb_otg2_vbus: regulator@2 {
-                       compatible = "regulator-fixed";
-                       reg = <2>;
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&pinctrl_usb_otg2>;
-                       regulator-name = "usb_otg2_vbus";
-                       regulator-min-microvolt = <5000000>;
-                       regulator-max-microvolt = <5000000>;
-                       gpio = <&gpio1 12 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-               };
-
-               reg_psu_5v: regulator@3 {
-                       compatible = "regulator-fixed";
-                       reg = <3>;
-                       regulator-name = "PSU-5V0";
-                       regulator-min-microvolt = <5000000>;
-                       regulator-max-microvolt = <5000000>;
-               };
-
-               reg_lcd_3v3: regulator@4 {
-                       compatible = "regulator-fixed";
-                       reg = <4>;
-                       regulator-name = "lcd-3v3";
-                       gpio = <&gpio3 27 0>;
-                       enable-active-high;
-               };
-
-               reg_peri_3v3: regulator@5 {
-                       compatible = "regulator-fixed";
-                       reg = <5>;
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&pinctrl_peri_3v3>;
-                       regulator-name = "peri_3v3";
-                       regulator-min-microvolt = <3300000>;
-                       regulator-max-microvolt = <3300000>;
-                       gpios = <&gpio4 16 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-                       regulator-always-on;
-               };
-
-               reg_enet_3v3: regulator@6 {
-                       compatible = "regulator-fixed";
-                       reg = <6>;
-                       pinctrl-names = "default";
-                       pinctrl-0 = <&pinctrl_enet_3v3>;
-                       regulator-name = "enet_3v3";
-                       regulator-min-microvolt = <3300000>;
-                       regulator-max-microvolt = <3300000>;
-                       gpios = <&gpio2 6 GPIO_ACTIVE_LOW>;
-               };
-       };
-
-       sound {
-               compatible = "fsl,imx6sx-sdb-wm8962", "fsl,imx-audio-wm8962";
-               model = "wm8962-audio";
-               ssi-controller = <&ssi2>;
-               audio-codec = <&codec>;
-               audio-routing =
-                       "Headphone Jack", "HPOUTL",
-                       "Headphone Jack", "HPOUTR",
-                       "Ext Spk", "SPKOUTL",
-                       "Ext Spk", "SPKOUTR",
-                       "AMIC", "MICBIAS",
-                       "IN3R", "AMIC";
-               mux-int-port = <2>;
-               mux-ext-port = <6>;
-       };
-};
-
-&audmux {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_audmux>;
-       status = "okay";
+       model = "Freescale i.MX6 SoloX SDB RevB Board";
 };
 
-&fec1 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_enet1>;
-       phy-supply = <&reg_enet_3v3>;
-       phy-mode = "rgmii";
-       phy-handle = <&ethphy1>;
-       status = "okay";
-
-       mdio {
-               #address-cells = <1>;
-               #size-cells = <0>;
-
-               ethphy1: ethernet-phy@1 {
-                       reg = <1>;
-               };
-
-               ethphy2: ethernet-phy@2 {
-                       reg = <2>;
-               };
-       };
+&cpu0 {
+       operating-points = <
+               /* kHz    uV */
+               996000  1250000
+               792000  1175000
+               396000  1175000
+               >;
+       fsl,soc-operating-points = <
+               /* ARM kHz      SOC uV */
+               996000  1250000
+               792000  1175000
+               396000  1175000
+       >;
 };
 
-&fec2 {
+&i2c1 {
+       clock-frequency = <100000>;
        pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_enet2>;
-       phy-mode = "rgmii";
-       phy-handle = <&ethphy2>;
+       pinctrl-0 = <&pinctrl_i2c1>;
        status = "okay";
-};
-
-&i2c1 {
-        clock-frequency = <100000>;
-        pinctrl-names = "default";
-        pinctrl-0 = <&pinctrl_i2c1>;
-        status = "okay";
 
        pmic: pfuze100@08 {
-               compatible = "fsl,pfuze100";
+               compatible = "fsl,pfuze200";
                reg = <0x08>;
 
                regulators {
                                regulator-ramp-delay = <6250>;
                        };
 
-                       sw1c_reg: sw1c {
-                               regulator-min-microvolt = <300000>;
-                               regulator-max-microvolt = <1875000>;
-                               regulator-boot-on;
-                               regulator-always-on;
-                               regulator-ramp-delay = <6250>;
-                       };
-
                        sw2_reg: sw2 {
                                regulator-min-microvolt = <800000>;
                                regulator-max-microvolt = <3300000>;
                                regulator-always-on;
                        };
 
-                       sw4_reg: sw4 {
-                               regulator-min-microvolt = <800000>;
-                               regulator-max-microvolt = <3300000>;
-                       };
-
                        swbst_reg: swbst {
                                regulator-min-microvolt = <5000000>;
                                regulator-max-microvolt = <5150000>;
        };
 };
 
-&i2c4 {
-        clock-frequency = <100000>;
-        pinctrl-names = "default";
-        pinctrl-0 = <&pinctrl_i2c4>;
-        status = "okay";
-
-       codec: wm8962@1a {
-               compatible = "wlf,wm8962";
-               reg = <0x1a>;
-               clocks = <&clks IMX6SX_CLK_AUDIO>;
-               DCVDD-supply = <&vgen4_reg>;
-               DBVDD-supply = <&vgen4_reg>;
-               AVDD-supply = <&vgen4_reg>;
-               CPVDD-supply = <&vgen4_reg>;
-               MICVDD-supply = <&vgen3_reg>;
-               PLLVDD-supply = <&vgen4_reg>;
-               SPKVDD1-supply = <&reg_psu_5v>;
-               SPKVDD2-supply = <&reg_psu_5v>;
-       };
-};
-
-&lcdif1 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_lcd>;
-       lcd-supply = <&reg_lcd_3v3>;
-       display = <&display0>;
-       status = "okay";
-
-       display0: display0 {
-               bits-per-pixel = <16>;
-               bus-width = <24>;
-
-               display-timings {
-                       native-mode = <&timing0>;
-                       timing0: timing0 {
-                               clock-frequency = <33500000>;
-                               hactive = <800>;
-                               vactive = <480>;
-                               hback-porch = <89>;
-                               hfront-porch = <164>;
-                               vback-porch = <23>;
-                               vfront-porch = <10>;
-                               hsync-len = <10>;
-                               vsync-len = <10>;
-                               hsync-active = <0>;
-                               vsync-active = <0>;
-                               de-active = <1>;
-                               pixelclk-active = <0>;
-                       };
-               };
-       };
-};
-
-&pwm3 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_pwm3>;
-       status = "okay";
-};
-
-&snvs_poweroff {
-       status = "okay";
-};
-
 &qspi2 {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_qspi2>;
        status = "okay";
 
-       flash0: s25fl128s@0 {
-               reg = <0>;
+       flash0: n25q256a@0 {
                #address-cells = <1>;
                #size-cells = <1>;
-               compatible = "spansion,s25fl128s";
-               spi-max-frequency = <66000000>;
+               compatible = "micron,n25q256a";
+               spi-max-frequency = <29000000>;
+               reg = <0>;
        };
 
-       flash1: s25fl128s@1 {
-               reg = <1>;
+       flash1: n25q256a@1 {
                #address-cells = <1>;
                #size-cells = <1>;
-               compatible = "spansion,s25fl128s";
-               spi-max-frequency = <66000000>;
-       };
-};
-
-&ssi2 {
-       status = "okay";
-};
-
-&uart1 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_uart1>;
-       status = "okay";
-};
-
-&uart5 { /* for bluetooth */
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_uart5>;
-       fsl,uart-has-rtscts;
-       status = "okay";
-};
-
-&usbotg1 {
-       vbus-supply = <&reg_usb_otg1_vbus>;
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_usb_otg1_id>;
-       status = "okay";
-};
-
-&usbotg2 {
-       vbus-supply = <&reg_usb_otg2_vbus>;
-       dr_mode = "host";
-       status = "okay";
-};
-
-&usdhc2 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_usdhc2>;
-       non-removable;
-       no-1-8-v;
-       keep-power-in-suspend;
-       enable-sdio-wakeup;
-       status = "okay";
-};
-
-&usdhc3 {
-       pinctrl-names = "default", "state_100mhz", "state_200mhz";
-       pinctrl-0 = <&pinctrl_usdhc3>;
-       pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
-       pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
-       bus-width = <8>;
-       cd-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>;
-       wp-gpios = <&gpio2 15 GPIO_ACTIVE_HIGH>;
-       keep-power-in-suspend;
-       enable-sdio-wakeup;
-       vmmc-supply = <&vcc_sd3>;
-       status = "okay";
-};
-
-&usdhc4 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_usdhc4>;
-       cd-gpios = <&gpio6 21 GPIO_ACTIVE_HIGH>;
-       wp-gpios = <&gpio6 20 GPIO_ACTIVE_HIGH>;
-       status = "okay";
-};
-
-&iomuxc {
-       imx6x-sdb {
-               pinctrl_audmux: audmuxgrp {
-                       fsl,pins = <
-                               MX6SX_PAD_CSI_DATA00__AUDMUX_AUD6_TXC   0x130b0
-                               MX6SX_PAD_CSI_DATA01__AUDMUX_AUD6_TXFS  0x130b0
-                               MX6SX_PAD_CSI_HSYNC__AUDMUX_AUD6_TXD    0x120b0
-                               MX6SX_PAD_CSI_VSYNC__AUDMUX_AUD6_RXD    0x130b0
-                               MX6SX_PAD_CSI_PIXCLK__AUDMUX_MCLK       0x130b0
-                       >;
-               };
-
-               pinctrl_enet1: enet1grp {
-                       fsl,pins = <
-                               MX6SX_PAD_ENET1_MDIO__ENET1_MDIO        0xa0b1
-                               MX6SX_PAD_ENET1_MDC__ENET1_MDC          0xa0b1
-                               MX6SX_PAD_RGMII1_TXC__ENET1_RGMII_TXC   0xa0b1
-                               MX6SX_PAD_RGMII1_TD0__ENET1_TX_DATA_0   0xa0b1
-                               MX6SX_PAD_RGMII1_TD1__ENET1_TX_DATA_1   0xa0b1
-                               MX6SX_PAD_RGMII1_TD2__ENET1_TX_DATA_2   0xa0b1
-                               MX6SX_PAD_RGMII1_TD3__ENET1_TX_DATA_3   0xa0b1
-                               MX6SX_PAD_RGMII1_TX_CTL__ENET1_TX_EN    0xa0b1
-                               MX6SX_PAD_RGMII1_RXC__ENET1_RX_CLK      0x3081
-                               MX6SX_PAD_RGMII1_RD0__ENET1_RX_DATA_0   0x3081
-                               MX6SX_PAD_RGMII1_RD1__ENET1_RX_DATA_1   0x3081
-                               MX6SX_PAD_RGMII1_RD2__ENET1_RX_DATA_2   0x3081
-                               MX6SX_PAD_RGMII1_RD3__ENET1_RX_DATA_3   0x3081
-                               MX6SX_PAD_RGMII1_RX_CTL__ENET1_RX_EN    0x3081
-                               MX6SX_PAD_ENET2_RX_CLK__ENET2_REF_CLK_25M       0x91
-                       >;
-               };
-
-               pinctrl_enet_3v3: enet3v3grp {
-                       fsl,pins = <
-                               MX6SX_PAD_ENET2_COL__GPIO2_IO_6         0x80000000
-                       >;
-               };
-
-               pinctrl_enet2: enet2grp {
-                       fsl,pins = <
-                               MX6SX_PAD_RGMII2_TXC__ENET2_RGMII_TXC   0xa0b9
-                               MX6SX_PAD_RGMII2_TD0__ENET2_TX_DATA_0   0xa0b1
-                               MX6SX_PAD_RGMII2_TD1__ENET2_TX_DATA_1   0xa0b1
-                               MX6SX_PAD_RGMII2_TD2__ENET2_TX_DATA_2   0xa0b1
-                               MX6SX_PAD_RGMII2_TD3__ENET2_TX_DATA_3   0xa0b1
-                               MX6SX_PAD_RGMII2_TX_CTL__ENET2_TX_EN    0xa0b1
-                               MX6SX_PAD_RGMII2_RXC__ENET2_RX_CLK      0x3081
-                               MX6SX_PAD_RGMII2_RD0__ENET2_RX_DATA_0   0x3081
-                               MX6SX_PAD_RGMII2_RD1__ENET2_RX_DATA_1   0x3081
-                               MX6SX_PAD_RGMII2_RD2__ENET2_RX_DATA_2   0x3081
-                               MX6SX_PAD_RGMII2_RD3__ENET2_RX_DATA_3   0x3081
-                               MX6SX_PAD_RGMII2_RX_CTL__ENET2_RX_EN    0x3081
-                       >;
-               };
-
-               pinctrl_gpio_keys: gpio_keysgrp {
-                       fsl,pins = <
-                               MX6SX_PAD_CSI_DATA04__GPIO1_IO_18 0x17059
-                               MX6SX_PAD_CSI_DATA05__GPIO1_IO_19 0x17059
-                       >;
-               };
-
-               pinctrl_i2c1: i2c1grp {
-                       fsl,pins = <
-                               MX6SX_PAD_GPIO1_IO01__I2C1_SDA          0x4001b8b1
-                               MX6SX_PAD_GPIO1_IO00__I2C1_SCL          0x4001b8b1
-                       >;
-               };
-
-               pinctrl_i2c4: i2c4grp {
-                       fsl,pins = <
-                               MX6SX_PAD_CSI_DATA07__I2C4_SDA          0x4001b8b1
-                               MX6SX_PAD_CSI_DATA06__I2C4_SCL          0x4001b8b1
-                       >;
-               };
-
-               pinctrl_lcd: lcdgrp {
-                       fsl,pins = <
-                               MX6SX_PAD_LCD1_DATA00__LCDIF1_DATA_0 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA01__LCDIF1_DATA_1 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA02__LCDIF1_DATA_2 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA03__LCDIF1_DATA_3 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA04__LCDIF1_DATA_4 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA05__LCDIF1_DATA_5 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA06__LCDIF1_DATA_6 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA07__LCDIF1_DATA_7 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA08__LCDIF1_DATA_8 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA09__LCDIF1_DATA_9 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA10__LCDIF1_DATA_10 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA11__LCDIF1_DATA_11 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA12__LCDIF1_DATA_12 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA13__LCDIF1_DATA_13 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA14__LCDIF1_DATA_14 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA15__LCDIF1_DATA_15 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA16__LCDIF1_DATA_16 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA17__LCDIF1_DATA_17 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA18__LCDIF1_DATA_18 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA19__LCDIF1_DATA_19 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA20__LCDIF1_DATA_20 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA21__LCDIF1_DATA_21 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA22__LCDIF1_DATA_22 0x4001b0b0
-                               MX6SX_PAD_LCD1_DATA23__LCDIF1_DATA_23 0x4001b0b0
-                               MX6SX_PAD_LCD1_CLK__LCDIF1_CLK  0x4001b0b0
-                               MX6SX_PAD_LCD1_ENABLE__LCDIF1_ENABLE 0x4001b0b0
-                               MX6SX_PAD_LCD1_VSYNC__LCDIF1_VSYNC 0x4001b0b0
-                               MX6SX_PAD_LCD1_HSYNC__LCDIF1_HSYNC 0x4001b0b0
-                               MX6SX_PAD_LCD1_RESET__GPIO3_IO_27 0x4001b0b0
-                       >;
-               };
-
-               pinctrl_peri_3v3: peri3v3grp {
-                       fsl,pins = <
-                               MX6SX_PAD_QSPI1A_DATA0__GPIO4_IO_16     0x80000000
-                       >;
-               };
-
-               pinctrl_pwm3: pwm3grp-1 {
-                       fsl,pins = <
-                               MX6SX_PAD_SD1_DATA2__PWM3_OUT 0x110b0
-                       >;
-               };
-
-               pinctrl_qspi2: qspi2grp {
-                       fsl,pins = <
-                               MX6SX_PAD_NAND_WP_B__QSPI2_A_DATA_0     0x70f1
-                               MX6SX_PAD_NAND_READY_B__QSPI2_A_DATA_1  0x70f1
-                               MX6SX_PAD_NAND_CE0_B__QSPI2_A_DATA_2    0x70f1
-                               MX6SX_PAD_NAND_CE1_B__QSPI2_A_DATA_3    0x70f1
-                               MX6SX_PAD_NAND_CLE__QSPI2_A_SCLK        0x70f1
-                               MX6SX_PAD_NAND_ALE__QSPI2_A_SS0_B       0x70f1
-                               MX6SX_PAD_NAND_DATA01__QSPI2_B_DATA_0   0x70f1
-                               MX6SX_PAD_NAND_DATA00__QSPI2_B_DATA_1   0x70f1
-                               MX6SX_PAD_NAND_WE_B__QSPI2_B_DATA_2     0x70f1
-                               MX6SX_PAD_NAND_RE_B__QSPI2_B_DATA_3     0x70f1
-                               MX6SX_PAD_NAND_DATA02__QSPI2_B_SCLK     0x70f1
-                               MX6SX_PAD_NAND_DATA03__QSPI2_B_SS0_B    0x70f1
-                       >;
-               };
-
-               pinctrl_vcc_sd3: vccsd3grp {
-                       fsl,pins = <
-                               MX6SX_PAD_KEY_COL1__GPIO2_IO_11         0x17059
-                       >;
-               };
-
-               pinctrl_uart1: uart1grp {
-                       fsl,pins = <
-                               MX6SX_PAD_GPIO1_IO04__UART1_TX          0x1b0b1
-                               MX6SX_PAD_GPIO1_IO05__UART1_RX          0x1b0b1
-                       >;
-               };
-
-               pinctrl_uart5: uart5grp {
-                       fsl,pins = <
-                               MX6SX_PAD_KEY_ROW3__UART5_RX            0x1b0b1
-                               MX6SX_PAD_KEY_COL3__UART5_TX            0x1b0b1
-                               MX6SX_PAD_KEY_ROW2__UART5_CTS_B         0x1b0b1
-                               MX6SX_PAD_KEY_COL2__UART5_RTS_B         0x1b0b1
-                       >;
-               };
-
-               pinctrl_usb_otg1: usbotg1grp {
-                       fsl,pins = <
-                               MX6SX_PAD_GPIO1_IO09__GPIO1_IO_9        0x10b0
-                       >;
-               };
-
-               pinctrl_usb_otg1_id: usbotg1idgrp {
-                       fsl,pins = <
-                               MX6SX_PAD_GPIO1_IO10__ANATOP_OTG1_ID    0x17059
-                       >;
-               };
-
-               pinctrl_usb_otg2: usbot2ggrp {
-                       fsl,pins = <
-                               MX6SX_PAD_GPIO1_IO12__GPIO1_IO_12       0x10b0
-                       >;
-               };
-
-               pinctrl_usdhc2: usdhc2grp {
-                       fsl,pins = <
-                               MX6SX_PAD_SD2_CMD__USDHC2_CMD           0x17059
-                               MX6SX_PAD_SD2_CLK__USDHC2_CLK           0x10059
-                               MX6SX_PAD_SD2_DATA0__USDHC2_DATA0       0x17059
-                               MX6SX_PAD_SD2_DATA1__USDHC2_DATA1       0x17059
-                               MX6SX_PAD_SD2_DATA2__USDHC2_DATA2       0x17059
-                               MX6SX_PAD_SD2_DATA3__USDHC2_DATA3       0x17059
-                       >;
-               };
-
-               pinctrl_usdhc3: usdhc3grp {
-                       fsl,pins = <
-                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x17059
-                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x10059
-                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x17059
-                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x17059
-                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x17059
-                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x17059
-                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x17059
-                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x17059
-                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x17059
-                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x17059
-                               MX6SX_PAD_KEY_COL0__GPIO2_IO_10         0x17059 /* CD */
-                               MX6SX_PAD_KEY_ROW0__GPIO2_IO_15         0x17059 /* WP */
-                       >;
-               };
-
-               pinctrl_usdhc3_100mhz: usdhc3grp-100mhz {
-                       fsl,pins = <
-                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x170b9
-                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x100b9
-                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x170b9
-                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x170b9
-                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x170b9
-                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x170b9
-                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x170b9
-                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x170b9
-                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x170b9
-                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x170b9
-                       >;
-               };
-
-               pinctrl_usdhc3_200mhz: usdhc3grp-200mhz {
-                       fsl,pins = <
-                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x170f9
-                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x100f9
-                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x170f9
-                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x170f9
-                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x170f9
-                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x170f9
-                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x170f9
-                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x170f9
-                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x170f9
-                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x170f9
-                       >;
-               };
-
-               pinctrl_usdhc4: usdhc4grp {
-                       fsl,pins = <
-                               MX6SX_PAD_SD4_CMD__USDHC4_CMD           0x17059
-                               MX6SX_PAD_SD4_CLK__USDHC4_CLK           0x10059
-                               MX6SX_PAD_SD4_DATA0__USDHC4_DATA0       0x17059
-                               MX6SX_PAD_SD4_DATA1__USDHC4_DATA1       0x17059
-                               MX6SX_PAD_SD4_DATA2__USDHC4_DATA2       0x17059
-                               MX6SX_PAD_SD4_DATA3__USDHC4_DATA3       0x17059
-                               MX6SX_PAD_SD4_DATA7__GPIO6_IO_21        0x17059 /* CD */
-                               MX6SX_PAD_SD4_DATA6__GPIO6_IO_20        0x17059 /* WP */
-                       >;
-               };
+               compatible = "micron,n25q256a";
+               spi-max-frequency = <29000000>;
+               reg = <1>;
        };
 };
diff --git a/arch/arm/boot/dts/imx6sx-sdb.dtsi b/arch/arm/boot/dts/imx6sx-sdb.dtsi
new file mode 100644 (file)
index 0000000..cef04ce
--- /dev/null
@@ -0,0 +1,562 @@
+/*
+ * Copyright (C) 2014 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+/dts-v1/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include "imx6sx.dtsi"
+
+/ {
+       model = "Freescale i.MX6 SoloX SDB Board";
+       compatible = "fsl,imx6sx-sdb", "fsl,imx6sx";
+
+       chosen {
+               stdout-path = &uart1;
+       };
+
+       memory {
+               reg = <0x80000000 0x40000000>;
+       };
+
+       backlight {
+               compatible = "pwm-backlight";
+               pwms = <&pwm3 0 5000000>;
+               brightness-levels = <0 4 8 16 32 64 128 255>;
+               default-brightness-level = <6>;
+       };
+
+       gpio-keys {
+               compatible = "gpio-keys";
+               pinctrl-names = "default";
+               pinctrl-0 = <&pinctrl_gpio_keys>;
+
+               volume-up {
+                       label = "Volume Up";
+                       gpios = <&gpio1 18 GPIO_ACTIVE_LOW>;
+                       linux,code = <KEY_VOLUMEUP>;
+               };
+
+               volume-down {
+                       label = "Volume Down";
+                       gpios = <&gpio1 19 GPIO_ACTIVE_LOW>;
+                       linux,code = <KEY_VOLUMEDOWN>;
+               };
+       };
+
+       regulators {
+               compatible = "simple-bus";
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               vcc_sd3: regulator@0 {
+                       compatible = "regulator-fixed";
+                       reg = <0>;
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&pinctrl_vcc_sd3>;
+                       regulator-name = "VCC_SD3";
+                       regulator-min-microvolt = <3000000>;
+                       regulator-max-microvolt = <3000000>;
+                       gpio = <&gpio2 11 GPIO_ACTIVE_HIGH>;
+                       enable-active-high;
+               };
+
+               reg_usb_otg1_vbus: regulator@1 {
+                       compatible = "regulator-fixed";
+                       reg = <1>;
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&pinctrl_usb_otg1>;
+                       regulator-name = "usb_otg1_vbus";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+                       gpio = <&gpio1 9 GPIO_ACTIVE_HIGH>;
+                       enable-active-high;
+               };
+
+               reg_usb_otg2_vbus: regulator@2 {
+                       compatible = "regulator-fixed";
+                       reg = <2>;
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&pinctrl_usb_otg2>;
+                       regulator-name = "usb_otg2_vbus";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+                       gpio = <&gpio1 12 GPIO_ACTIVE_HIGH>;
+                       enable-active-high;
+               };
+
+               reg_psu_5v: regulator@3 {
+                       compatible = "regulator-fixed";
+                       reg = <3>;
+                       regulator-name = "PSU-5V0";
+                       regulator-min-microvolt = <5000000>;
+                       regulator-max-microvolt = <5000000>;
+               };
+
+               reg_lcd_3v3: regulator@4 {
+                       compatible = "regulator-fixed";
+                       reg = <4>;
+                       regulator-name = "lcd-3v3";
+                       gpio = <&gpio3 27 0>;
+                       enable-active-high;
+               };
+
+               reg_peri_3v3: regulator@5 {
+                       compatible = "regulator-fixed";
+                       reg = <5>;
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&pinctrl_peri_3v3>;
+                       regulator-name = "peri_3v3";
+                       regulator-min-microvolt = <3300000>;
+                       regulator-max-microvolt = <3300000>;
+                       gpios = <&gpio4 16 GPIO_ACTIVE_HIGH>;
+                       enable-active-high;
+                       regulator-always-on;
+               };
+
+               reg_enet_3v3: regulator@6 {
+                       compatible = "regulator-fixed";
+                       reg = <6>;
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&pinctrl_enet_3v3>;
+                       regulator-name = "enet_3v3";
+                       regulator-min-microvolt = <3300000>;
+                       regulator-max-microvolt = <3300000>;
+                       gpios = <&gpio2 6 GPIO_ACTIVE_LOW>;
+               };
+       };
+
+       sound {
+               compatible = "fsl,imx6sx-sdb-wm8962", "fsl,imx-audio-wm8962";
+               model = "wm8962-audio";
+               ssi-controller = <&ssi2>;
+               audio-codec = <&codec>;
+               audio-routing =
+                       "Headphone Jack", "HPOUTL",
+                       "Headphone Jack", "HPOUTR",
+                       "Ext Spk", "SPKOUTL",
+                       "Ext Spk", "SPKOUTR",
+                       "AMIC", "MICBIAS",
+                       "IN3R", "AMIC";
+               mux-int-port = <2>;
+               mux-ext-port = <6>;
+       };
+};
+
+&audmux {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_audmux>;
+       status = "okay";
+};
+
+&fec1 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_enet1>;
+       phy-supply = <&reg_enet_3v3>;
+       phy-mode = "rgmii";
+       phy-handle = <&ethphy1>;
+       status = "okay";
+
+       mdio {
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               ethphy1: ethernet-phy@1 {
+                       reg = <1>;
+               };
+
+               ethphy2: ethernet-phy@2 {
+                       reg = <2>;
+               };
+       };
+};
+
+&fec2 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_enet2>;
+       phy-mode = "rgmii";
+       phy-handle = <&ethphy2>;
+       status = "okay";
+};
+
+&i2c4 {
+        clock-frequency = <100000>;
+        pinctrl-names = "default";
+        pinctrl-0 = <&pinctrl_i2c4>;
+        status = "okay";
+
+       codec: wm8962@1a {
+               compatible = "wlf,wm8962";
+               reg = <0x1a>;
+               clocks = <&clks IMX6SX_CLK_AUDIO>;
+               DCVDD-supply = <&vgen4_reg>;
+               DBVDD-supply = <&vgen4_reg>;
+               AVDD-supply = <&vgen4_reg>;
+               CPVDD-supply = <&vgen4_reg>;
+               MICVDD-supply = <&vgen3_reg>;
+               PLLVDD-supply = <&vgen4_reg>;
+               SPKVDD1-supply = <&reg_psu_5v>;
+               SPKVDD2-supply = <&reg_psu_5v>;
+       };
+};
+
+&lcdif1 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lcd>;
+       lcd-supply = <&reg_lcd_3v3>;
+       display = <&display0>;
+       status = "okay";
+
+       display0: display0 {
+               bits-per-pixel = <16>;
+               bus-width = <24>;
+
+               display-timings {
+                       native-mode = <&timing0>;
+                       timing0: timing0 {
+                               clock-frequency = <33500000>;
+                               hactive = <800>;
+                               vactive = <480>;
+                               hback-porch = <89>;
+                               hfront-porch = <164>;
+                               vback-porch = <23>;
+                               vfront-porch = <10>;
+                               hsync-len = <10>;
+                               vsync-len = <10>;
+                               hsync-active = <0>;
+                               vsync-active = <0>;
+                               de-active = <1>;
+                               pixelclk-active = <0>;
+                       };
+               };
+       };
+};
+
+&pwm3 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_pwm3>;
+       status = "okay";
+};
+
+&snvs_poweroff {
+       status = "okay";
+};
+
+&ssi2 {
+       status = "okay";
+};
+
+&uart1 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_uart1>;
+       status = "okay";
+};
+
+&uart5 { /* for bluetooth */
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_uart5>;
+       fsl,uart-has-rtscts;
+       status = "okay";
+};
+
+&usbotg1 {
+       vbus-supply = <&reg_usb_otg1_vbus>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_usb_otg1_id>;
+       status = "okay";
+};
+
+&usbotg2 {
+       vbus-supply = <&reg_usb_otg2_vbus>;
+       dr_mode = "host";
+       status = "okay";
+};
+
+&usdhc2 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_usdhc2>;
+       non-removable;
+       no-1-8-v;
+       keep-power-in-suspend;
+       enable-sdio-wakeup;
+       status = "okay";
+};
+
+&usdhc3 {
+       pinctrl-names = "default", "state_100mhz", "state_200mhz";
+       pinctrl-0 = <&pinctrl_usdhc3>;
+       pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
+       pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
+       bus-width = <8>;
+       cd-gpios = <&gpio2 10 GPIO_ACTIVE_HIGH>;
+       wp-gpios = <&gpio2 15 GPIO_ACTIVE_HIGH>;
+       keep-power-in-suspend;
+       enable-sdio-wakeup;
+       vmmc-supply = <&vcc_sd3>;
+       status = "okay";
+};
+
+&usdhc4 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_usdhc4>;
+       cd-gpios = <&gpio6 21 GPIO_ACTIVE_HIGH>;
+       wp-gpios = <&gpio6 20 GPIO_ACTIVE_HIGH>;
+       status = "okay";
+};
+
+&iomuxc {
+       imx6x-sdb {
+               pinctrl_audmux: audmuxgrp {
+                       fsl,pins = <
+                               MX6SX_PAD_CSI_DATA00__AUDMUX_AUD6_TXC   0x130b0
+                               MX6SX_PAD_CSI_DATA01__AUDMUX_AUD6_TXFS  0x130b0
+                               MX6SX_PAD_CSI_HSYNC__AUDMUX_AUD6_TXD    0x120b0
+                               MX6SX_PAD_CSI_VSYNC__AUDMUX_AUD6_RXD    0x130b0
+                               MX6SX_PAD_CSI_PIXCLK__AUDMUX_MCLK       0x130b0
+                       >;
+               };
+
+               pinctrl_enet1: enet1grp {
+                       fsl,pins = <
+                               MX6SX_PAD_ENET1_MDIO__ENET1_MDIO        0xa0b1
+                               MX6SX_PAD_ENET1_MDC__ENET1_MDC          0xa0b1
+                               MX6SX_PAD_RGMII1_TXC__ENET1_RGMII_TXC   0xa0b1
+                               MX6SX_PAD_RGMII1_TD0__ENET1_TX_DATA_0   0xa0b1
+                               MX6SX_PAD_RGMII1_TD1__ENET1_TX_DATA_1   0xa0b1
+                               MX6SX_PAD_RGMII1_TD2__ENET1_TX_DATA_2   0xa0b1
+                               MX6SX_PAD_RGMII1_TD3__ENET1_TX_DATA_3   0xa0b1
+                               MX6SX_PAD_RGMII1_TX_CTL__ENET1_TX_EN    0xa0b1
+                               MX6SX_PAD_RGMII1_RXC__ENET1_RX_CLK      0x3081
+                               MX6SX_PAD_RGMII1_RD0__ENET1_RX_DATA_0   0x3081
+                               MX6SX_PAD_RGMII1_RD1__ENET1_RX_DATA_1   0x3081
+                               MX6SX_PAD_RGMII1_RD2__ENET1_RX_DATA_2   0x3081
+                               MX6SX_PAD_RGMII1_RD3__ENET1_RX_DATA_3   0x3081
+                               MX6SX_PAD_RGMII1_RX_CTL__ENET1_RX_EN    0x3081
+                               MX6SX_PAD_ENET2_RX_CLK__ENET2_REF_CLK_25M       0x91
+                       >;
+               };
+
+               pinctrl_enet_3v3: enet3v3grp {
+                       fsl,pins = <
+                               MX6SX_PAD_ENET2_COL__GPIO2_IO_6         0x80000000
+                       >;
+               };
+
+               pinctrl_enet2: enet2grp {
+                       fsl,pins = <
+                               MX6SX_PAD_RGMII2_TXC__ENET2_RGMII_TXC   0xa0b9
+                               MX6SX_PAD_RGMII2_TD0__ENET2_TX_DATA_0   0xa0b1
+                               MX6SX_PAD_RGMII2_TD1__ENET2_TX_DATA_1   0xa0b1
+                               MX6SX_PAD_RGMII2_TD2__ENET2_TX_DATA_2   0xa0b1
+                               MX6SX_PAD_RGMII2_TD3__ENET2_TX_DATA_3   0xa0b1
+                               MX6SX_PAD_RGMII2_TX_CTL__ENET2_TX_EN    0xa0b1
+                               MX6SX_PAD_RGMII2_RXC__ENET2_RX_CLK      0x3081
+                               MX6SX_PAD_RGMII2_RD0__ENET2_RX_DATA_0   0x3081
+                               MX6SX_PAD_RGMII2_RD1__ENET2_RX_DATA_1   0x3081
+                               MX6SX_PAD_RGMII2_RD2__ENET2_RX_DATA_2   0x3081
+                               MX6SX_PAD_RGMII2_RD3__ENET2_RX_DATA_3   0x3081
+                               MX6SX_PAD_RGMII2_RX_CTL__ENET2_RX_EN    0x3081
+                       >;
+               };
+
+               pinctrl_gpio_keys: gpio_keysgrp {
+                       fsl,pins = <
+                               MX6SX_PAD_CSI_DATA04__GPIO1_IO_18 0x17059
+                               MX6SX_PAD_CSI_DATA05__GPIO1_IO_19 0x17059
+                       >;
+               };
+
+               pinctrl_i2c1: i2c1grp {
+                       fsl,pins = <
+                               MX6SX_PAD_GPIO1_IO01__I2C1_SDA          0x4001b8b1
+                               MX6SX_PAD_GPIO1_IO00__I2C1_SCL          0x4001b8b1
+                       >;
+               };
+
+               pinctrl_i2c4: i2c4grp {
+                       fsl,pins = <
+                               MX6SX_PAD_CSI_DATA07__I2C4_SDA          0x4001b8b1
+                               MX6SX_PAD_CSI_DATA06__I2C4_SCL          0x4001b8b1
+                       >;
+               };
+
+               pinctrl_lcd: lcdgrp {
+                       fsl,pins = <
+                               MX6SX_PAD_LCD1_DATA00__LCDIF1_DATA_0 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA01__LCDIF1_DATA_1 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA02__LCDIF1_DATA_2 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA03__LCDIF1_DATA_3 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA04__LCDIF1_DATA_4 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA05__LCDIF1_DATA_5 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA06__LCDIF1_DATA_6 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA07__LCDIF1_DATA_7 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA08__LCDIF1_DATA_8 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA09__LCDIF1_DATA_9 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA10__LCDIF1_DATA_10 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA11__LCDIF1_DATA_11 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA12__LCDIF1_DATA_12 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA13__LCDIF1_DATA_13 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA14__LCDIF1_DATA_14 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA15__LCDIF1_DATA_15 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA16__LCDIF1_DATA_16 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA17__LCDIF1_DATA_17 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA18__LCDIF1_DATA_18 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA19__LCDIF1_DATA_19 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA20__LCDIF1_DATA_20 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA21__LCDIF1_DATA_21 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA22__LCDIF1_DATA_22 0x4001b0b0
+                               MX6SX_PAD_LCD1_DATA23__LCDIF1_DATA_23 0x4001b0b0
+                               MX6SX_PAD_LCD1_CLK__LCDIF1_CLK  0x4001b0b0
+                               MX6SX_PAD_LCD1_ENABLE__LCDIF1_ENABLE 0x4001b0b0
+                               MX6SX_PAD_LCD1_VSYNC__LCDIF1_VSYNC 0x4001b0b0
+                               MX6SX_PAD_LCD1_HSYNC__LCDIF1_HSYNC 0x4001b0b0
+                               MX6SX_PAD_LCD1_RESET__GPIO3_IO_27 0x4001b0b0
+                       >;
+               };
+
+               pinctrl_peri_3v3: peri3v3grp {
+                       fsl,pins = <
+                               MX6SX_PAD_QSPI1A_DATA0__GPIO4_IO_16     0x80000000
+                       >;
+               };
+
+               pinctrl_pwm3: pwm3grp-1 {
+                       fsl,pins = <
+                               MX6SX_PAD_SD1_DATA2__PWM3_OUT 0x110b0
+                       >;
+               };
+
+               pinctrl_qspi2: qspi2grp {
+                       fsl,pins = <
+                               MX6SX_PAD_NAND_WP_B__QSPI2_A_DATA_0     0x70f1
+                               MX6SX_PAD_NAND_READY_B__QSPI2_A_DATA_1  0x70f1
+                               MX6SX_PAD_NAND_CE0_B__QSPI2_A_DATA_2    0x70f1
+                               MX6SX_PAD_NAND_CE1_B__QSPI2_A_DATA_3    0x70f1
+                               MX6SX_PAD_NAND_CLE__QSPI2_A_SCLK        0x70f1
+                               MX6SX_PAD_NAND_ALE__QSPI2_A_SS0_B       0x70f1
+                               MX6SX_PAD_NAND_DATA01__QSPI2_B_DATA_0   0x70f1
+                               MX6SX_PAD_NAND_DATA00__QSPI2_B_DATA_1   0x70f1
+                               MX6SX_PAD_NAND_WE_B__QSPI2_B_DATA_2     0x70f1
+                               MX6SX_PAD_NAND_RE_B__QSPI2_B_DATA_3     0x70f1
+                               MX6SX_PAD_NAND_DATA02__QSPI2_B_SCLK     0x70f1
+                               MX6SX_PAD_NAND_DATA03__QSPI2_B_SS0_B    0x70f1
+                       >;
+               };
+
+               pinctrl_vcc_sd3: vccsd3grp {
+                       fsl,pins = <
+                               MX6SX_PAD_KEY_COL1__GPIO2_IO_11         0x17059
+                       >;
+               };
+
+               pinctrl_uart1: uart1grp {
+                       fsl,pins = <
+                               MX6SX_PAD_GPIO1_IO04__UART1_TX          0x1b0b1
+                               MX6SX_PAD_GPIO1_IO05__UART1_RX          0x1b0b1
+                       >;
+               };
+
+               pinctrl_uart5: uart5grp {
+                       fsl,pins = <
+                               MX6SX_PAD_KEY_ROW3__UART5_RX            0x1b0b1
+                               MX6SX_PAD_KEY_COL3__UART5_TX            0x1b0b1
+                               MX6SX_PAD_KEY_ROW2__UART5_CTS_B         0x1b0b1
+                               MX6SX_PAD_KEY_COL2__UART5_RTS_B         0x1b0b1
+                       >;
+               };
+
+               pinctrl_usb_otg1: usbotg1grp {
+                       fsl,pins = <
+                               MX6SX_PAD_GPIO1_IO09__GPIO1_IO_9        0x10b0
+                       >;
+               };
+
+               pinctrl_usb_otg1_id: usbotg1idgrp {
+                       fsl,pins = <
+                               MX6SX_PAD_GPIO1_IO10__ANATOP_OTG1_ID    0x17059
+                       >;
+               };
+
+               pinctrl_usb_otg2: usbot2ggrp {
+                       fsl,pins = <
+                               MX6SX_PAD_GPIO1_IO12__GPIO1_IO_12       0x10b0
+                       >;
+               };
+
+               pinctrl_usdhc2: usdhc2grp {
+                       fsl,pins = <
+                               MX6SX_PAD_SD2_CMD__USDHC2_CMD           0x17059
+                               MX6SX_PAD_SD2_CLK__USDHC2_CLK           0x10059
+                               MX6SX_PAD_SD2_DATA0__USDHC2_DATA0       0x17059
+                               MX6SX_PAD_SD2_DATA1__USDHC2_DATA1       0x17059
+                               MX6SX_PAD_SD2_DATA2__USDHC2_DATA2       0x17059
+                               MX6SX_PAD_SD2_DATA3__USDHC2_DATA3       0x17059
+                       >;
+               };
+
+               pinctrl_usdhc3: usdhc3grp {
+                       fsl,pins = <
+                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x17059
+                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x10059
+                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x17059
+                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x17059
+                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x17059
+                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x17059
+                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x17059
+                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x17059
+                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x17059
+                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x17059
+                               MX6SX_PAD_KEY_COL0__GPIO2_IO_10         0x17059 /* CD */
+                               MX6SX_PAD_KEY_ROW0__GPIO2_IO_15         0x17059 /* WP */
+                       >;
+               };
+
+               pinctrl_usdhc3_100mhz: usdhc3grp-100mhz {
+                       fsl,pins = <
+                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x170b9
+                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x100b9
+                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x170b9
+                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x170b9
+                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x170b9
+                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x170b9
+                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x170b9
+                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x170b9
+                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x170b9
+                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x170b9
+                       >;
+               };
+
+               pinctrl_usdhc3_200mhz: usdhc3grp-200mhz {
+                       fsl,pins = <
+                               MX6SX_PAD_SD3_CMD__USDHC3_CMD           0x170f9
+                               MX6SX_PAD_SD3_CLK__USDHC3_CLK           0x100f9
+                               MX6SX_PAD_SD3_DATA0__USDHC3_DATA0       0x170f9
+                               MX6SX_PAD_SD3_DATA1__USDHC3_DATA1       0x170f9
+                               MX6SX_PAD_SD3_DATA2__USDHC3_DATA2       0x170f9
+                               MX6SX_PAD_SD3_DATA3__USDHC3_DATA3       0x170f9
+                               MX6SX_PAD_SD3_DATA4__USDHC3_DATA4       0x170f9
+                               MX6SX_PAD_SD3_DATA5__USDHC3_DATA5       0x170f9
+                               MX6SX_PAD_SD3_DATA6__USDHC3_DATA6       0x170f9
+                               MX6SX_PAD_SD3_DATA7__USDHC3_DATA7       0x170f9
+                       >;
+               };
+
+               pinctrl_usdhc4: usdhc4grp {
+                       fsl,pins = <
+                               MX6SX_PAD_SD4_CMD__USDHC4_CMD           0x17059
+                               MX6SX_PAD_SD4_CLK__USDHC4_CLK           0x10059
+                               MX6SX_PAD_SD4_DATA0__USDHC4_DATA0       0x17059
+                               MX6SX_PAD_SD4_DATA1__USDHC4_DATA1       0x17059
+                               MX6SX_PAD_SD4_DATA2__USDHC4_DATA2       0x17059
+                               MX6SX_PAD_SD4_DATA3__USDHC4_DATA3       0x17059
+                               MX6SX_PAD_SD4_DATA7__GPIO6_IO_21        0x17059 /* CD */
+                               MX6SX_PAD_SD4_DATA6__GPIO6_IO_20        0x17059 /* WP */
+                       >;
+               };
+       };
+};
index 7a24fee1e7aecf7bc16df8c241e42a5ba5e5e561..708175d59b9c31085877da68ad378765fe701369 100644 (file)
@@ -88,6 +88,7 @@
                interrupt-controller;
                reg = <0x00a01000 0x1000>,
                      <0x00a00100 0x100>;
+               interrupt-parent = <&intc>;
        };
 
        clocks {
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "simple-bus";
-               interrupt-parent = <&intc>;
+               interrupt-parent = <&gpc>;
                ranges;
 
                pmu {
                                #size-cells = <1>;
                                ranges = <0 0x020cc000 0x4000>;
 
-                               snvs-rtc-lp@34 {
+                               snvs_rtc: snvs-rtc-lp@34 {
                                        compatible = "fsl,sec-v4.0-mon-rtc-lp";
                                        reg = <0x34 0x58>;
                                        interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>, <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
                        gpc: gpc@020dc000 {
                                compatible = "fsl,imx6sx-gpc", "fsl,imx6q-gpc";
                                reg = <0x020dc000 0x4000>;
+                               interrupt-controller;
+                               #interrupt-cells = <3>;
                                interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-parent = <&intc>;
                        };
 
                        iomuxc: iomuxc@020e0000 {
                                fsl,usbmisc = <&usbmisc 2>;
                                phy_type = "hsic";
                                fsl,anatop = <&anatop>;
+                               dr_mode = "host";
                                status = "disabled";
                        };
 
index e2b2e93d7b6160f364bcb4832cc593c09f9627ac..5b9a376cc31eee01e38a0cbd8a5cb16b8bf6c04f 100644 (file)
        compatible = "ti,omap2420", "ti,omap2";
 
        ocp {
-               prcm: prcm@48008000 {
-                       compatible = "ti,omap2-prcm";
-                       reg = <0x48008000 0x1000>;
+               l4: l4@48000000 {
+                       compatible = "ti,omap2-l4", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x48000000 0x100000>;
 
-                       prcm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+                       prcm: prcm@8000 {
+                               compatible = "ti,omap2-prcm";
+                               reg = <0x8000 0x1000>;
 
-                       prcm_clockdomains: clockdomains {
-                       };
-               };
+                               prcm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-               scrm: scrm@48000000 {
-                       compatible = "ti,omap2-scrm";
-                       reg = <0x48000000 0x1000>;
+                               prcm_clockdomains: clockdomains {
+                               };
+                       };
 
-                       scrm_clocks: clocks {
+                       scm: scm@0 {
+                               compatible = "ti,omap2-scm", "simple-bus";
+                               reg = <0x0 0x1000>;
                                #address-cells = <1>;
-                               #size-cells = <0>;
+                               #size-cells = <1>;
+                               ranges = <0 0x0 0x1000>;
+
+                               omap2420_pmx: pinmux@30 {
+                                       compatible = "ti,omap2420-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x30 0x0113>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       pinctrl-single,register-width = <8>;
+                                       pinctrl-single,function-mask = <0x3f>;
+                               };
+
+                               scm_conf: scm_conf@270 {
+                                       compatible = "syscon";
+                                       reg = <0x270 0x100>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       scm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+                               };
+
+                               scm_clockdomains: clockdomains {
+                               };
                        };
 
-                       scrm_clockdomains: clockdomains {
+                       counter32k: counter@4000 {
+                               compatible = "ti,omap-counter32k";
+                               reg = <0x4000 0x20>;
+                               ti,hwmods = "counter_32k";
                        };
                };
 
-               counter32k: counter@48004000 {
-                       compatible = "ti,omap-counter32k";
-                       reg = <0x48004000 0x20>;
-                       ti,hwmods = "counter_32k";
-               };
-
-               omap2420_pmx: pinmux@48000030 {
-                       compatible = "ti,omap2420-padconf", "pinctrl-single";
-                       reg = <0x48000030 0x0113>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       pinctrl-single,register-width = <8>;
-                       pinctrl-single,function-mask = <0x3f>;
-               };
-
                gpio1: gpio@48018000 {
                        compatible = "ti,omap2-gpio";
                        reg = <0x48018000 0x200>;
index 805f75df1cf2011474a8fa119c95523acaffb163..93fed68839b9f66f8112713b28c92e7df86ea14a 100644 (file)
@@ -8,12 +8,12 @@
  * published by the Free Software Foundation.
  */
 
-&scrm_clocks {
+&scm_clocks {
        mcbsp3_mux_fck: mcbsp3_mux_fck {
                #clock-cells = <0>;
                compatible = "ti,composite-mux-clock";
                clocks = <&func_96m_ck>, <&mcbsp_clks>;
-               reg = <0x02e8>;
+               reg = <0x78>;
        };
 
        mcbsp3_fck: mcbsp3_fck {
@@ -27,7 +27,7 @@
                compatible = "ti,composite-mux-clock";
                clocks = <&func_96m_ck>, <&mcbsp_clks>;
                ti,bit-shift = <2>;
-               reg = <0x02e8>;
+               reg = <0x78>;
        };
 
        mcbsp4_fck: mcbsp4_fck {
@@ -41,7 +41,7 @@
                compatible = "ti,composite-mux-clock";
                clocks = <&func_96m_ck>, <&mcbsp_clks>;
                ti,bit-shift = <4>;
-               reg = <0x02e8>;
+               reg = <0x78>;
        };
 
        mcbsp5_fck: mcbsp5_fck {
index 0dc8de2782b1871772150b3a62ab7a92685da56a..11a7963be0035a002fa77c2bec6809b34444e584 100644 (file)
        compatible = "ti,omap2430", "ti,omap2";
 
        ocp {
-               prcm: prcm@49006000 {
-                       compatible = "ti,omap2-prcm";
-                       reg = <0x49006000 0x1000>;
+               l4_wkup: l4_wkup@49000000 {
+                       compatible = "ti,omap2-l4-wkup", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x49000000 0x31000>;
 
-                       prcm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+                       prcm: prcm@6000 {
+                               compatible = "ti,omap2-prcm";
+                               reg = <0x6000 0x1000>;
 
-                       prcm_clockdomains: clockdomains {
-                       };
-               };
-
-               scrm: scrm@49002000 {
-                       compatible = "ti,omap2-scrm";
-                       reg = <0x49002000 0x1000>;
+                               prcm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       scrm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                               prcm_clockdomains: clockdomains {
+                               };
                        };
 
-                       scrm_clockdomains: clockdomains {
+                       scm: scm@2000 {
+                               compatible = "ti,omap2-scm", "simple-bus";
+                               reg = <0x2000 0x1000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2000 0x1000>;
+
+                               omap2430_pmx: pinmux@30 {
+                                       compatible = "ti,omap2430-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x30 0x0154>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       pinctrl-single,register-width = <8>;
+                                       pinctrl-single,function-mask = <0x3f>;
+                               };
+
+                               scm_conf: scm_conf@270 {
+                                       compatible = "syscon";
+                                       reg = <0x270 0x240>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       scm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+
+                                       pbias_regulator: pbias_regulator {
+                                               compatible = "ti,pbias-omap";
+                                               reg = <0x230 0x4>;
+                                               syscon = <&scm_conf>;
+                                               pbias_mmc_reg: pbias_mmc_omap2430 {
+                                                       regulator-name = "pbias_mmc_omap2430";
+                                                       regulator-min-microvolt = <1800000>;
+                                                       regulator-max-microvolt = <3000000>;
+                                               };
+                                       };
+                               };
+
+                               scm_clockdomains: clockdomains {
+                               };
                        };
-               };
-
-               counter32k: counter@49020000 {
-                       compatible = "ti,omap-counter32k";
-                       reg = <0x49020000 0x20>;
-                       ti,hwmods = "counter_32k";
-               };
-
-               omap2430_pmx: pinmux@49002030 {
-                       compatible = "ti,omap2430-padconf", "pinctrl-single";
-                       reg = <0x49002030 0x0154>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       pinctrl-single,register-width = <8>;
-                       pinctrl-single,function-mask = <0x3f>;
-               };
-
-               omap2_scm_general: tisyscon@49002270 {
-                       compatible = "syscon";
-                       reg = <0x49002270 0x240>;
-               };
 
-               pbias_regulator: pbias_regulator {
-                       compatible = "ti,pbias-omap";
-                       reg = <0x230 0x4>;
-                       syscon = <&omap2_scm_general>;
-                       pbias_mmc_reg: pbias_mmc_omap2430 {
-                               regulator-name = "pbias_mmc_omap2430";
-                               regulator-min-microvolt = <1800000>;
-                               regulator-max-microvolt = <3000000>;
+                       counter32k: counter@20000 {
+                               compatible = "ti,omap-counter32k";
+                               reg = <0x20000 0x20>;
+                               ti,hwmods = "counter_32k";
                        };
                };
 
index a1365ca926eb6a4bcd52f1099e7c1e5c882f8664..63965b8769732f7e2e30708c30b50ad3f9ee6968 100644 (file)
@@ -7,13 +7,13 @@
  * it under the terms of the GNU General Public License version 2 as
  * published by the Free Software Foundation.
  */
-&scrm_clocks {
+&scm_clocks {
        mcbsp1_mux_fck: mcbsp1_mux_fck {
                #clock-cells = <0>;
                compatible = "ti,composite-mux-clock";
                clocks = <&func_96m_ck>, <&mcbsp_clks>;
                ti,bit-shift = <2>;
-               reg = <0x0274>;
+               reg = <0x4>;
        };
 
        mcbsp1_fck: mcbsp1_fck {
@@ -27,7 +27,7 @@
                compatible = "ti,composite-mux-clock";
                clocks = <&func_96m_ck>, <&mcbsp_clks>;
                ti,bit-shift = <6>;
-               reg = <0x0274>;
+               reg = <0x4>;
        };
 
        mcbsp2_fck: mcbsp2_fck {
index f4f78c40b56450160ba566cc25bcb7fac9ca489b..02cd996d0b0634520748a2cf83245b74c737ef6d 100644 (file)
                ranges;
                ti,hwmods = "l3_main";
 
+               l4_core: l4@48000000 {
+                       compatible = "ti,omap3-l4-core", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x48000000 0x1000000>;
+
+                       scm: scm@2000 {
+                               compatible = "ti,omap3-scm", "simple-bus";
+                               reg = <0x2000 0x2000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2000 0x2000>;
+
+                               omap3_pmx_core: pinmux@30 {
+                                       compatible = "ti,omap3-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x30 0x238>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <16>;
+                                       pinctrl-single,function-mask = <0xff1f>;
+                               };
+
+                               scm_conf: scm_conf@270 {
+                                       compatible = "syscon";
+                                       reg = <0x270 0x330>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       scm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+                               };
+
+                               scm_clockdomains: clockdomains {
+                               };
+
+                               omap3_pmx_wkup: pinmux@a00 {
+                                       compatible = "ti,omap3-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0xa00 0x5c>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <16>;
+                                       pinctrl-single,function-mask = <0xff1f>;
+                               };
+                       };
+               };
+
                aes: aes@480c5000 {
                        compatible = "ti,omap3-aes";
                        ti,hwmods = "aes";
                        };
                };
 
-               scrm: scrm@48002000 {
-                       compatible = "ti,omap3-scrm";
-                       reg = <0x48002000 0x2000>;
-
-                       scrm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
-
-                       scrm_clockdomains: clockdomains {
-                       };
-               };
-
                counter32k: counter@48320000 {
                        compatible = "ti,omap-counter32k";
                        reg = <0x48320000 0x20>;
                        dma-requests = <96>;
                };
 
-               omap3_pmx_core: pinmux@48002030 {
-                       compatible = "ti,omap3-padconf", "pinctrl-single";
-                       reg = <0x48002030 0x0238>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0xff1f>;
-               };
-
-               omap3_pmx_wkup: pinmux@48002a00 {
-                       compatible = "ti,omap3-padconf", "pinctrl-single";
-                       reg = <0x48002a00 0x5c>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0xff1f>;
-               };
-
-               omap3_scm_general: tisyscon@48002270 {
-                       compatible = "syscon";
-                       reg = <0x48002270 0x2f0>;
-               };
-
                pbias_regulator: pbias_regulator {
                        compatible = "ti,pbias-omap";
                        reg = <0x2b0 0x4>;
-                       syscon = <&omap3_scm_general>;
+                       syscon = <&scm_conf>;
                        pbias_mmc_reg: pbias_mmc_omap2430 {
                                regulator-name = "pbias_mmc_omap2430";
                                regulator-min-microvolt = <1800000>;
index 7bc8c0f72ddb29c06ef9e31bd5897dcc865a46ab..4f6b2d5b1902e96114f12b1f8bd7d15ba0b9819e 100644 (file)
@@ -46,7 +46,7 @@
                               0x480bd800 0x017c>;
                        interrupts = <24>;
                        iommus = <&mmu_isp>;
-                       syscon = <&omap3_scm_general 0xdc>;
+                       syscon = <&scm_conf 0xdc>;
                        ti,phy-type = <OMAP3ISP_PHY_TYPE_COMPLEX_IO>;
                        #clock-cells = <1>;
                        ports {
index 3502fe00ec7d2713692c54ca85408952b36b0038..86253de5a97a99ddb12ea5f41c72f3c59279fced 100644 (file)
@@ -78,7 +78,7 @@
                               0x480bd800 0x0600>;
                        interrupts = <24>;
                        iommus = <&mmu_isp>;
-                       syscon = <&omap3_scm_general 0x2f0>;
+                       syscon = <&scm_conf 0x2f0>;
                        ti,phy-type = <OMAP3ISP_PHY_TYPE_CSIPHY>;
                        #clock-cells = <1>;
                        ports {
index 5c375003bad106216109b5626264300433dabd1d..bbba5bdc4bc946d5cb9b179283c65f27ecdef1d9 100644 (file)
                clock-div = <1>;
        };
 };
-&scrm_clocks {
+
+&scm_clocks {
        mcbsp5_mux_fck: mcbsp5_mux_fck {
                #clock-cells = <0>;
                compatible = "ti,composite-mux-clock";
                clocks = <&core_96m_fck>, <&mcbsp_clks>;
                ti,bit-shift = <4>;
-               reg = <0x02d8>;
+               reg = <0x68>;
        };
 
        mcbsp5_fck: mcbsp5_fck {
                compatible = "ti,composite-mux-clock";
                clocks = <&core_96m_fck>, <&mcbsp_clks>;
                ti,bit-shift = <2>;
-               reg = <0x0274>;
+               reg = <0x04>;
        };
 
        mcbsp1_fck: mcbsp1_fck {
                compatible = "ti,composite-mux-clock";
                clocks = <&per_96m_fck>, <&mcbsp_clks>;
                ti,bit-shift = <6>;
-               reg = <0x0274>;
+               reg = <0x04>;
        };
 
        mcbsp2_fck: mcbsp2_fck {
                #clock-cells = <0>;
                compatible = "ti,composite-mux-clock";
                clocks = <&per_96m_fck>, <&mcbsp_clks>;
-               reg = <0x02d8>;
+               reg = <0x68>;
        };
 
        mcbsp3_fck: mcbsp3_fck {
                compatible = "ti,composite-mux-clock";
                clocks = <&per_96m_fck>, <&mcbsp_clks>;
                ti,bit-shift = <2>;
-               reg = <0x02d8>;
+               reg = <0x68>;
        };
 
        mcbsp4_fck: mcbsp4_fck {
index cb9458feb2e36fe3c2ff95b1e857bd6ea5e52dbb..ab7f87ae96f099e5fbb53ee786602ea5492ba698 100644 (file)
@@ -18,7 +18,7 @@ cpu_thermal: cpu_thermal {
                        /* sensor       ID */
         thermal-sensors = <&bandgap     0>;
 
-        trips {
+       cpu_trips: trips {
                 cpu_alert0: cpu_alert {
                         temperature = <100000>; /* millicelsius */
                         hysteresis = <2000>; /* millicelsius */
@@ -31,7 +31,7 @@ cpu_thermal: cpu_thermal {
                 };
         };
 
-       cooling-maps {
+       cpu_cooling_maps: cooling-maps {
                map0 {
                        trip = <&cpu_alert0>;
                        cooling-device =
index 87401d9f4d8b02314323e5a46ee38e5b0c6e4523..cf2681b2d173e2b7c3de6618daac2708e4f85f9f 100644 (file)
                interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>,
                             <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
 
-               cm1: cm1@4a004000 {
-                       compatible = "ti,omap4-cm1";
-                       reg = <0x4a004000 0x2000>;
-
-                       cm1_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+               l4_cfg: l4@4a000000 {
+                       compatible = "ti,omap4-l4-cfg", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x4a000000 0x1000000>;
 
-                       cm1_clockdomains: clockdomains {
-                       };
-               };
+                       cm1: cm1@4000 {
+                               compatible = "ti,omap4-cm1";
+                               reg = <0x4000 0x2000>;
 
-               prm: prm@4a306000 {
-                       compatible = "ti,omap4-prm";
-                       reg = <0x4a306000 0x3000>;
-                       interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
+                               cm1_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       prm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                               cm1_clockdomains: clockdomains {
+                               };
                        };
 
-                       prm_clockdomains: clockdomains {
-                       };
-               };
+                       cm2: cm2@8000 {
+                               compatible = "ti,omap4-cm2";
+                               reg = <0x8000 0x3000>;
 
-               cm2: cm2@4a008000 {
-                       compatible = "ti,omap4-cm2";
-                       reg = <0x4a008000 0x3000>;
+                               cm2_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       cm2_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                               cm2_clockdomains: clockdomains {
+                               };
                        };
 
-                       cm2_clockdomains: clockdomains {
+                       omap4_scm_core: scm@2000 {
+                               compatible = "ti,omap4-scm-core", "simple-bus";
+                               reg = <0x2000 0x1000>;
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2000 0x1000>;
+
+                               scm_conf: scm_conf@0 {
+                                       compatible = "syscon";
+                                       reg = <0x0 0x800>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+                               };
                        };
-               };
-
-               scrm: scrm@4a30a000 {
-                       compatible = "ti,omap4-scrm";
-                       reg = <0x4a30a000 0x2000>;
 
-                       scrm_clocks: clocks {
+                       omap4_padconf_core: scm@100000 {
+                               compatible = "ti,omap4-scm-padconf-core",
+                                            "simple-bus";
                                #address-cells = <1>;
-                               #size-cells = <0>;
+                               #size-cells = <1>;
+                               ranges = <0 0x100000 0x1000>;
+
+                               omap4_pmx_core: pinmux@40 {
+                                       compatible = "ti,omap4-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x40 0x0196>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <16>;
+                                       pinctrl-single,function-mask = <0x7fff>;
+                               };
+
+                               omap4_padconf_global: omap4_padconf_global@5a0 {
+                                       compatible = "syscon";
+                                       reg = <0x5a0 0x170>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       pbias_regulator: pbias_regulator {
+                                               compatible = "ti,pbias-omap";
+                                               reg = <0x60 0x4>;
+                                               syscon = <&omap4_padconf_global>;
+                                               pbias_mmc_reg: pbias_mmc_omap4 {
+                                                       regulator-name = "pbias_mmc_omap4";
+                                                       regulator-min-microvolt = <1800000>;
+                                                       regulator-max-microvolt = <3000000>;
+                                               };
+                                       };
+                               };
                        };
 
-                       scrm_clockdomains: clockdomains {
-                       };
-               };
-
-               counter32k: counter@4a304000 {
-                       compatible = "ti,omap-counter32k";
-                       reg = <0x4a304000 0x20>;
-                       ti,hwmods = "counter_32k";
-               };
-
-               omap4_pmx_core: pinmux@4a100040 {
-                       compatible = "ti,omap4-padconf", "pinctrl-single";
-                       reg = <0x4a100040 0x0196>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0x7fff>;
-               };
-               omap4_pmx_wkup: pinmux@4a31e040 {
-                       compatible = "ti,omap4-padconf", "pinctrl-single";
-                       reg = <0x4a31e040 0x0038>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0x7fff>;
-               };
-
-               omap4_padconf_global: tisyscon@4a1005a0 {
-                       compatible = "syscon";
-                       reg = <0x4a1005a0 0x170>;
-               };
-
-               pbias_regulator: pbias_regulator {
-                       compatible = "ti,pbias-omap";
-                       reg = <0x60 0x4>;
-                       syscon = <&omap4_padconf_global>;
-                       pbias_mmc_reg: pbias_mmc_omap4 {
-                               regulator-name = "pbias_mmc_omap4";
-                               regulator-min-microvolt = <1800000>;
-                               regulator-max-microvolt = <3000000>;
+                       l4_wkup: l4@300000 {
+                               compatible = "ti,omap4-l4-wkup", "simple-bus";
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x300000 0x40000>;
+
+                               counter32k: counter@4000 {
+                                       compatible = "ti,omap-counter32k";
+                                       reg = <0x4000 0x20>;
+                                       ti,hwmods = "counter_32k";
+                               };
+
+                               prm: prm@6000 {
+                                       compatible = "ti,omap4-prm";
+                                       reg = <0x6000 0x3000>;
+                                       interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
+
+                                       prm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+
+                                       prm_clockdomains: clockdomains {
+                                       };
+                               };
+
+                               scrm: scrm@a000 {
+                                       compatible = "ti,omap4-scrm";
+                                       reg = <0xa000 0x2000>;
+
+                                       scrm_clocks: clocks {
+                                               #address-cells = <1>;
+                                               #size-cells = <0>;
+                                       };
+
+                                       scrm_clockdomains: clockdomains {
+                                       };
+                               };
+
+                               omap4_pmx_wkup: pinmux@1e040 {
+                                       compatible = "ti,omap4-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x1e040 0x0038>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <16>;
+                                       pinctrl-single,function-mask = <0x7fff>;
+                               };
                        };
                };
 
index ddff674bd05edd2df3482e35628871628286f2c9..3cdb5c22148d9123479111f1a61e656bf9b0e8a9 100644 (file)
                interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>,
                             <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
 
-               prm: prm@4ae06000 {
-                       compatible = "ti,omap5-prm";
-                       reg = <0x4ae06000 0x3000>;
-                       interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
+               l4_cfg: l4@4a000000 {
+                       compatible = "ti,omap5-l4-cfg", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x4a000000 0x22a000>;
 
-                       prm_clocks: clocks {
+                       scm_core: scm@2000 {
+                               compatible = "ti,omap5-scm-core", "simple-bus";
+                               reg = <0x2000 0x1000>;
                                #address-cells = <1>;
-                               #size-cells = <0>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2000 0x800>;
+
+                               scm_conf: scm_conf@0 {
+                                       compatible = "syscon";
+                                       reg = <0x0 0x800>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+                               };
                        };
 
-                       prm_clockdomains: clockdomains {
+                       scm_padconf_core: scm@2800 {
+                               compatible = "ti,omap5-scm-padconf-core",
+                                            "simple-bus";
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               ranges = <0 0x2800 0x800>;
+
+                               omap5_pmx_core: pinmux@40 {
+                                       compatible = "ti,omap5-padconf",
+                                                    "pinctrl-single";
+                                       reg = <0x40 0x01b6>;
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                                       #interrupt-cells = <1>;
+                                       interrupt-controller;
+                                       pinctrl-single,register-width = <16>;
+                                       pinctrl-single,function-mask = <0x7fff>;
+                               };
+
+                               omap5_padconf_global: omap5_padconf_global@5a0 {
+                                       compatible = "syscon";
+                                       reg = <0x5a0 0xec>;
+                                       #address-cells = <1>;
+                                       #size-cells = <1>;
+
+                                       pbias_regulator: pbias_regulator {
+                                               compatible = "ti,pbias-omap";
+                                               reg = <0x60 0x4>;
+                                               syscon = <&omap5_padconf_global>;
+                                               pbias_mmc_reg: pbias_mmc_omap5 {
+                                                       regulator-name = "pbias_mmc_omap5";
+                                                       regulator-min-microvolt = <1800000>;
+                                                       regulator-max-microvolt = <3000000>;
+                                               };
+                                       };
+                               };
                        };
-               };
 
-               cm_core_aon: cm_core_aon@4a004000 {
-                       compatible = "ti,omap5-cm-core-aon";
-                       reg = <0x4a004000 0x2000>;
+                       cm_core_aon: cm_core_aon@4000 {
+                               compatible = "ti,omap5-cm-core-aon";
+                               reg = <0x4000 0x2000>;
 
-                       cm_core_aon_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+                               cm_core_aon_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       cm_core_aon_clockdomains: clockdomains {
+                               cm_core_aon_clockdomains: clockdomains {
+                               };
                        };
-               };
 
-               scrm: scrm@4ae0a000 {
-                       compatible = "ti,omap5-scrm";
-                       reg = <0x4ae0a000 0x2000>;
+                       cm_core: cm_core@8000 {
+                               compatible = "ti,omap5-cm-core";
+                               reg = <0x8000 0x3000>;
 
-                       scrm_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
-                       };
+                               cm_core_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-                       scrm_clockdomains: clockdomains {
+                               cm_core_clockdomains: clockdomains {
+                               };
                        };
                };
 
-               cm_core: cm_core@4a008000 {
-                       compatible = "ti,omap5-cm-core";
-                       reg = <0x4a008000 0x3000>;
+               l4_wkup: l4@4ae00000 {
+                       compatible = "ti,omap5-l4-wkup", "simple-bus";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+                       ranges = <0 0x4ae00000 0x2b000>;
 
-                       cm_core_clocks: clocks {
-                               #address-cells = <1>;
-                               #size-cells = <0>;
+                       counter32k: counter@4000 {
+                               compatible = "ti,omap-counter32k";
+                               reg = <0x4000 0x40>;
+                               ti,hwmods = "counter_32k";
                        };
 
-                       cm_core_clockdomains: clockdomains {
+                       prm: prm@6000 {
+                               compatible = "ti,omap5-prm";
+                               reg = <0x6000 0x3000>;
+                               interrupts = <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
+
+                               prm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
+
+                               prm_clockdomains: clockdomains {
+                               };
                        };
-               };
 
-               counter32k: counter@4ae04000 {
-                       compatible = "ti,omap-counter32k";
-                       reg = <0x4ae04000 0x40>;
-                       ti,hwmods = "counter_32k";
-               };
+                       scrm: scrm@a000 {
+                               compatible = "ti,omap5-scrm";
+                               reg = <0xa000 0x2000>;
 
-               omap5_pmx_core: pinmux@4a002840 {
-                       compatible = "ti,omap5-padconf", "pinctrl-single";
-                       reg = <0x4a002840 0x01b6>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0x7fff>;
-               };
-               omap5_pmx_wkup: pinmux@4ae0c840 {
-                       compatible = "ti,omap5-padconf", "pinctrl-single";
-                       reg = <0x4ae0c840 0x0038>;
-                       #address-cells = <1>;
-                       #size-cells = <0>;
-                       #interrupt-cells = <1>;
-                       interrupt-controller;
-                       pinctrl-single,register-width = <16>;
-                       pinctrl-single,function-mask = <0x7fff>;
-               };
+                               scrm_clocks: clocks {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+                               };
 
-               omap5_padconf_global: tisyscon@4a002da0 {
-                       compatible = "syscon";
-                       reg = <0x4A002da0 0xec>;
-               };
+                               scrm_clockdomains: clockdomains {
+                               };
+                       };
 
-               pbias_regulator: pbias_regulator {
-                       compatible = "ti,pbias-omap";
-                       reg = <0x60 0x4>;
-                       syscon = <&omap5_padconf_global>;
-                       pbias_mmc_reg: pbias_mmc_omap5 {
-                               regulator-name = "pbias_mmc_omap5";
-                               regulator-min-microvolt = <1800000>;
-                               regulator-max-microvolt = <3000000>;
+                       omap5_pmx_wkup: pinmux@c840 {
+                               compatible = "ti,omap5-padconf",
+                                            "pinctrl-single";
+                               reg = <0xc840 0x0038>;
+                               #address-cells = <1>;
+                               #size-cells = <0>;
+                               #interrupt-cells = <1>;
+                               interrupt-controller;
+                               pinctrl-single,register-width = <16>;
+                               pinctrl-single,function-mask = <0x7fff>;
                        };
                };
 
index 36cafbfa1bfacd58bd9e6ebbfeaf8a18c23ff018..606753eb72c8f67d9551b19bfed61137b2ab07c2 100644 (file)
                bootargs = "console=ttyLP0,115200";
        };
 
+       clk16m: clk16m {
+               compatible = "fixed-clock";
+               #clock-cells = <0>;
+               clock-frequency = <16000000>;
+       };
+
        regulators {
                compatible = "simple-bus";
                #address-cells = <1>;
        status  = "okay";
 };
 
+&dspi1 {
+       status = "okay";
+
+       mcp2515can: can@0 {
+               compatible = "microchip,mcp2515";
+               pinctrl-names = "default";
+               pinctrl-0 = <&pinctrl_can_int>;
+               reg = <0>;
+               clocks = <&clk16m>;
+               spi-max-frequency = <10000000>;
+               interrupt-parent = <&gpio1>;
+               interrupts = <11 GPIO_ACTIVE_LOW>;
+       };
+};
+
 &esdhc1 {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_esdhc1>;
 &usbh1 {
        vbus-supply = <&usbh_vbus_reg>;
 };
+
+&iomuxc {
+       vf610-colibri {
+               pinctrl_can_int: can_int {
+                       fsl,pins = <
+                               VF610_PAD_PTB21__GPIO_43        0x22ed
+                       >;
+               };
+       };
+};
index 5c2b7320856dc0efc49c12cf7ff5575bf94a05dc..fbef0828e9303ca54d3a2304b0d4b2cf26bea417 100644 (file)
        status = "okay";
 };
 
+&dspi1 {
+       bus-num = <1>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_dspi1>;
+};
+
 &edma0 {
        status = "okay";
 };
                        >;
                };
 
+               pinctrl_dspi1: dspi1grp {
+                       fsl,pins = <
+                               VF610_PAD_PTD5__DSPI1_CS0               0x33e2
+                               VF610_PAD_PTD6__DSPI1_SIN               0x33e1
+                               VF610_PAD_PTD7__DSPI1_SOUT              0x33e2
+                               VF610_PAD_PTD8__DSPI1_SCK               0x33e2
+                       >;
+               };
+
                pinctrl_esdhc1: esdhc1grp {
                        fsl,pins = <
                                VF610_PAD_PTA24__ESDHC1_CLK     0x31ef
index 1dbf8d2d1ddf50e034b337a64b6f74b4f868fd55..e976d2fa15274239b9ed2b0568cb9bd9ba9b2aa6 100644 (file)
        };
 
        soc {
-               interrupt-parent = <&intc>;
-
                aips-bus@40000000 {
 
                        intc: interrupt-controller@40002000 {
                                compatible = "arm,cortex-a9-gic";
                                #interrupt-cells = <3>;
                                interrupt-controller;
+                               interrupt-parent = <&intc>;
                                reg = <0x40003000 0x1000>,
                                      <0x40002100 0x100>;
                        };
                                compatible = "arm,cortex-a9-global-timer";
                                reg = <0x40002200 0x20>;
                                interrupts = <GIC_PPI 11 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-parent = <&intc>;
                                clocks = <&clks VF610_CLK_PLATFORM_BUS>;
                        };
                };
        };
 };
 
-&adc0 {
-       interrupts = <GIC_SPI 53 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&adc1 {
-       interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&can0 {
-       interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&can1 {
-       interrupts = <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&dspi0 {
-       interrupts = <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&edma0 {
-       interrupts = <GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>,
-                       <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>;
-       interrupt-names = "edma-tx", "edma-err";
-};
-
-&edma1 {
-       interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>,
-                       <GIC_SPI 11 IRQ_TYPE_LEVEL_HIGH>;
-       interrupt-names = "edma-tx", "edma-err";
-};
-
-&esdhc1 {
-       interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&fec0 {
-       interrupts = <GIC_SPI 78 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&fec1 {
-       interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&ftm {
-       interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&gpio0 {
-       interrupts = <GIC_SPI 107 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&gpio1 {
-       interrupts = <GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&gpio2 {
-       interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&gpio3 {
-       interrupts = <GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&gpio4 {
-       interrupts = <GIC_SPI 111 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&i2c0 {
-       interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&pit {
-       interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&qspi0 {
-       interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&sai2 {
-       interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&snvsrtc {
-       interrupts = <GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&src {
-       interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart0 {
-       interrupts = <GIC_SPI 61 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart1 {
-       interrupts = <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart2 {
-       interrupts = <GIC_SPI 63 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart3 {
-       interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart4 {
-       interrupts = <GIC_SPI 65 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&uart5 {
-       interrupts = <GIC_SPI 66 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&usbdev0 {
-       interrupts = <GIC_SPI 75 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&usbh1 {
-       interrupts = <GIC_SPI 76 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&usbphy0 {
-       interrupts = <GIC_SPI 50 IRQ_TYPE_LEVEL_HIGH>;
-};
-
-&usbphy1 {
-       interrupts = <GIC_SPI 51 IRQ_TYPE_LEVEL_HIGH>;
+&mscm_ir {
+       interrupt-parent = <&intc>;
 };
 
 &wdoga5 {
-       interrupts = <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
        status = "okay";
 };
index a29c7ce15eafb2b8bbeffb05f173c752d319d230..4aa335166be76ae7296cbaf455a03af2e872e127 100644 (file)
@@ -54,6 +54,7 @@
                #address-cells = <1>;
                #size-cells = <1>;
                compatible = "simple-bus";
+               interrupt-parent = <&mscm_ir>;
                ranges;
 
                aips0: aips-bus@40000000 {
                        #size-cells = <1>;
                        ranges;
 
+                       mscm_cpucfg: cpucfg@40001000 {
+                               compatible = "fsl,vf610-mscm-cpucfg", "syscon";
+                               reg = <0x40001000 0x800>;
+                       };
+
+                       mscm_ir: interrupt-controller@40001800 {
+                               compatible = "fsl,vf610-mscm-ir";
+                               reg = <0x40001800 0x400>;
+                               fsl,cpucfg = <&mscm_cpucfg>;
+                               interrupt-controller;
+                               #interrupt-cells = <2>;
+                       };
+
                        edma0: dma-controller@40018000 {
                                #dma-cells = <2>;
                                compatible = "fsl,vf610-edma";
@@ -69,6 +83,9 @@
                                        <0x40024000 0x1000>,
                                        <0x40025000 0x1000>;
                                dma-channels = <32>;
+                               interrupts = <8 IRQ_TYPE_LEVEL_HIGH>,
+                                               <9 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-names = "edma-tx", "edma-err";
                                clock-names = "dmamux0", "dmamux1";
                                clocks = <&clks VF610_CLK_DMAMUX0>,
                                        <&clks VF610_CLK_DMAMUX1>;
@@ -78,6 +95,7 @@
                        can0: flexcan@40020000 {
                                compatible = "fsl,vf610-flexcan";
                                reg = <0x40020000 0x4000>;
+                               interrupts = <58 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_FLEXCAN0>,
                                         <&clks VF610_CLK_FLEXCAN0>;
                                clock-names = "ipg", "per";
                        uart0: serial@40027000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x40027000 0x1000>;
+                               interrupts = <61 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART0>;
                                clock-names = "ipg";
                                dmas = <&edma0 0 2>,
                        uart1: serial@40028000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x40028000 0x1000>;
+                               interrupts = <62 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART1>;
                                clock-names = "ipg";
                                dmas = <&edma0 0 4>,
                        uart2: serial@40029000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x40029000 0x1000>;
+                               interrupts = <63 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART2>;
                                clock-names = "ipg";
                                dmas = <&edma0 0 6>,
                        uart3: serial@4002a000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x4002a000 0x1000>;
+                               interrupts = <64 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART3>;
                                clock-names = "ipg";
                                dmas = <&edma0 0 8>,
                                #size-cells = <0>;
                                compatible = "fsl,vf610-dspi";
                                reg = <0x4002c000 0x1000>;
+                               interrupts = <67 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_DSPI0>;
                                clock-names = "dspi";
                                spi-num-chipselects = <5>;
                                status = "disabled";
                        };
 
+                       dspi1: dspi1@4002d000 {
+                               #address-cells = <1>;
+                               #size-cells = <0>;
+                               compatible = "fsl,vf610-dspi";
+                               reg = <0x4002d000 0x1000>;
+                               interrupts = <68 IRQ_TYPE_LEVEL_HIGH>;
+                               clocks = <&clks VF610_CLK_DSPI1>;
+                               clock-names = "dspi";
+                               spi-num-chipselects = <5>;
+                               status = "disabled";
+                       };
+
                        sai2: sai@40031000 {
                                compatible = "fsl,vf610-sai";
                                reg = <0x40031000 0x1000>;
+                               interrupts = <86 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_SAI2>;
                                clock-names = "sai";
                                dma-names = "tx", "rx";
                        pit: pit@40037000 {
                                compatible = "fsl,vf610-pit";
                                reg = <0x40037000 0x1000>;
+                               interrupts = <39 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_PIT>;
                                clock-names = "pit";
                        };
                        adc0: adc@4003b000 {
                                compatible = "fsl,vf610-adc";
                                reg = <0x4003b000 0x1000>;
+                               interrupts = <53 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_ADC0>;
                                clock-names = "adc";
                                status = "disabled";
                        wdoga5: wdog@4003e000 {
                                compatible = "fsl,vf610-wdt", "fsl,imx21-wdt";
                                reg = <0x4003e000 0x1000>;
+                               interrupts = <20 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_WDT>;
                                clock-names = "wdog";
                                status = "disabled";
                                #size-cells = <0>;
                                compatible = "fsl,vf610-qspi";
                                reg = <0x40044000 0x1000>;
+                               interrupts = <24 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_QSPI0_EN>,
                                        <&clks VF610_CLK_QSPI0>;
                                clock-names = "qspi_en", "qspi";
                        iomuxc: iomuxc@40048000 {
                                compatible = "fsl,vf610-iomuxc";
                                reg = <0x40048000 0x1000>;
-                               #gpio-range-cells = <3>;
                        };
 
                        gpio0: gpio@40049000 {
                                reg = <0x40049000 0x1000 0x400ff000 0x40>;
                                gpio-controller;
                                #gpio-cells = <2>;
+                               interrupts = <107 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-controller;
                                #interrupt-cells = <2>;
                                gpio-ranges = <&iomuxc 0 0 32>;
                                reg = <0x4004a000 0x1000 0x400ff040 0x40>;
                                gpio-controller;
                                #gpio-cells = <2>;
+                               interrupts = <108 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-controller;
                                #interrupt-cells = <2>;
                                gpio-ranges = <&iomuxc 0 32 32>;
                                reg = <0x4004b000 0x1000 0x400ff080 0x40>;
                                gpio-controller;
                                #gpio-cells = <2>;
+                               interrupts = <109 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-controller;
                                #interrupt-cells = <2>;
                                gpio-ranges = <&iomuxc 0 64 32>;
                                reg = <0x4004c000 0x1000 0x400ff0c0 0x40>;
                                gpio-controller;
                                #gpio-cells = <2>;
+                               interrupts = <110 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-controller;
                                #interrupt-cells = <2>;
                                gpio-ranges = <&iomuxc 0 96 32>;
                                reg = <0x4004d000 0x1000 0x400ff100 0x40>;
                                gpio-controller;
                                #gpio-cells = <2>;
+                               interrupts = <111 IRQ_TYPE_LEVEL_HIGH>;
                                interrupt-controller;
                                #interrupt-cells = <2>;
                                gpio-ranges = <&iomuxc 0 128 7>;
                        usbphy0: usbphy@40050800 {
                                compatible = "fsl,vf610-usbphy";
                                reg = <0x40050800 0x400>;
+                               interrupts = <50 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_USBPHY0>;
                                fsl,anatop = <&anatop>;
                                status = "disabled";
                        usbphy1: usbphy@40050c00 {
                                compatible = "fsl,vf610-usbphy";
                                reg = <0x40050c00 0x400>;
+                               interrupts = <51 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_USBPHY1>;
                                fsl,anatop = <&anatop>;
                                status = "disabled";
                                #size-cells = <0>;
                                compatible = "fsl,vf610-i2c";
                                reg = <0x40066000 0x1000>;
+                               interrupts = <71 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_I2C0>;
                                clock-names = "ipg";
                                dmas = <&edma0 0 50>,
                        usbdev0: usb@40034000 {
                                compatible = "fsl,vf610-usb", "fsl,imx27-usb";
                                reg = <0x40034000 0x800>;
+                               interrupts = <75 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_USBC0>;
                                fsl,usbphy = <&usbphy0>;
                                fsl,usbmisc = <&usbmisc0 0>;
                        src: src@4006e000 {
                                compatible = "fsl,vf610-src", "syscon";
                                reg = <0x4006e000 0x1000>;
+                               interrupts = <96 IRQ_TYPE_LEVEL_HIGH>;
                        };
                };
 
                                        <0x400a1000 0x1000>,
                                        <0x400a2000 0x1000>;
                                dma-channels = <32>;
+                               interrupts = <10 IRQ_TYPE_LEVEL_HIGH>,
+                                               <11 IRQ_TYPE_LEVEL_HIGH>;
+                               interrupt-names = "edma-tx", "edma-err";
                                clock-names = "dmamux0", "dmamux1";
                                clocks = <&clks VF610_CLK_DMAMUX2>,
                                        <&clks VF610_CLK_DMAMUX3>;
                                snvsrtc: snvs-rtc-lp@34 {
                                        compatible = "fsl,sec-v4.0-mon-rtc-lp";
                                        reg = <0x34 0x58>;
+                                       interrupts = <100 IRQ_TYPE_LEVEL_HIGH>;
                                        clocks = <&clks VF610_CLK_SNVS>;
                                        clock-names = "snvs-rtc";
                                };
                        uart4: serial@400a9000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x400a9000 0x1000>;
+                               interrupts = <65 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART4>;
                                clock-names = "ipg";
                                status = "disabled";
                        uart5: serial@400aa000 {
                                compatible = "fsl,vf610-lpuart";
                                reg = <0x400aa000 0x1000>;
+                               interrupts = <66 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_UART5>;
                                clock-names = "ipg";
                                status = "disabled";
                        adc1: adc@400bb000 {
                                compatible = "fsl,vf610-adc";
                                reg = <0x400bb000 0x1000>;
+                               interrupts = <54 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_ADC1>;
                                clock-names = "adc";
                                status = "disabled";
                        esdhc1: esdhc@400b2000 {
                                compatible = "fsl,imx53-esdhc";
                                reg = <0x400b2000 0x1000>;
+                               interrupts = <28 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_IPG_BUS>,
                                        <&clks VF610_CLK_PLATFORM_BUS>,
                                        <&clks VF610_CLK_ESDHC1>;
                        usbh1: usb@400b4000 {
                                compatible = "fsl,vf610-usb", "fsl,imx27-usb";
                                reg = <0x400b4000 0x800>;
+                               interrupts = <76 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_USBC1>;
                                fsl,usbphy = <&usbphy1>;
                                fsl,usbmisc = <&usbmisc1 0>;
                        ftm: ftm@400b8000 {
                                compatible = "fsl,ftm-timer";
                                reg = <0x400b8000 0x1000 0x400b9000 0x1000>;
+                               interrupts = <44 IRQ_TYPE_LEVEL_HIGH>;
                                clock-names = "ftm-evt", "ftm-src",
                                        "ftm-evt-counter-en", "ftm-src-counter-en";
                                clocks = <&clks VF610_CLK_FTM2>,
                        fec0: ethernet@400d0000 {
                                compatible = "fsl,mvf600-fec";
                                reg = <0x400d0000 0x1000>;
+                               interrupts = <78 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_ENET0>,
                                        <&clks VF610_CLK_ENET0>,
                                        <&clks VF610_CLK_ENET>;
                        fec1: ethernet@400d1000 {
                                compatible = "fsl,mvf600-fec";
                                reg = <0x400d1000 0x1000>;
+                               interrupts = <79 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_ENET1>,
                                        <&clks VF610_CLK_ENET1>,
                                        <&clks VF610_CLK_ENET>;
                        can1: flexcan@400d4000 {
                                compatible = "fsl,vf610-flexcan";
                                reg = <0x400d4000 0x4000>;
+                               interrupts = <59 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&clks VF610_CLK_FLEXCAN1>,
                                         <&clks VF610_CLK_FLEXCAN1>;
                                clock-names = "ipg", "per";
index e6b0007355f883eaca70e4ce4df5b6fcc9818ae4..af07e058ba119194334ef36e4aeca5b822052f7f 100644 (file)
@@ -24,9 +24,8 @@ CONFIG_ARCH_MXC=y
 CONFIG_MACH_SCB9328=y
 CONFIG_MACH_APF9328=y
 CONFIG_MACH_MX21ADS=y
-CONFIG_MACH_MX25_3DS=y
 CONFIG_MACH_EUKREA_CPUIMX25SD=y
-CONFIG_MACH_IMX25_DT=y
+CONFIG_SOC_IMX25=y
 CONFIG_MACH_MX27ADS=y
 CONFIG_MACH_MX27_3DS=y
 CONFIG_MACH_IMX27_VISSTRIM_M10=y
index 9d56781a8f80171e65922a44786d8bb10cbd3d4a..f69a459f4f92db0016857df6c710eb3b281c500e 100644 (file)
@@ -13,7 +13,7 @@ CONFIG_ARCH_MVEBU=y
 CONFIG_MACH_KIRKWOOD=y
 CONFIG_MACH_NETXBIG=y
 CONFIG_ARCH_MXC=y
-CONFIG_MACH_IMX25_DT=y
+CONFIG_SOC_IMX25=y
 CONFIG_MACH_IMX27_DT=y
 CONFIG_ARCH_U300=y
 CONFIG_PCI_MVEBU=y
index e8627e04e1e669e6485d8eb71e142c2acda25fea..3a3d3e9d7bfd6eb7f781bfa904df5caede06a33c 100644 (file)
@@ -21,6 +21,7 @@ config MXC_AVIC
 
 config MXC_DEBUG_BOARD
        bool "Enable MXC debug board(for 3-stack)"
+       depends on MACH_MX27_3DS || MACH_MX31_3DS || MACH_MX35_3DS
        help
          The debug board is an integral part of the MXC 3-stack(PDK)
          platforms, it can be attached or removed from the peripheral
@@ -50,6 +51,7 @@ config HAVE_IMX_ANATOP
 
 config HAVE_IMX_GPC
        bool
+       select PM_GENERIC_DOMAINS if PM
 
 config HAVE_IMX_MMDC
        bool
@@ -77,13 +79,6 @@ config SOC_IMX21
        select IMX_HAVE_IOMUX_V1
        select MXC_AVIC
 
-config SOC_IMX25
-       bool
-       select ARCH_MXC_IOMUX_V3
-       select CPU_ARM926T
-       select MXC_AVIC
-       select PINCTRL_IMX25
-
 config SOC_IMX27
        bool
        select CPU_ARM926T
@@ -149,62 +144,6 @@ config MACH_MX21ADS
          Include support for MX21ADS platform. This includes specific
          configurations for the board and its peripherals.
 
-comment "MX25 platforms:"
-
-config MACH_MX25_3DS
-       bool "Support MX25PDK (3DS) Platform"
-       select IMX_HAVE_PLATFORM_FLEXCAN
-       select IMX_HAVE_PLATFORM_FSL_USB2_UDC
-       select IMX_HAVE_PLATFORM_IMX2_WDT
-       select IMX_HAVE_PLATFORM_IMXDI_RTC
-       select IMX_HAVE_PLATFORM_IMX_FB
-       select IMX_HAVE_PLATFORM_IMX_I2C
-       select IMX_HAVE_PLATFORM_IMX_KEYPAD
-       select IMX_HAVE_PLATFORM_IMX_UART
-       select IMX_HAVE_PLATFORM_MXC_EHCI
-       select IMX_HAVE_PLATFORM_MXC_NAND
-       select IMX_HAVE_PLATFORM_SDHCI_ESDHC_IMX
-       select SOC_IMX25
-
-config MACH_EUKREA_CPUIMX25SD
-       bool "Support Eukrea CPUIMX25 Platform"
-       select IMX_HAVE_PLATFORM_FLEXCAN
-       select IMX_HAVE_PLATFORM_FSL_USB2_UDC
-       select IMX_HAVE_PLATFORM_IMX2_WDT
-       select IMX_HAVE_PLATFORM_IMXDI_RTC
-       select IMX_HAVE_PLATFORM_IMX_FB
-       select IMX_HAVE_PLATFORM_IMX_I2C
-       select IMX_HAVE_PLATFORM_IMX_UART
-       select IMX_HAVE_PLATFORM_MXC_EHCI
-       select IMX_HAVE_PLATFORM_MXC_NAND
-       select IMX_HAVE_PLATFORM_SDHCI_ESDHC_IMX
-       select USB_ULPI_VIEWPORT if USB_ULPI
-       select SOC_IMX25
-
-choice
-       prompt "Baseboard"
-       depends on MACH_EUKREA_CPUIMX25SD
-       default MACH_EUKREA_MBIMXSD25_BASEBOARD
-
-config MACH_EUKREA_MBIMXSD25_BASEBOARD
-       bool "Eukrea MBIMXSD development board"
-       select IMX_HAVE_PLATFORM_GPIO_KEYS
-       select IMX_HAVE_PLATFORM_IMX_SSI
-       select IMX_HAVE_PLATFORM_SPI_IMX
-       select LEDS_GPIO_REGISTER
-       help
-         This adds board specific devices that can be found on Eukrea's
-         MBIMXSD evaluation board.
-
-endchoice
-
-config MACH_IMX25_DT
-       bool "Support i.MX25 platforms from device tree"
-       select SOC_IMX25
-       help
-         Include support for Freescale i.MX25 based platforms
-         using the device tree for discovery
-
 comment "MX27 platforms:"
 
 config MACH_MX27ADS
@@ -557,6 +496,20 @@ config MACH_VPR200
 
 endif
 
+if ARCH_MULTI_V5
+
+comment "Device tree only"
+
+config SOC_IMX25
+       bool "i.MX25 support"
+       select ARCH_MXC_IOMUX_V3
+       select CPU_ARM926T
+       select MXC_AVIC
+       select PINCTRL_IMX25
+       help
+         This enables support for Freescale i.MX25 processor
+endif
+
 if ARCH_MULTI_V7
 
 comment "Device tree only"
@@ -631,12 +584,14 @@ config SOC_IMX6SX
 
 config SOC_VF610
        bool "Vybrid Family VF610 support"
+       select IRQ_DOMAIN_HIERARCHY
        select ARM_GIC
        select PINCTRL_VF610
        select PL310_ERRATA_769419 if CACHE_L2X0
+       select SMP_ON_UP if SMP
 
        help
-         This enable support for Freescale Vybrid VF610 processor.
+         This enables support for Freescale Vybrid VF610 processor.
 
 choice
        prompt "Clocksource for scheduler clock"
@@ -666,7 +621,7 @@ config SOC_LS1021A
        select ZONE_DMA if ARM_LPAE
 
        help
-         This enable support for Freescale LS1021A processor.
+         This enables support for Freescale LS1021A processor.
 
 endif
 
index 8d1b1018090898d9d1698b6bb39825a99d540001..3244cf1d2773f1c20836b6b96e60f4d054aa67f0 100644 (file)
@@ -3,7 +3,7 @@ obj-y := time.o cpu.o system.o irq-common.o
 obj-$(CONFIG_SOC_IMX1) += clk-imx1.o mm-imx1.o
 obj-$(CONFIG_SOC_IMX21) += clk-imx21.o mm-imx21.o
 
-obj-$(CONFIG_SOC_IMX25) += clk-imx25.o mm-imx25.o ehci-imx25.o cpu-imx25.o
+obj-$(CONFIG_SOC_IMX25) += clk-imx25.o cpu-imx25.o mach-imx25.o
 
 obj-$(CONFIG_SOC_IMX27) += cpu-imx27.o pm-imx27.o
 obj-$(CONFIG_SOC_IMX27) += clk-imx27.o mm-imx27.o ehci-imx27.o
@@ -48,12 +48,6 @@ obj-$(CONFIG_MACH_IMX1_DT) += imx1-dt.o
 # i.MX21 based machines
 obj-$(CONFIG_MACH_MX21ADS) += mach-mx21ads.o
 
-# i.MX25 based machines
-obj-$(CONFIG_MACH_MX25_3DS) += mach-mx25_3ds.o
-obj-$(CONFIG_MACH_EUKREA_CPUIMX25SD) += mach-eukrea_cpuimx25.o
-obj-$(CONFIG_MACH_EUKREA_MBIMXSD25_BASEBOARD) += eukrea_mbimxsd25-baseboard.o
-obj-$(CONFIG_MACH_IMX25_DT) += imx25-dt.o
-
 # i.MX27 based machines
 obj-$(CONFIG_MACH_MX27ADS) += mach-mx27ads.o
 obj-$(CONFIG_MACH_MX27_3DS) += mach-mx27_3ds.o
index 59c0c8558c6bf5d5212c5e88083a55f859f01287..9c2633a9de9f0ec53dfdc20677eb709488b7824a 100644 (file)
@@ -30,7 +30,6 @@
 #include "clk.h"
 #include "common.h"
 #include "hardware.h"
-#include "mx25.h"
 
 #define CCM_MPCTL      0x00
 #define CCM_UPCTL      0x04
@@ -239,80 +238,6 @@ static int __init __mx25_clocks_init(unsigned long osc_rate,
        return 0;
 }
 
-int __init mx25_clocks_init(void)
-{
-       void __iomem *ccm;
-
-       ccm = ioremap(MX25_CRM_BASE_ADDR, SZ_16K);
-
-       __mx25_clocks_init(24000000, ccm);
-
-       clk_register_clkdev(clk[gpt1_ipg], "ipg", "imx-gpt.0");
-       clk_register_clkdev(clk[gpt_ipg_per], "per", "imx-gpt.0");
-       /* i.mx25 has the i.mx21 type uart */
-       clk_register_clkdev(clk[uart1_ipg], "ipg", "imx21-uart.0");
-       clk_register_clkdev(clk[uart_ipg_per], "per", "imx21-uart.0");
-       clk_register_clkdev(clk[uart2_ipg], "ipg", "imx21-uart.1");
-       clk_register_clkdev(clk[uart_ipg_per], "per", "imx21-uart.1");
-       clk_register_clkdev(clk[uart3_ipg], "ipg", "imx21-uart.2");
-       clk_register_clkdev(clk[uart_ipg_per], "per", "imx21-uart.2");
-       clk_register_clkdev(clk[uart4_ipg], "ipg", "imx21-uart.3");
-       clk_register_clkdev(clk[uart_ipg_per], "per", "imx21-uart.3");
-       clk_register_clkdev(clk[uart5_ipg], "ipg", "imx21-uart.4");
-       clk_register_clkdev(clk[uart_ipg_per], "per", "imx21-uart.4");
-       clk_register_clkdev(clk[ipg], "ipg", "mxc-ehci.0");
-       clk_register_clkdev(clk[usbotg_ahb], "ahb", "mxc-ehci.0");
-       clk_register_clkdev(clk[usb_div], "per", "mxc-ehci.0");
-       clk_register_clkdev(clk[ipg], "ipg", "mxc-ehci.1");
-       clk_register_clkdev(clk[usbotg_ahb], "ahb", "mxc-ehci.1");
-       clk_register_clkdev(clk[usb_div], "per", "mxc-ehci.1");
-       clk_register_clkdev(clk[ipg], "ipg", "mxc-ehci.2");
-       clk_register_clkdev(clk[usbotg_ahb], "ahb", "mxc-ehci.2");
-       clk_register_clkdev(clk[usb_div], "per", "mxc-ehci.2");
-       clk_register_clkdev(clk[ipg], "ipg", "imx-udc-mx27");
-       clk_register_clkdev(clk[usbotg_ahb], "ahb", "imx-udc-mx27");
-       clk_register_clkdev(clk[usb_div], "per", "imx-udc-mx27");
-       clk_register_clkdev(clk[nfc_ipg_per], NULL, "imx25-nand.0");
-       /* i.mx25 has the i.mx35 type cspi */
-       clk_register_clkdev(clk[cspi1_ipg], NULL, "imx35-cspi.0");
-       clk_register_clkdev(clk[cspi2_ipg], NULL, "imx35-cspi.1");
-       clk_register_clkdev(clk[cspi3_ipg], NULL, "imx35-cspi.2");
-       clk_register_clkdev(clk[kpp_ipg], NULL, "imx-keypad");
-       clk_register_clkdev(clk[tsc_ipg], NULL, "mx25-adc");
-       clk_register_clkdev(clk[i2c_ipg_per], NULL, "imx21-i2c.0");
-       clk_register_clkdev(clk[i2c_ipg_per], NULL, "imx21-i2c.1");
-       clk_register_clkdev(clk[i2c_ipg_per], NULL, "imx21-i2c.2");
-       clk_register_clkdev(clk[fec_ipg], "ipg", "imx25-fec.0");
-       clk_register_clkdev(clk[fec_ahb], "ahb", "imx25-fec.0");
-       clk_register_clkdev(clk[dryice_ipg], NULL, "imxdi_rtc.0");
-       clk_register_clkdev(clk[lcdc_ipg_per], "per", "imx21-fb.0");
-       clk_register_clkdev(clk[lcdc_ipg], "ipg", "imx21-fb.0");
-       clk_register_clkdev(clk[lcdc_ahb], "ahb", "imx21-fb.0");
-       clk_register_clkdev(clk[wdt_ipg], NULL, "imx2-wdt.0");
-       clk_register_clkdev(clk[ssi1_ipg], NULL, "imx-ssi.0");
-       clk_register_clkdev(clk[ssi2_ipg], NULL, "imx-ssi.1");
-       clk_register_clkdev(clk[esdhc1_ipg_per], "per", "sdhci-esdhc-imx25.0");
-       clk_register_clkdev(clk[esdhc1_ipg], "ipg", "sdhci-esdhc-imx25.0");
-       clk_register_clkdev(clk[esdhc1_ahb], "ahb", "sdhci-esdhc-imx25.0");
-       clk_register_clkdev(clk[esdhc2_ipg_per], "per", "sdhci-esdhc-imx25.1");
-       clk_register_clkdev(clk[esdhc2_ipg], "ipg", "sdhci-esdhc-imx25.1");
-       clk_register_clkdev(clk[esdhc2_ahb], "ahb", "sdhci-esdhc-imx25.1");
-       clk_register_clkdev(clk[csi_ipg_per], "per", "imx25-camera.0");
-       clk_register_clkdev(clk[csi_ipg], "ipg", "imx25-camera.0");
-       clk_register_clkdev(clk[csi_ahb], "ahb", "imx25-camera.0");
-       clk_register_clkdev(clk[dummy], "audmux", NULL);
-       clk_register_clkdev(clk[can1_ipg], NULL, "flexcan.0");
-       clk_register_clkdev(clk[can2_ipg], NULL, "flexcan.1");
-       /* i.mx25 has the i.mx35 type sdma */
-       clk_register_clkdev(clk[sdma_ipg], "ipg", "imx35-sdma");
-       clk_register_clkdev(clk[sdma_ahb], "ahb", "imx35-sdma");
-       clk_register_clkdev(clk[iim_ipg], "iim", NULL);
-
-       mxc_timer_init(MX25_IO_ADDRESS(MX25_GPT1_BASE_ADDR), MX25_INT_GPT1);
-
-       return 0;
-}
-
 static void __init mx25_clocks_init_dt(struct device_node *np)
 {
        struct device_node *refnp;
index d04a430607b8af66ef71ba3f01ff8e151738eeb1..469a150bf98f98cbb5521343e81d531c7fc34e91 100644 (file)
@@ -119,6 +119,7 @@ static unsigned int share_count_asrc;
 static unsigned int share_count_ssi1;
 static unsigned int share_count_ssi2;
 static unsigned int share_count_ssi3;
+static unsigned int share_count_mipi_core_cfg;
 
 static void __init imx6q_clocks_init(struct device_node *ccm_node)
 {
@@ -246,6 +247,7 @@ static void __init imx6q_clocks_init(struct device_node *ccm_node)
        clk[IMX6QDL_CLK_PLL3_60M]  = imx_clk_fixed_factor("pll3_60m",  "pll3_usb_otg",   1, 8);
        clk[IMX6QDL_CLK_TWD]       = imx_clk_fixed_factor("twd",       "arm",            1, 2);
        clk[IMX6QDL_CLK_GPT_3M]    = imx_clk_fixed_factor("gpt_3m",    "osc",            1, 8);
+       clk[IMX6QDL_CLK_VIDEO_27M] = imx_clk_fixed_factor("video_27m", "pll3_pfd1_540m", 1, 20);
        if (cpu_is_imx6dl()) {
                clk[IMX6QDL_CLK_GPU2D_AXI] = imx_clk_fixed_factor("gpu2d_axi", "mmdc_ch0_axi_podf", 1, 1);
                clk[IMX6QDL_CLK_GPU3D_AXI] = imx_clk_fixed_factor("gpu3d_axi", "mmdc_ch0_axi_podf", 1, 1);
@@ -400,7 +402,7 @@ static void __init imx6q_clocks_init(struct device_node *ccm_node)
                clk[IMX6QDL_CLK_GPU2D_CORE] = imx_clk_gate2("gpu2d_core", "gpu2d_core_podf", base + 0x6c, 24);
        clk[IMX6QDL_CLK_GPU3D_CORE]   = imx_clk_gate2("gpu3d_core",    "gpu3d_core_podf",   base + 0x6c, 26);
        clk[IMX6QDL_CLK_HDMI_IAHB]    = imx_clk_gate2("hdmi_iahb",     "ahb",               base + 0x70, 0);
-       clk[IMX6QDL_CLK_HDMI_ISFR]    = imx_clk_gate2("hdmi_isfr",     "pll3_pfd1_540m",    base + 0x70, 4);
+       clk[IMX6QDL_CLK_HDMI_ISFR]    = imx_clk_gate2("hdmi_isfr",     "video_27m",         base + 0x70, 4);
        clk[IMX6QDL_CLK_I2C1]         = imx_clk_gate2("i2c1",          "ipg_per",           base + 0x70, 6);
        clk[IMX6QDL_CLK_I2C2]         = imx_clk_gate2("i2c2",          "ipg_per",           base + 0x70, 8);
        clk[IMX6QDL_CLK_I2C3]         = imx_clk_gate2("i2c3",          "ipg_per",           base + 0x70, 10);
@@ -415,7 +417,9 @@ static void __init imx6q_clocks_init(struct device_node *ccm_node)
        clk[IMX6QDL_CLK_LDB_DI0]      = imx_clk_gate2("ldb_di0",       "ldb_di0_podf",      base + 0x74, 12);
        clk[IMX6QDL_CLK_LDB_DI1]      = imx_clk_gate2("ldb_di1",       "ldb_di1_podf",      base + 0x74, 14);
        clk[IMX6QDL_CLK_IPU2_DI1]     = imx_clk_gate2("ipu2_di1",      "ipu2_di1_sel",      base + 0x74, 10);
-       clk[IMX6QDL_CLK_HSI_TX]       = imx_clk_gate2("hsi_tx",        "hsi_tx_podf",       base + 0x74, 16);
+       clk[IMX6QDL_CLK_HSI_TX]       = imx_clk_gate2_shared("hsi_tx", "hsi_tx_podf",       base + 0x74, 16, &share_count_mipi_core_cfg);
+       clk[IMX6QDL_CLK_MIPI_CORE_CFG] = imx_clk_gate2_shared("mipi_core_cfg", "video_27m", base + 0x74, 16, &share_count_mipi_core_cfg);
+       clk[IMX6QDL_CLK_MIPI_IPG]     = imx_clk_gate2_shared("mipi_ipg", "ipg",             base + 0x74, 16, &share_count_mipi_core_cfg);
        if (cpu_is_imx6dl())
                /*
                 * The multiplexer and divider of the imx6q clock gpu2d get
index 1028b6c505c496b315b90c65911e1cda403ac4fe..0f04e30b726d22e43ad725427bf2731295a705e7 100644 (file)
@@ -23,13 +23,11 @@ struct of_device_id;
 
 void mx1_map_io(void);
 void mx21_map_io(void);
-void mx25_map_io(void);
 void mx27_map_io(void);
 void mx31_map_io(void);
 void mx35_map_io(void);
 void imx1_init_early(void);
 void imx21_init_early(void);
-void imx25_init_early(void);
 void imx27_init_early(void);
 void imx31_init_early(void);
 void imx35_init_early(void);
@@ -37,13 +35,11 @@ void mxc_init_irq(void __iomem *);
 void tzic_init_irq(void);
 void mx1_init_irq(void);
 void mx21_init_irq(void);
-void mx25_init_irq(void);
 void mx27_init_irq(void);
 void mx31_init_irq(void);
 void mx35_init_irq(void);
 void imx1_soc_init(void);
 void imx21_soc_init(void);
-void imx25_soc_init(void);
 void imx27_soc_init(void);
 void imx31_soc_init(void);
 void imx35_soc_init(void);
@@ -51,7 +47,6 @@ void epit_timer_init(void __iomem *base, int irq);
 void mxc_timer_init(void __iomem *, int);
 int mx1_clocks_init(unsigned long fref);
 int mx21_clocks_init(unsigned long lref, unsigned long fref);
-int mx25_clocks_init(void);
 int mx27_clocks_init(unsigned long fref);
 int mx31_clocks_init(unsigned long fref);
 int mx35_clocks_init(void);
@@ -71,6 +66,7 @@ unsigned int imx_get_soc_revision(void);
 void imx_init_revision_from_anatop(void);
 struct device *imx_soc_device_init(void);
 void imx6_enable_rbc(bool enable);
+void imx_gpc_check_dt(void);
 void imx_gpc_set_arm_power_in_lpm(bool power_off);
 void imx_gpc_set_arm_power_up_timing(u32 sw2iso, u32 sw);
 void imx_gpc_set_arm_power_down_timing(u32 sw2iso, u32 sw);
@@ -106,7 +102,6 @@ static inline void imx_scu_map_io(void) {}
 static inline void imx_smp_prepare(void) {}
 #endif
 void imx_src_init(void);
-void imx_gpc_init(void);
 void imx_gpc_pre_suspend(bool arm_power_off);
 void imx_gpc_post_resume(void);
 void imx_gpc_mask_all(void);
index 96ec64b5ff7d3e056ddfdea0f3918278732ea0c1..d0ad67e802d33962c1f10f9bfabe9e3b01c7c903 100644 (file)
@@ -11,6 +11,8 @@
  */
 #include <linux/module.h>
 #include <linux/io.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
 
 #include "iim.h"
 #include "hardware.h"
@@ -20,8 +22,15 @@ static int mx25_cpu_rev = -1;
 static int mx25_read_cpu_rev(void)
 {
        u32 rev;
+       void __iomem *iim_base;
+       struct device_node *np;
+
+       np = of_find_compatible_node(NULL, NULL, "fsl,imx25-iim");
+       iim_base = of_iomap(np, 0);
+       BUG_ON(!iim_base);
+       rev = readl(iim_base + MXC_IIMSREV);
+       iounmap(iim_base);
 
-       rev = __raw_readl(MX25_IO_ADDRESS(MX25_IIM_BASE_ADDR + MXC_IIMSREV));
        switch (rev) {
        case 0x00:
                return IMX_CHIP_REVISION_1_0;
diff --git a/arch/arm/mach-imx/devices-imx25.h b/arch/arm/mach-imx/devices-imx25.h
deleted file mode 100644 (file)
index 61a114c..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (C) 2010 Pengutronix
- * Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de>
- *
- * This program is free software; you can redistribute it and/or modify it under
- * the terms of the GNU General Public License version 2 as published by the
- * Free Software Foundation.
- */
-#include "devices/devices-common.h"
-
-extern const struct imx_fec_data imx25_fec_data;
-#define imx25_add_fec(pdata)   \
-       imx_add_fec(&imx25_fec_data, pdata)
-
-extern const struct imx_flexcan_data imx25_flexcan_data[];
-#define imx25_add_flexcan(id)  \
-       imx_add_flexcan(&imx25_flexcan_data[id])
-#define imx25_add_flexcan0()           imx25_add_flexcan(0)
-#define imx25_add_flexcan1()           imx25_add_flexcan(1)
-
-extern const struct imx_fsl_usb2_udc_data imx25_fsl_usb2_udc_data;
-#define imx25_add_fsl_usb2_udc(pdata)  \
-       imx_add_fsl_usb2_udc(&imx25_fsl_usb2_udc_data, pdata)
-
-extern struct imx_imxdi_rtc_data imx25_imxdi_rtc_data;
-#define imx25_add_imxdi_rtc()  \
-       imx_add_imxdi_rtc(&imx25_imxdi_rtc_data)
-
-extern const struct imx_imx2_wdt_data imx25_imx2_wdt_data;
-#define imx25_add_imx2_wdt()   \
-       imx_add_imx2_wdt(&imx25_imx2_wdt_data)
-
-extern const struct imx_imx_fb_data imx25_imx_fb_data;
-#define imx25_add_imx_fb(pdata)        \
-       imx_add_imx_fb(&imx25_imx_fb_data, pdata)
-
-extern const struct imx_imx_i2c_data imx25_imx_i2c_data[];
-#define imx25_add_imx_i2c(id, pdata)   \
-       imx_add_imx_i2c(&imx25_imx_i2c_data[id], pdata)
-#define imx25_add_imx_i2c0(pdata)      imx25_add_imx_i2c(0, pdata)
-#define imx25_add_imx_i2c1(pdata)      imx25_add_imx_i2c(1, pdata)
-#define imx25_add_imx_i2c2(pdata)      imx25_add_imx_i2c(2, pdata)
-
-extern const struct imx_imx_keypad_data imx25_imx_keypad_data;
-#define imx25_add_imx_keypad(pdata)    \
-       imx_add_imx_keypad(&imx25_imx_keypad_data, pdata)
-
-extern const struct imx_imx_ssi_data imx25_imx_ssi_data[];
-#define imx25_add_imx_ssi(id, pdata)   \
-       imx_add_imx_ssi(&imx25_imx_ssi_data[id], pdata)
-
-extern const struct imx_imx_uart_1irq_data imx25_imx_uart_data[];
-#define imx25_add_imx_uart(id, pdata)  \
-       imx_add_imx_uart_1irq(&imx25_imx_uart_data[id], pdata)
-#define imx25_add_imx_uart0(pdata)     imx25_add_imx_uart(0, pdata)
-#define imx25_add_imx_uart1(pdata)     imx25_add_imx_uart(1, pdata)
-#define imx25_add_imx_uart2(pdata)     imx25_add_imx_uart(2, pdata)
-#define imx25_add_imx_uart3(pdata)     imx25_add_imx_uart(3, pdata)
-#define imx25_add_imx_uart4(pdata)     imx25_add_imx_uart(4, pdata)
-
-extern const struct imx_mx2_camera_data imx25_mx2_camera_data;
-#define imx25_add_mx2_camera(pdata)    \
-       imx_add_mx2_camera(&imx25_mx2_camera_data, pdata)
-
-extern const struct imx_mxc_ehci_data imx25_mxc_ehci_otg_data;
-#define imx25_add_mxc_ehci_otg(pdata)  \
-       imx_add_mxc_ehci(&imx25_mxc_ehci_otg_data, pdata)
-extern const struct imx_mxc_ehci_data imx25_mxc_ehci_hs_data;
-#define imx25_add_mxc_ehci_hs(pdata)   \
-       imx_add_mxc_ehci(&imx25_mxc_ehci_hs_data, pdata)
-
-extern const struct imx_mxc_nand_data imx25_mxc_nand_data;
-#define imx25_add_mxc_nand(pdata)      \
-       imx_add_mxc_nand(&imx25_mxc_nand_data, pdata)
-
-extern const struct imx_sdhci_esdhc_imx_data imx25_sdhci_esdhc_imx_data[];
-#define imx25_add_sdhci_esdhc_imx(id, pdata)   \
-       imx_add_sdhci_esdhc_imx(&imx25_sdhci_esdhc_imx_data[id], pdata)
-
-extern const struct imx_spi_imx_data imx25_cspi_data[];
-#define imx25_add_spi_imx(id, pdata)   \
-       imx_add_spi_imx(&imx25_cspi_data[id], pdata)
-#define imx25_add_spi_imx0(pdata)      imx25_add_spi_imx(0, pdata)
-#define imx25_add_spi_imx1(pdata)      imx25_add_spi_imx(1, pdata)
-#define imx25_add_spi_imx2(pdata)      imx25_add_spi_imx(2, pdata)
index 1d2cc1805f3e51d00f4f7db8d0e3f1cad318a0f0..3a552989248ed309020a0c159480f8c569f71dc9 100644 (file)
@@ -21,9 +21,6 @@ config IMX_HAVE_PLATFORM_IMX27_CODA
 config IMX_HAVE_PLATFORM_IMX2_WDT
        bool
 
-config IMX_HAVE_PLATFORM_IMXDI_RTC
-       bool
-
 config IMX_HAVE_PLATFORM_IMX_FB
        bool
 
index 8fdb12b4ca7ee12d12b9798e66d60c3dbac998fe..e5cf587bc1a0ed346ec128e3ff7cff3f990a477d 100644 (file)
@@ -8,7 +8,6 @@ obj-y += platform-gpio-mxc.o
 obj-$(CONFIG_IMX_HAVE_PLATFORM_IMX21_HCD) += platform-imx21-hcd.o
 obj-$(CONFIG_IMX_HAVE_PLATFORM_IMX27_CODA) += platform-imx27-coda.o
 obj-$(CONFIG_IMX_HAVE_PLATFORM_IMX2_WDT) += platform-imx2-wdt.o
-obj-$(CONFIG_IMX_HAVE_PLATFORM_IMXDI_RTC) += platform-imxdi_rtc.o
 obj-y += platform-imx-dma.o
 obj-$(CONFIG_IMX_HAVE_PLATFORM_IMX_FB) += platform-imx-fb.o
 obj-$(CONFIG_IMX_HAVE_PLATFORM_IMX_I2C) += platform-imx-i2c.o
index d86f9250b4ee87292ce8758a4538cd64a8b4ac92..b403a4fe2892b3773f3b92ea6f8520b077269588 100644 (file)
                .irq = soc ## _INT_FEC,                                 \
        }
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_fec_data imx25_fec_data __initconst =
-       imx_fec_data_entry_single(MX25, "imx25-fec");
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_fec_data imx27_fec_data __initconst =
        imx_fec_data_entry_single(MX27, "imx27-fec");
index 23b0061347cba81f5fd8c63add9d8d57b7585d82..25e1de6f3a47fd5ebca7f7c0164e7706b4bece8c 100644 (file)
                .irq = soc ## _INT_USB_OTG,                             \
        }
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_fsl_usb2_udc_data imx25_fsl_usb2_udc_data __initconst =
-       imx_fsl_usb2_udc_data_entry_single(MX25, "imx-udc-mx27");
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_fsl_usb2_udc_data imx27_fsl_usb2_udc_data __initconst =
        imx_fsl_usb2_udc_data_entry_single(MX27, "imx-udc-mx27");
index 25a47c616b2d7c2b855eaf510b84b4d466b51d62..7df6328306f964dcf5c698f30c2bf4aeabb757f1 100644 (file)
@@ -29,11 +29,6 @@ const struct imx_imx_fb_data imx21_imx_fb_data __initconst =
        imx_imx_fb_data_entry_single(MX21, "imx21-fb", SZ_4K);
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx_fb_data imx25_imx_fb_data __initconst =
-       imx_imx_fb_data_entry_single(MX25, "imx21-fb", SZ_16K);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx_fb_data imx27_imx_fb_data __initconst =
        imx_imx_fb_data_entry_single(MX27, "imx21-fb", SZ_4K);
index 644ac26898823ac617c5892a5c41571af254cf00..ae9791522fc80e70ac8df2dcd2791f8a3f341a6a 100644 (file)
@@ -31,16 +31,6 @@ const struct imx_imx_i2c_data imx21_imx_i2c_data __initconst =
        imx_imx_i2c_data_entry_single(MX21, "imx21-i2c", 0, , SZ_4K);
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx_i2c_data imx25_imx_i2c_data[] __initconst = {
-#define imx25_imx_i2c_data_entry(_id, _hwid)                           \
-       imx_imx_i2c_data_entry(MX25, "imx21-i2c", _id, _hwid, SZ_16K)
-       imx25_imx_i2c_data_entry(0, 1),
-       imx25_imx_i2c_data_entry(1, 2),
-       imx25_imx_i2c_data_entry(2, 3),
-};
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx_i2c_data imx27_imx_i2c_data[] __initconst = {
 #define imx27_imx_i2c_data_entry(_id, _hwid)                           \
index f42200b7aca96044b8d10dbedb10cfe680ab5a80..479e4d70dbf92c43812124f72add5cd6d87d21c0 100644 (file)
@@ -21,11 +21,6 @@ const struct imx_imx_keypad_data imx21_imx_keypad_data __initconst =
        imx_imx_keypad_data_entry_single(MX21, SZ_16);
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx_keypad_data imx25_imx_keypad_data __initconst =
-       imx_imx_keypad_data_entry_single(MX25, SZ_16K);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx_keypad_data imx27_imx_keypad_data __initconst =
        imx_imx_keypad_data_entry_single(MX27, SZ_16);
index 1c7c721ebff1ba04ef2f73e1025aace0758769c1..6f0e94eb29eeec2c549a0110beb3234357e9c08d 100644 (file)
@@ -30,15 +30,6 @@ const struct imx_imx_ssi_data imx21_imx_ssi_data[] __initconst = {
 };
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx_ssi_data imx25_imx_ssi_data[] __initconst = {
-#define imx25_imx_ssi_data_entry(_id, _hwid)                           \
-       imx_imx_ssi_data_entry(MX25, _id, _hwid, SZ_4K)
-       imx25_imx_ssi_data_entry(0, 1),
-       imx25_imx_ssi_data_entry(1, 2),
-};
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx_ssi_data imx27_imx_ssi_data[] __initconst = {
 #define imx27_imx_ssi_data_entry(_id, _hwid)                           \
index 8c01836bc1d4b03c8df84a28cda9cc433d9a825c..6962cff4a9504569cc333b6e538bdbc54dfa1a36 100644 (file)
@@ -47,18 +47,6 @@ const struct imx_imx_uart_1irq_data imx21_imx_uart_data[] __initconst = {
 };
 #endif
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx_uart_1irq_data imx25_imx_uart_data[] __initconst = {
-#define imx25_imx_uart_data_entry(_id, _hwid)                          \
-       imx_imx_uart_1irq_data_entry(MX25, _id, _hwid, SZ_16K)
-       imx25_imx_uart_data_entry(0, 1),
-       imx25_imx_uart_data_entry(1, 2),
-       imx25_imx_uart_data_entry(2, 3),
-       imx25_imx_uart_data_entry(3, 4),
-       imx25_imx_uart_data_entry(4, 5),
-};
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx_uart_1irq_data imx27_imx_uart_data[] __initconst = {
 #define imx27_imx_uart_data_entry(_id, _hwid)                          \
index 54f63bc25ca4d1e7974668577324ef2b61285a07..8c134c8d7500349f1040cca3fcad40ea851a1bcd 100644 (file)
@@ -25,11 +25,6 @@ const struct imx_imx2_wdt_data imx21_imx2_wdt_data __initconst =
        imx_imx2_wdt_data_entry_single(MX21, 0, , SZ_4K);
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imx2_wdt_data imx25_imx2_wdt_data __initconst =
-       imx_imx2_wdt_data_entry_single(MX25, 0, , SZ_16K);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_imx2_wdt_data imx27_imx2_wdt_data __initconst =
        imx_imx2_wdt_data_entry_single(MX27, 0, , SZ_4K);
diff --git a/arch/arm/mach-imx/devices/platform-imxdi_rtc.c b/arch/arm/mach-imx/devices/platform-imxdi_rtc.c
deleted file mode 100644 (file)
index 5bb490d..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (C) 2010 Pengutronix
- * Uwe Kleine-Koenig <u.kleine-koenig@pengutronix.de>
- *
- * This program is free software; you can redistribute it and/or modify it under
- * the terms of the GNU General Public License version 2 as published by the
- * Free Software Foundation.
- */
-#include <asm/sizes.h>
-
-#include "../hardware.h"
-#include "devices-common.h"
-
-#define imx_imxdi_rtc_data_entry_single(soc)                           \
-       {                                                               \
-               .iobase = soc ## _DRYICE_BASE_ADDR,                     \
-               .irq = soc ## _INT_DRYICE,                              \
-       }
-
-#ifdef CONFIG_SOC_IMX25
-const struct imx_imxdi_rtc_data imx25_imxdi_rtc_data __initconst =
-       imx_imxdi_rtc_data_entry_single(MX25);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
-struct platform_device *__init imx_add_imxdi_rtc(
-               const struct imx_imxdi_rtc_data *data)
-{
-       struct resource res[] = {
-               {
-                       .start = data->iobase,
-                       .end = data->iobase + SZ_16K - 1,
-                       .flags = IORESOURCE_MEM,
-               }, {
-                       .start = data->irq,
-                       .end = data->irq,
-                       .flags = IORESOURCE_IRQ,
-               },
-       };
-
-       return imx_add_platform_device("imxdi_rtc", 0,
-                       res, ARRAY_SIZE(res), NULL, 0);
-}
index b53e1f348f518f5de7ec9aa8745a7299d5c26df4..4c377c33242c75b31bfe8849a5662cb770486223 100644 (file)
                .irqemmaprp = soc ## _INT_EMMAPRP,                      \
        }
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_mx2_camera_data imx25_mx2_camera_data __initconst =
-       imx_mx2_camera_data_entry_single(MX25, "imx25-camera");
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_mx2_camera_data imx27_mx2_camera_data __initconst =
        imx_mx2_camera_data_entry_single_emma(MX27, "imx27-camera");
index 296353662ff025dac519c7cffbb112f601dc007f..4537abd2a8f23df0d8323165473f65aca6258015 100644 (file)
                .irq = soc ## _INT_USB_ ## hs,                          \
        }
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_mxc_ehci_data imx25_mxc_ehci_otg_data __initconst =
-       imx_mxc_ehci_data_entry_single(MX25, 0, OTG);
-const struct imx_mxc_ehci_data imx25_mxc_ehci_hs_data __initconst =
-       imx_mxc_ehci_data_entry_single(MX25, 1, HS);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_mxc_ehci_data imx27_mxc_ehci_otg_data __initconst =
        imx_mxc_ehci_data_entry_single(MX27, 0, OTG);
index fa618a34f4625f6df8a5759116434fcd682eda18..676df4920c7b6d6e06a7e86309c5d1455a3c1648 100644 (file)
@@ -34,11 +34,6 @@ const struct imx_mxc_nand_data imx21_mxc_nand_data __initconst =
        imx_mxc_nand_data_entry_single(MX21, "imx21-nand", SZ_4K);
 #endif /* ifdef CONFIG_SOC_IMX21 */
 
-#ifdef CONFIG_SOC_IMX25
-const struct imx_mxc_nand_data imx25_mxc_nand_data __initconst =
-       imx_mxc_nand_data_entry_single(MX25, "imx25-nand", SZ_8K);
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_mxc_nand_data imx27_mxc_nand_data __initconst =
        imx_mxc_nand_data_entry_single(MX27, "imx27-nand", SZ_4K);
index aca825d74c48761dabcecc6f54467520036bc698..5e9707b47f92925078200bdd363982617ece4996 100644 (file)
@@ -39,17 +39,6 @@ const struct imx_spi_imx_data imx21_cspi_data[] __initconst = {
 };
 #endif
 
-#ifdef CONFIG_SOC_IMX25
-/* i.mx25 has the i.mx35 type cspi */
-const struct imx_spi_imx_data imx25_cspi_data[] __initconst = {
-#define imx25_cspi_data_entry(_id, _hwid)                              \
-       imx_spi_imx_data_entry(MX25, CSPI, "imx35-cspi", _id, _hwid, SZ_16K)
-       imx25_cspi_data_entry(0, 1),
-       imx25_cspi_data_entry(1, 2),
-       imx25_cspi_data_entry(2, 3),
-};
-#endif /* ifdef CONFIG_SOC_IMX25 */
-
 #ifdef CONFIG_SOC_IMX27
 const struct imx_spi_imx_data imx27_cspi_data[] __initconst = {
 #define imx27_cspi_data_entry(_id, _hwid)                              \
diff --git a/arch/arm/mach-imx/ehci-imx25.c b/arch/arm/mach-imx/ehci-imx25.c
deleted file mode 100644 (file)
index 42a5a3d..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright (c) 2009 Daniel Mack <daniel@caiaq.de>
- * Copyright (C) 2010 Freescale Semiconductor, Inc.
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation; either version 2 of the License, or (at your
- * option) any later version.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * for more details.
- */
-
-#include <linux/platform_device.h>
-#include <linux/io.h>
-#include <linux/platform_data/usb-ehci-mxc.h>
-
-#include "ehci.h"
-#include "hardware.h"
-
-#define USBCTRL_OTGBASE_OFFSET 0x600
-
-#define MX25_OTG_SIC_SHIFT     29
-#define MX25_OTG_SIC_MASK      (0x3 << MX25_OTG_SIC_SHIFT)
-#define MX25_OTG_PM_BIT                (1 << 24)
-#define MX25_OTG_PP_BIT                (1 << 11)
-#define MX25_OTG_OCPOL_BIT     (1 << 3)
-
-#define MX25_H1_SIC_SHIFT      21
-#define MX25_H1_SIC_MASK       (0x3 << MX25_H1_SIC_SHIFT)
-#define MX25_H1_PP_BIT         (1 << 18)
-#define MX25_H1_PM_BIT         (1 << 16)
-#define MX25_H1_IPPUE_UP_BIT   (1 << 7)
-#define MX25_H1_IPPUE_DOWN_BIT (1 << 6)
-#define MX25_H1_TLL_BIT                (1 << 5)
-#define MX25_H1_USBTE_BIT      (1 << 4)
-#define MX25_H1_OCPOL_BIT      (1 << 2)
-
-int mx25_initialize_usb_hw(int port, unsigned int flags)
-{
-       unsigned int v;
-
-       v = readl(MX25_IO_ADDRESS(MX25_USB_BASE_ADDR + USBCTRL_OTGBASE_OFFSET));
-
-       switch (port) {
-       case 0: /* OTG port */
-               v &= ~(MX25_OTG_SIC_MASK | MX25_OTG_PM_BIT | MX25_OTG_PP_BIT |
-                       MX25_OTG_OCPOL_BIT);
-               v |= (flags & MXC_EHCI_INTERFACE_MASK) << MX25_OTG_SIC_SHIFT;
-
-               if (!(flags & MXC_EHCI_POWER_PINS_ENABLED))
-                       v |= MX25_OTG_PM_BIT;
-
-               if (flags & MXC_EHCI_PWR_PIN_ACTIVE_HIGH)
-                       v |= MX25_OTG_PP_BIT;
-
-               if (!(flags & MXC_EHCI_OC_PIN_ACTIVE_LOW))
-                       v |= MX25_OTG_OCPOL_BIT;
-
-               break;
-       case 1: /* H1 port */
-               v &= ~(MX25_H1_SIC_MASK | MX25_H1_PM_BIT | MX25_H1_PP_BIT |
-                       MX25_H1_OCPOL_BIT | MX25_H1_TLL_BIT | MX25_H1_USBTE_BIT |
-                       MX25_H1_IPPUE_DOWN_BIT | MX25_H1_IPPUE_UP_BIT);
-               v |= (flags & MXC_EHCI_INTERFACE_MASK) << MX25_H1_SIC_SHIFT;
-
-               if (!(flags & MXC_EHCI_POWER_PINS_ENABLED))
-                       v |= MX25_H1_PM_BIT;
-
-               if (flags & MXC_EHCI_PWR_PIN_ACTIVE_HIGH)
-                       v |= MX25_H1_PP_BIT;
-
-               if (!(flags & MXC_EHCI_OC_PIN_ACTIVE_LOW))
-                       v |= MX25_H1_OCPOL_BIT;
-
-               if (!(flags & MXC_EHCI_TTL_ENABLED))
-                       v |= MX25_H1_TLL_BIT;
-
-               if (flags & MXC_EHCI_INTERNAL_PHY)
-                       v |= MX25_H1_USBTE_BIT;
-
-               if (flags & MXC_EHCI_IPPUE_DOWN)
-                       v |= MX25_H1_IPPUE_DOWN_BIT;
-
-               if (flags & MXC_EHCI_IPPUE_UP)
-                       v |= MX25_H1_IPPUE_UP_BIT;
-
-               break;
-       default:
-               return -EINVAL;
-       }
-
-       writel(v, MX25_IO_ADDRESS(MX25_USB_BASE_ADDR + USBCTRL_OTGBASE_OFFSET));
-
-       return 0;
-}
-
diff --git a/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c b/arch/arm/mach-imx/eukrea_mbimxsd25-baseboard.c
deleted file mode 100644 (file)
index e77cc3a..0000000
+++ /dev/null
@@ -1,310 +0,0 @@
-/*
- * Copyright (C) 2010 Eric Benard - eric@eukrea.com
- *
- * Based on pcm970-baseboard.c which is :
- * Copyright (C) 2008 Juergen Beisert (kernel@pengutronix.de)
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- */
-
-#include <linux/gpio.h>
-#include <linux/leds.h>
-#include <linux/platform_device.h>
-#include <linux/input.h>
-#include <linux/spi/spi.h>
-#include <video/platform_lcd.h>
-
-#include <asm/mach-types.h>
-#include <asm/mach/arch.h>
-
-#include "common.h"
-#include "devices-imx25.h"
-#include "hardware.h"
-#include "iomux-mx25.h"
-#include "mx25.h"
-
-static iomux_v3_cfg_t eukrea_mbimxsd_pads[] = {
-       /* LCD */
-       MX25_PAD_LD0__LD0,
-       MX25_PAD_LD1__LD1,
-       MX25_PAD_LD2__LD2,
-       MX25_PAD_LD3__LD3,
-       MX25_PAD_LD4__LD4,
-       MX25_PAD_LD5__LD5,
-       MX25_PAD_LD6__LD6,
-       MX25_PAD_LD7__LD7,
-       MX25_PAD_LD8__LD8,
-       MX25_PAD_LD9__LD9,
-       MX25_PAD_LD10__LD10,
-       MX25_PAD_LD11__LD11,
-       MX25_PAD_LD12__LD12,
-       MX25_PAD_LD13__LD13,
-       MX25_PAD_LD14__LD14,
-       MX25_PAD_LD15__LD15,
-       MX25_PAD_GPIO_E__LD16,
-       MX25_PAD_GPIO_F__LD17,
-       MX25_PAD_HSYNC__HSYNC,
-       MX25_PAD_VSYNC__VSYNC,
-       MX25_PAD_LSCLK__LSCLK,
-       MX25_PAD_OE_ACD__OE_ACD,
-       MX25_PAD_CONTRAST__CONTRAST,
-       /* LCD_PWR */
-       MX25_PAD_PWM__GPIO_1_26,
-       /* LED */
-       MX25_PAD_POWER_FAIL__GPIO_3_19,
-       /* SWITCH */
-       MX25_PAD_VSTBY_ACK__GPIO_3_18,
-       /* UART2 */
-       MX25_PAD_UART2_RTS__UART2_RTS,
-       MX25_PAD_UART2_CTS__UART2_CTS,
-       MX25_PAD_UART2_TXD__UART2_TXD,
-       MX25_PAD_UART2_RXD__UART2_RXD,
-       /* SD1 */
-       MX25_PAD_SD1_CMD__SD1_CMD,
-       MX25_PAD_SD1_CLK__SD1_CLK,
-       MX25_PAD_SD1_DATA0__SD1_DATA0,
-       MX25_PAD_SD1_DATA1__SD1_DATA1,
-       MX25_PAD_SD1_DATA2__SD1_DATA2,
-       MX25_PAD_SD1_DATA3__SD1_DATA3,
-       /* SD1 CD */
-       MX25_PAD_DE_B__GPIO_2_20,
-       /* I2S */
-       MX25_PAD_KPP_COL3__AUD5_TXFS,
-       MX25_PAD_KPP_COL2__AUD5_TXC,
-       MX25_PAD_KPP_COL1__AUD5_RXD,
-       MX25_PAD_KPP_COL0__AUD5_TXD,
-       /* CAN */
-       MX25_PAD_GPIO_D__CAN2_RX,
-       MX25_PAD_GPIO_C__CAN2_TX,
-       /* SPI1 */
-       MX25_PAD_CSPI1_MOSI__CSPI1_MOSI,
-       MX25_PAD_CSPI1_MISO__CSPI1_MISO,
-       MX25_PAD_CSPI1_SS0__GPIO_1_16,
-       MX25_PAD_CSPI1_SS1__GPIO_1_17,
-       MX25_PAD_CSPI1_SCLK__CSPI1_SCLK,
-       MX25_PAD_CSPI1_RDY__GPIO_2_22,
-};
-
-#define GPIO_LED1              IMX_GPIO_NR(3, 19)
-#define GPIO_SWITCH1   IMX_GPIO_NR(3, 18)
-#define GPIO_SD1CD             IMX_GPIO_NR(2, 20)
-#define GPIO_LCDPWR            IMX_GPIO_NR(1, 26)
-#define        GPIO_SPI1_SS0   IMX_GPIO_NR(1, 16)
-#define        GPIO_SPI1_SS1   IMX_GPIO_NR(1, 17)
-#define        GPIO_SPI1_IRQ   IMX_GPIO_NR(2, 22)
-
-static struct imx_fb_videomode eukrea_mximxsd_modes[] = {
-       {
-               .mode   = {
-                       .name           = "CMO-QVGA",
-                       .refresh        = 60,
-                       .xres           = 320,
-                       .yres           = 240,
-                       .pixclock       = KHZ2PICOS(6500),
-                       .left_margin    = 30,
-                       .right_margin   = 38,
-                       .upper_margin   = 20,
-                       .lower_margin   = 3,
-                       .hsync_len      = 15,
-                       .vsync_len      = 4,
-               },
-               .bpp    = 16,
-               .pcr    = 0xCAD08B80,
-       }, {
-               .mode = {
-                       .name           = "DVI-VGA",
-                       .refresh        = 60,
-                       .xres           = 640,
-                       .yres           = 480,
-                       .pixclock       = 32000,
-                       .hsync_len      = 7,
-                       .left_margin    = 100,
-                       .right_margin   = 100,
-                       .vsync_len      = 7,
-                       .upper_margin   = 7,
-                       .lower_margin   = 100,
-               },
-               .pcr            = 0xFA208B80,
-               .bpp            = 16,
-       }, {
-               .mode = {
-                       .name           = "DVI-SVGA",
-                       .refresh        = 60,
-                       .xres           = 800,
-                       .yres           = 600,
-                       .pixclock       = 25000,
-                       .hsync_len      = 7,
-                       .left_margin    = 75,
-                       .right_margin   = 75,
-                       .vsync_len      = 7,
-                       .upper_margin   = 7,
-                       .lower_margin   = 75,
-               },
-               .pcr            = 0xFA208B80,
-               .bpp            = 16,
-       },
-};
-
-static const struct imx_fb_platform_data eukrea_mximxsd_fb_pdata __initconst = {
-       .mode           = eukrea_mximxsd_modes,
-       .num_modes      = ARRAY_SIZE(eukrea_mximxsd_modes),
-       .pwmr           = 0x00A903FF,
-       .lscr1          = 0x00120300,
-       .dmacr          = 0x00040060,
-};
-
-static void eukrea_mbimxsd_lcd_power_set(struct plat_lcd_data *pd,
-                                  unsigned int power)
-{
-       if (power)
-               gpio_direction_output(GPIO_LCDPWR, 1);
-       else
-               gpio_direction_output(GPIO_LCDPWR, 0);
-}
-
-static struct plat_lcd_data eukrea_mbimxsd_lcd_power_data = {
-       .set_power              = eukrea_mbimxsd_lcd_power_set,
-};
-
-static struct platform_device eukrea_mbimxsd_lcd_powerdev = {
-       .name                   = "platform-lcd",
-       .dev.platform_data      = &eukrea_mbimxsd_lcd_power_data,
-};
-
-static const struct gpio_led eukrea_mbimxsd_leds[] __initconst = {
-       {
-               .name                   = "led1",
-               .default_trigger        = "heartbeat",
-               .active_low             = 1,
-               .gpio                   = GPIO_LED1,
-       },
-};
-
-static const struct gpio_led_platform_data
-               eukrea_mbimxsd_led_info __initconst = {
-       .leds           = eukrea_mbimxsd_leds,
-       .num_leds       = ARRAY_SIZE(eukrea_mbimxsd_leds),
-};
-
-static struct gpio_keys_button eukrea_mbimxsd_gpio_buttons[] = {
-       {
-               .gpio           = GPIO_SWITCH1,
-               .code           = BTN_0,
-               .desc           = "BP1",
-               .active_low     = 1,
-               .wakeup         = 1,
-       },
-};
-
-static const struct gpio_keys_platform_data
-               eukrea_mbimxsd_button_data __initconst = {
-       .buttons        = eukrea_mbimxsd_gpio_buttons,
-       .nbuttons       = ARRAY_SIZE(eukrea_mbimxsd_gpio_buttons),
-};
-
-static struct platform_device *platform_devices[] __initdata = {
-       &eukrea_mbimxsd_lcd_powerdev,
-};
-
-static const struct imxuart_platform_data uart_pdata __initconst = {
-       .flags = IMXUART_HAVE_RTSCTS,
-};
-
-static struct i2c_board_info eukrea_mbimxsd_i2c_devices[] = {
-       {
-               I2C_BOARD_INFO("tlv320aic23", 0x1a),
-       },
-};
-
-static const
-struct imx_ssi_platform_data eukrea_mbimxsd_ssi_pdata __initconst = {
-       .flags = IMX_SSI_SYN | IMX_SSI_NET | IMX_SSI_USE_I2S_SLAVE,
-};
-
-static struct esdhc_platform_data sd1_pdata = {
-       .cd_gpio = GPIO_SD1CD,
-       .cd_type = ESDHC_CD_GPIO,
-       .wp_type = ESDHC_WP_NONE,
-};
-
-static struct spi_board_info eukrea_mbimxsd25_spi_board_info[] __initdata = {
-       {
-               .modalias = "spidev",
-               .max_speed_hz = 20000000,
-               .bus_num = 0,
-               .chip_select = 0,
-               .mode = SPI_MODE_0,
-       },
-       {
-               .modalias = "spidev",
-               .max_speed_hz = 20000000,
-               .bus_num = 0,
-               .chip_select = 1,
-               .mode = SPI_MODE_0,
-       },
-};
-
-static int eukrea_mbimxsd25_spi_cs[] = {GPIO_SPI1_SS0, GPIO_SPI1_SS1};
-
-static const struct spi_imx_master eukrea_mbimxsd25_spi0_data __initconst = {
-       .chipselect     = eukrea_mbimxsd25_spi_cs,
-       .num_chipselect = ARRAY_SIZE(eukrea_mbimxsd25_spi_cs),
-};
-
-/*
- * system init for baseboard usage. Will be called by cpuimx25 init.
- *
- * Add platform devices present on this baseboard and init
- * them from CPU side as far as required to use them later on
- */
-void __init eukrea_mbimxsd25_baseboard_init(void)
-{
-       if (mxc_iomux_v3_setup_multiple_pads(eukrea_mbimxsd_pads,
-                       ARRAY_SIZE(eukrea_mbimxsd_pads)))
-               printk(KERN_ERR "error setting mbimxsd pads !\n");
-
-       imx25_add_imx_uart1(&uart_pdata);
-       imx25_add_imx_fb(&eukrea_mximxsd_fb_pdata);
-       imx25_add_imx_ssi(0, &eukrea_mbimxsd_ssi_pdata);
-
-       imx25_add_flexcan1();
-       imx25_add_sdhci_esdhc_imx(0, &sd1_pdata);
-
-       gpio_request(GPIO_LED1, "LED1");
-       gpio_direction_output(GPIO_LED1, 1);
-       gpio_free(GPIO_LED1);
-
-       gpio_request(GPIO_SWITCH1, "SWITCH1");
-       gpio_direction_input(GPIO_SWITCH1);
-       gpio_free(GPIO_SWITCH1);
-
-       gpio_request(GPIO_LCDPWR, "LCDPWR");
-       gpio_direction_output(GPIO_LCDPWR, 1);
-
-       i2c_register_board_info(0, eukrea_mbimxsd_i2c_devices,
-                               ARRAY_SIZE(eukrea_mbimxsd_i2c_devices));
-
-       gpio_request(GPIO_SPI1_IRQ, "SPI1_IRQ");
-       gpio_direction_input(GPIO_SPI1_IRQ);
-       gpio_free(GPIO_SPI1_IRQ);
-       imx25_add_spi_imx0(&eukrea_mbimxsd25_spi0_data);
-       spi_register_board_info(eukrea_mbimxsd25_spi_board_info,
-               ARRAY_SIZE(eukrea_mbimxsd25_spi_board_info));
-
-       platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices));
-       gpio_led_register_device(-1, &eukrea_mbimxsd_led_info);
-       imx_add_gpio_keys(&eukrea_mbimxsd_button_data);
-       imx_add_platform_device("eukrea_tlv320", 0, NULL, 0, NULL, 0);
-}
index 14d6c8249b76b9c5e03a5684477d84113b5daae9..6edc940e086548fd010f158a2013615f7608d062 100644 (file)
@@ -100,7 +100,7 @@ static struct mx3fb_platform_data mx3fb_pdata __initdata = {
        .num_modes      = ARRAY_SIZE(fb_modedb),
 };
 
-static iomux_v3_cfg_t eukrea_mbimxsd_pads[] = {
+static const iomux_v3_cfg_t eukrea_mbimxsd_pads[] __initconst = {
        /* LCD */
        MX35_PAD_LD0__IPU_DISPB_DAT_0,
        MX35_PAD_LD1__IPU_DISPB_DAT_1,
index 745caa18ab2c0bc0edcfa7388e1a44c1bdf6986a..4d60005e9277ce8f33307f411dd5c0baa8a6ac7a 100644 (file)
  * http://www.gnu.org/copyleft/gpl.html
  */
 
+#include <linux/clk.h>
+#include <linux/delay.h>
 #include <linux/io.h>
 #include <linux/irq.h>
 #include <linux/of.h>
 #include <linux/of_address.h>
 #include <linux/of_irq.h>
+#include <linux/platform_device.h>
+#include <linux/pm_domain.h>
+#include <linux/regulator/consumer.h>
 #include <linux/irqchip/arm-gic.h>
 #include "common.h"
+#include "hardware.h"
 
+#define GPC_CNTR               0x000
 #define GPC_IMR1               0x008
+#define GPC_PGC_GPU_PDN                0x260
+#define GPC_PGC_GPU_PUPSCR     0x264
+#define GPC_PGC_GPU_PDNSCR     0x268
 #define GPC_PGC_CPU_PDN                0x2a0
 #define GPC_PGC_CPU_PUPSCR     0x2a4
 #define GPC_PGC_CPU_PDNSCR     0x2a8
 #define GPC_PGC_SW_SHIFT       0x0
 
 #define IMR_NUM                        4
+#define GPC_MAX_IRQS           (IMR_NUM * 32)
+
+#define GPU_VPU_PUP_REQ                BIT(1)
+#define GPU_VPU_PDN_REQ                BIT(0)
+
+#define GPC_CLK_MAX            6
+
+struct pu_domain {
+       struct generic_pm_domain base;
+       struct regulator *reg;
+       struct clk *clk[GPC_CLK_MAX];
+       int num_clks;
+};
 
 static void __iomem *gpc_base;
 static u32 gpc_wake_irqs[IMR_NUM];
@@ -77,17 +100,17 @@ void imx_gpc_post_resume(void)
 
 static int imx_gpc_irq_set_wake(struct irq_data *d, unsigned int on)
 {
-       unsigned int idx = d->hwirq / 32 - 1;
+       unsigned int idx = d->hwirq / 32;
        u32 mask;
 
-       /* Sanity check for SPI irq */
-       if (d->hwirq < 32)
-               return -EINVAL;
-
        mask = 1 << d->hwirq % 32;
        gpc_wake_irqs[idx] = on ? gpc_wake_irqs[idx] | mask :
                                  gpc_wake_irqs[idx] & ~mask;
 
+       /*
+        * Do *not* call into the parent, as the GIC doesn't have any
+        * wake-up facility...
+        */
        return 0;
 }
 
@@ -117,7 +140,7 @@ void imx_gpc_hwirq_unmask(unsigned int hwirq)
        void __iomem *reg;
        u32 val;
 
-       reg = gpc_base + GPC_IMR1 + (hwirq / 32 - 1) * 4;
+       reg = gpc_base + GPC_IMR1 + hwirq / 32 * 4;
        val = readl_relaxed(reg);
        val &= ~(1 << hwirq % 32);
        writel_relaxed(val, reg);
@@ -128,7 +151,7 @@ void imx_gpc_hwirq_mask(unsigned int hwirq)
        void __iomem *reg;
        u32 val;
 
-       reg = gpc_base + GPC_IMR1 + (hwirq / 32 - 1) * 4;
+       reg = gpc_base + GPC_IMR1 + hwirq / 32 * 4;
        val = readl_relaxed(reg);
        val |= 1 << (hwirq % 32);
        writel_relaxed(val, reg);
@@ -136,37 +159,319 @@ void imx_gpc_hwirq_mask(unsigned int hwirq)
 
 static void imx_gpc_irq_unmask(struct irq_data *d)
 {
-       /* Sanity check for SPI irq */
-       if (d->hwirq < 32)
-               return;
-
        imx_gpc_hwirq_unmask(d->hwirq);
+       irq_chip_unmask_parent(d);
 }
 
 static void imx_gpc_irq_mask(struct irq_data *d)
 {
-       /* Sanity check for SPI irq */
-       if (d->hwirq < 32)
-               return;
-
        imx_gpc_hwirq_mask(d->hwirq);
+       irq_chip_mask_parent(d);
 }
 
-void __init imx_gpc_init(void)
+static struct irq_chip imx_gpc_chip = {
+       .name                   = "GPC",
+       .irq_eoi                = irq_chip_eoi_parent,
+       .irq_mask               = imx_gpc_irq_mask,
+       .irq_unmask             = imx_gpc_irq_unmask,
+       .irq_retrigger          = irq_chip_retrigger_hierarchy,
+       .irq_set_wake           = imx_gpc_irq_set_wake,
+#ifdef CONFIG_SMP
+       .irq_set_affinity       = irq_chip_set_affinity_parent,
+#endif
+};
+
+static int imx_gpc_domain_xlate(struct irq_domain *domain,
+                               struct device_node *controller,
+                               const u32 *intspec,
+                               unsigned int intsize,
+                               unsigned long *out_hwirq,
+                               unsigned int *out_type)
 {
-       struct device_node *np;
+       if (domain->of_node != controller)
+               return -EINVAL; /* Shouldn't happen, really... */
+       if (intsize != 3)
+               return -EINVAL; /* Not GIC compliant */
+       if (intspec[0] != 0)
+               return -EINVAL; /* No PPI should point to this domain */
+
+       *out_hwirq = intspec[1];
+       *out_type = intspec[2];
+       return 0;
+}
+
+static int imx_gpc_domain_alloc(struct irq_domain *domain,
+                                 unsigned int irq,
+                                 unsigned int nr_irqs, void *data)
+{
+       struct of_phandle_args *args = data;
+       struct of_phandle_args parent_args;
+       irq_hw_number_t hwirq;
        int i;
 
-       np = of_find_compatible_node(NULL, NULL, "fsl,imx6q-gpc");
-       gpc_base = of_iomap(np, 0);
-       WARN_ON(!gpc_base);
+       if (args->args_count != 3)
+               return -EINVAL; /* Not GIC compliant */
+       if (args->args[0] != 0)
+               return -EINVAL; /* No PPI should point to this domain */
+
+       hwirq = args->args[1];
+       if (hwirq >= GPC_MAX_IRQS)
+               return -EINVAL; /* Can't deal with this */
+
+       for (i = 0; i < nr_irqs; i++)
+               irq_domain_set_hwirq_and_chip(domain, irq + i, hwirq + i,
+                                             &imx_gpc_chip, NULL);
+
+       parent_args = *args;
+       parent_args.np = domain->parent->of_node;
+       return irq_domain_alloc_irqs_parent(domain, irq, nr_irqs, &parent_args);
+}
+
+static struct irq_domain_ops imx_gpc_domain_ops = {
+       .xlate  = imx_gpc_domain_xlate,
+       .alloc  = imx_gpc_domain_alloc,
+       .free   = irq_domain_free_irqs_common,
+};
+
+static int __init imx_gpc_init(struct device_node *node,
+                              struct device_node *parent)
+{
+       struct irq_domain *parent_domain, *domain;
+       int i;
+
+       if (!parent) {
+               pr_err("%s: no parent, giving up\n", node->full_name);
+               return -ENODEV;
+       }
+
+       parent_domain = irq_find_host(parent);
+       if (!parent_domain) {
+               pr_err("%s: unable to obtain parent domain\n", node->full_name);
+               return -ENXIO;
+       }
+
+       gpc_base = of_iomap(node, 0);
+       if (WARN_ON(!gpc_base))
+               return -ENOMEM;
+
+       domain = irq_domain_add_hierarchy(parent_domain, 0, GPC_MAX_IRQS,
+                                         node, &imx_gpc_domain_ops,
+                                         NULL);
+       if (!domain) {
+               iounmap(gpc_base);
+               return -ENOMEM;
+       }
 
        /* Initially mask all interrupts */
        for (i = 0; i < IMR_NUM; i++)
                writel_relaxed(~0, gpc_base + GPC_IMR1 + i * 4);
 
-       /* Register GPC as the secondary interrupt controller behind GIC */
-       gic_arch_extn.irq_mask = imx_gpc_irq_mask;
-       gic_arch_extn.irq_unmask = imx_gpc_irq_unmask;
-       gic_arch_extn.irq_set_wake = imx_gpc_irq_set_wake;
+       return 0;
+}
+
+/*
+ * We cannot use the IRQCHIP_DECLARE macro that lives in
+ * drivers/irqchip, so we're forced to roll our own. Not very nice.
+ */
+OF_DECLARE_2(irqchip, imx_gpc, "fsl,imx6q-gpc", imx_gpc_init);
+
+void __init imx_gpc_check_dt(void)
+{
+       struct device_node *np;
+
+       np = of_find_compatible_node(NULL, NULL, "fsl,imx6q-gpc");
+       if (WARN_ON(!np ||
+                   !of_find_property(np, "interrupt-controller", NULL)))
+               pr_warn("Outdated DT detected, system is about to crash!!!\n");
+}
+
+#ifdef CONFIG_PM_GENERIC_DOMAINS
+
+static void _imx6q_pm_pu_power_off(struct generic_pm_domain *genpd)
+{
+       int iso, iso2sw;
+       u32 val;
+
+       /* Read ISO and ISO2SW power down delays */
+       val = readl_relaxed(gpc_base + GPC_PGC_GPU_PDNSCR);
+       iso = val & 0x3f;
+       iso2sw = (val >> 8) & 0x3f;
+
+       /* Gate off PU domain when GPU/VPU when powered down */
+       writel_relaxed(0x1, gpc_base + GPC_PGC_GPU_PDN);
+
+       /* Request GPC to power down GPU/VPU */
+       val = readl_relaxed(gpc_base + GPC_CNTR);
+       val |= GPU_VPU_PDN_REQ;
+       writel_relaxed(val, gpc_base + GPC_CNTR);
+
+       /* Wait ISO + ISO2SW IPG clock cycles */
+       ndelay((iso + iso2sw) * 1000 / 66);
+}
+
+static int imx6q_pm_pu_power_off(struct generic_pm_domain *genpd)
+{
+       struct pu_domain *pu = container_of(genpd, struct pu_domain, base);
+
+       _imx6q_pm_pu_power_off(genpd);
+
+       if (pu->reg)
+               regulator_disable(pu->reg);
+
+       return 0;
+}
+
+static int imx6q_pm_pu_power_on(struct generic_pm_domain *genpd)
+{
+       struct pu_domain *pu = container_of(genpd, struct pu_domain, base);
+       int i, ret, sw, sw2iso;
+       u32 val;
+
+       if (pu->reg)
+               ret = regulator_enable(pu->reg);
+       if (pu->reg && ret) {
+               pr_err("%s: failed to enable regulator: %d\n", __func__, ret);
+               return ret;
+       }
+
+       /* Enable reset clocks for all devices in the PU domain */
+       for (i = 0; i < pu->num_clks; i++)
+               clk_prepare_enable(pu->clk[i]);
+
+       /* Gate off PU domain when GPU/VPU when powered down */
+       writel_relaxed(0x1, gpc_base + GPC_PGC_GPU_PDN);
+
+       /* Read ISO and ISO2SW power down delays */
+       val = readl_relaxed(gpc_base + GPC_PGC_GPU_PUPSCR);
+       sw = val & 0x3f;
+       sw2iso = (val >> 8) & 0x3f;
+
+       /* Request GPC to power up GPU/VPU */
+       val = readl_relaxed(gpc_base + GPC_CNTR);
+       val |= GPU_VPU_PUP_REQ;
+       writel_relaxed(val, gpc_base + GPC_CNTR);
+
+       /* Wait ISO + ISO2SW IPG clock cycles */
+       ndelay((sw + sw2iso) * 1000 / 66);
+
+       /* Disable reset clocks for all devices in the PU domain */
+       for (i = 0; i < pu->num_clks; i++)
+               clk_disable_unprepare(pu->clk[i]);
+
+       return 0;
+}
+
+static struct generic_pm_domain imx6q_arm_domain = {
+       .name = "ARM",
+};
+
+static struct pu_domain imx6q_pu_domain = {
+       .base = {
+               .name = "PU",
+               .power_off = imx6q_pm_pu_power_off,
+               .power_on = imx6q_pm_pu_power_on,
+               .power_off_latency_ns = 25000,
+               .power_on_latency_ns = 2000000,
+       },
+};
+
+static struct generic_pm_domain imx6sl_display_domain = {
+       .name = "DISPLAY",
+};
+
+static struct generic_pm_domain *imx_gpc_domains[] = {
+       &imx6q_arm_domain,
+       &imx6q_pu_domain.base,
+       &imx6sl_display_domain,
+};
+
+static struct genpd_onecell_data imx_gpc_onecell_data = {
+       .domains = imx_gpc_domains,
+       .num_domains = ARRAY_SIZE(imx_gpc_domains),
+};
+
+static int imx_gpc_genpd_init(struct device *dev, struct regulator *pu_reg)
+{
+       struct clk *clk;
+       bool is_off;
+       int i;
+
+       imx6q_pu_domain.reg = pu_reg;
+
+       for (i = 0; ; i++) {
+               clk = of_clk_get(dev->of_node, i);
+               if (IS_ERR(clk))
+                       break;
+               if (i >= GPC_CLK_MAX) {
+                       dev_err(dev, "more than %d clocks\n", GPC_CLK_MAX);
+                       goto clk_err;
+               }
+               imx6q_pu_domain.clk[i] = clk;
+       }
+       imx6q_pu_domain.num_clks = i;
+
+       is_off = IS_ENABLED(CONFIG_PM);
+       if (is_off) {
+               _imx6q_pm_pu_power_off(&imx6q_pu_domain.base);
+       } else {
+               /*
+                * Enable power if compiled without CONFIG_PM in case the
+                * bootloader disabled it.
+                */
+               imx6q_pm_pu_power_on(&imx6q_pu_domain.base);
+       }
+
+       pm_genpd_init(&imx6q_pu_domain.base, NULL, is_off);
+       return of_genpd_add_provider_onecell(dev->of_node,
+                                            &imx_gpc_onecell_data);
+
+clk_err:
+       while (i--)
+               clk_put(imx6q_pu_domain.clk[i]);
+       return -EINVAL;
+}
+
+#else
+static inline int imx_gpc_genpd_init(struct device *dev, struct regulator *reg)
+{
+       return 0;
+}
+#endif /* CONFIG_PM_GENERIC_DOMAINS */
+
+static int imx_gpc_probe(struct platform_device *pdev)
+{
+       struct regulator *pu_reg;
+       int ret;
+
+       pu_reg = devm_regulator_get_optional(&pdev->dev, "pu");
+       if (PTR_ERR(pu_reg) == -ENODEV)
+               pu_reg = NULL;
+       if (IS_ERR(pu_reg)) {
+               ret = PTR_ERR(pu_reg);
+               dev_err(&pdev->dev, "failed to get pu regulator: %d\n", ret);
+               return ret;
+       }
+
+       return imx_gpc_genpd_init(&pdev->dev, pu_reg);
+}
+
+static const struct of_device_id imx_gpc_dt_ids[] = {
+       { .compatible = "fsl,imx6q-gpc" },
+       { .compatible = "fsl,imx6sl-gpc" },
+       { }
+};
+
+static struct platform_driver imx_gpc_driver = {
+       .driver = {
+               .name = "imx-gpc",
+               .owner = THIS_MODULE,
+               .of_match_table = imx_gpc_dt_ids,
+       },
+       .probe = imx_gpc_probe,
+};
+
+static int __init imx_pgc_init(void)
+{
+       return platform_driver_register(&imx_gpc_driver);
 }
+subsys_initcall(imx_pgc_init);
index 66b2b564c463ef59b27ef8145ae9f78d8c340083..76af2c03c241eff9509e6cdf6b1129763537824b 100644 (file)
 #include "mx21.h"
 #include "mx27.h"
 #include "mx1.h"
-#include "mx25.h"
 
 #define imx_map_entry(soc, name, _type)        {                               \
        .virtual = soc ## _IO_P2V(soc ## _ ## name ## _BASE_ADDR),      \
diff --git a/arch/arm/mach-imx/iomux-mx25.h b/arch/arm/mach-imx/iomux-mx25.h
deleted file mode 100644 (file)
index be51e83..0000000
+++ /dev/null
@@ -1,524 +0,0 @@
-/*
- * arch/arm/plat-mxc/include/mach/iomux-mx25.h
- *
- * Copyright (C) 2009 by Lothar Wassmann <LW@KARO-electronics.de>
- *
- * based on arch/arm/mach-mx25/mx25_pins.h
- *    Copyright 2008 Freescale Semiconductor, Inc. All Rights Reserved.
- * and
- * arch/arm/plat-mxc/include/mach/iomux-mx35.h
- *    Copyright (C) 2009 by Jan Weitzel Phytec Messtechnik GmbH <armlinux@phytec.de>
- *
- * The code contained herein is licensed under the GNU General Public
- * License. You may obtain a copy of the GNU General Public License
- * Version 2 or later at the following locations:
- *
- * http://www.opensource.org/licenses/gpl-license.html
- * http://www.gnu.org/copyleft/gpl.html
- */
-#ifndef __MACH_IOMUX_MX25_H__
-#define __MACH_IOMUX_MX25_H__
-
-#include "iomux-v3.h"
-
-/*
- * IOMUX/PAD Bit field definitions
- */
-
-#define MX25_PAD_A10__A10              IOMUX_PAD(0x000, 0x008, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A10__GPIO_4_0         IOMUX_PAD(0x000, 0x008, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A13__A13              IOMUX_PAD(0x22C, 0x00c, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A13__GPIO_4_1         IOMUX_PAD(0x22C, 0x00c, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A14__A14              IOMUX_PAD(0x230, 0x010, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A14__GPIO_2_0         IOMUX_PAD(0x230, 0x010, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A15__A15              IOMUX_PAD(0x234, 0x014, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A15__GPIO_2_1         IOMUX_PAD(0x234, 0x014, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A16__A16              IOMUX_PAD(0x000, 0x018, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A16__GPIO_2_2         IOMUX_PAD(0x000, 0x018, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A17__A17              IOMUX_PAD(0x238, 0x01c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A17__GPIO_2_3         IOMUX_PAD(0x238, 0x01c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A18__A18              IOMUX_PAD(0x23c, 0x020, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A18__GPIO_2_4         IOMUX_PAD(0x23c, 0x020, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A18__FEC_COL          IOMUX_PAD(0x23c, 0x020, 0x17, 0x504, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A19__A19              IOMUX_PAD(0x240, 0x024, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A19__FEC_RX_ER                IOMUX_PAD(0x240, 0x024, 0x17, 0x518, 0, NO_PAD_CTRL)
-#define MX25_PAD_A19__GPIO_2_5         IOMUX_PAD(0x240, 0x024, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A20__A20              IOMUX_PAD(0x244, 0x028, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A20__GPIO_2_6         IOMUX_PAD(0x244, 0x028, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A20__FEC_RDATA2       IOMUX_PAD(0x244, 0x028, 0x17, 0x50c, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A21__A21              IOMUX_PAD(0x248, 0x02c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A21__GPIO_2_7         IOMUX_PAD(0x248, 0x02c, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A21__FEC_RDATA3       IOMUX_PAD(0x248, 0x02c, 0x17, 0x510, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A22__A22              IOMUX_PAD(0x000, 0x030, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A22__GPIO_2_8         IOMUX_PAD(0x000, 0x030, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A23__A23              IOMUX_PAD(0x24c, 0x034, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A23__GPIO_2_9         IOMUX_PAD(0x24c, 0x034, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A24__A24              IOMUX_PAD(0x250, 0x038, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A24__GPIO_2_10                IOMUX_PAD(0x250, 0x038, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A24__FEC_RX_CLK       IOMUX_PAD(0x250, 0x038, 0x17, 0x514, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_A25__A25              IOMUX_PAD(0x254, 0x03c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A25__GPIO_2_11                IOMUX_PAD(0x254, 0x03c, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_A25__FEC_CRS          IOMUX_PAD(0x254, 0x03c, 0x17, 0x508, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_EB0__EB0              IOMUX_PAD(0x258, 0x040, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_EB0__AUD4_TXD         IOMUX_PAD(0x258, 0x040, 0x14, 0x464, 0, NO_PAD_CTRL)
-#define MX25_PAD_EB0__GPIO_2_12                IOMUX_PAD(0x258, 0x040, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_EB1__EB1              IOMUX_PAD(0x25c, 0x044, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_EB1__AUD4_RXD         IOMUX_PAD(0x25c, 0x044, 0x14, 0x460, 0, NO_PAD_CTRL)
-#define MX25_PAD_EB1__GPIO_2_13                IOMUX_PAD(0x25c, 0x044, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_OE__OE                        IOMUX_PAD(0x260, 0x048, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_OE__AUD4_TXC          IOMUX_PAD(0x260, 0x048, 0x14, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_OE__GPIO_2_14         IOMUX_PAD(0x260, 0x048, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CS0__CS0              IOMUX_PAD(0x000, 0x04c, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS0__GPIO_4_2         IOMUX_PAD(0x000, 0x04c, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CS1__CS1              IOMUX_PAD(0x000, 0x050, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS1__NF_CE3           IOMUX_PAD(0x000, 0x050, 0x01, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS1__GPIO_4_3         IOMUX_PAD(0x000, 0x050, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CS4__CS4              IOMUX_PAD(0x264, 0x054, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS4__NF_CE1           IOMUX_PAD(0x264, 0x054, 0x01, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS4__UART5_CTS                IOMUX_PAD(0x264, 0x054, 0x13, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS4__GPIO_3_20                IOMUX_PAD(0x264, 0x054, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CS5__CS5              IOMUX_PAD(0x268, 0x058, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS5__NF_CE2           IOMUX_PAD(0x268, 0x058, 0x01, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS5__UART5_RTS                IOMUX_PAD(0x268, 0x058, 0x13, 0x574, 0, NO_PAD_CTRL)
-#define MX25_PAD_CS5__GPIO_3_21                IOMUX_PAD(0x268, 0x058, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NF_CE0__NF_CE0                IOMUX_PAD(0x26c, 0x05c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NF_CE0__GPIO_3_22     IOMUX_PAD(0x26c, 0x05c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_ECB__ECB              IOMUX_PAD(0x270, 0x060, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_ECB__UART5_TXD_MUX    IOMUX_PAD(0x270, 0x060, 0x13, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_ECB__GPIO_3_23                IOMUX_PAD(0x270, 0x060, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LBA__LBA              IOMUX_PAD(0x274, 0x064, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_LBA__UART5_RXD_MUX    IOMUX_PAD(0x274, 0x064, 0x13, 0x578, 0, NO_PAD_CTRL)
-#define MX25_PAD_LBA__GPIO_3_24                IOMUX_PAD(0x274, 0x064, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_BCLK__BCLK            IOMUX_PAD(0x000, 0x068, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_BCLK__GPIO_4_4                IOMUX_PAD(0x000, 0x068, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_RW__RW                        IOMUX_PAD(0x278, 0x06c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_RW__AUD4_TXFS         IOMUX_PAD(0x278, 0x06c, 0x14, 0x474, 0, NO_PAD_CTRL)
-#define MX25_PAD_RW__GPIO_3_25         IOMUX_PAD(0x278, 0x06c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFWE_B__NFWE_B                IOMUX_PAD(0x000, 0x070, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NFWE_B__GPIO_3_26     IOMUX_PAD(0x000, 0x070, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFRE_B__NFRE_B                IOMUX_PAD(0x000, 0x074, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NFRE_B__GPIO_3_27     IOMUX_PAD(0x000, 0x074, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFALE__NFALE          IOMUX_PAD(0x000, 0x078, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NFALE__GPIO_3_28      IOMUX_PAD(0x000, 0x078, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFCLE__NFCLE          IOMUX_PAD(0x000, 0x07c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NFCLE__GPIO_3_29      IOMUX_PAD(0x000, 0x07c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFWP_B__NFWP_B                IOMUX_PAD(0x000, 0x080, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_NFWP_B__GPIO_3_30     IOMUX_PAD(0x000, 0x080, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_NFRB__NFRB            IOMUX_PAD(0x27c, 0x084, 0x10, 0, 0, PAD_CTL_PKE)
-#define MX25_PAD_NFRB__GPIO_3_31       IOMUX_PAD(0x27c, 0x084, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D15__D15              IOMUX_PAD(0x280, 0x088, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D15__LD16             IOMUX_PAD(0x280, 0x088, 0x01, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_D15__GPIO_4_5         IOMUX_PAD(0x280, 0x088, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D14__D14              IOMUX_PAD(0x284, 0x08c, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D14__LD17             IOMUX_PAD(0x284, 0x08c, 0x01, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_D14__GPIO_4_6         IOMUX_PAD(0x284, 0x08c, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D13__D13              IOMUX_PAD(0x288, 0x090, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D13__LD18             IOMUX_PAD(0x288, 0x090, 0x01, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_D13__GPIO_4_7         IOMUX_PAD(0x288, 0x090, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D12__D12              IOMUX_PAD(0x28c, 0x094, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D12__GPIO_4_8         IOMUX_PAD(0x28c, 0x094, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D11__D11              IOMUX_PAD(0x290, 0x098, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D11__GPIO_4_9         IOMUX_PAD(0x290, 0x098, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D10__D10              IOMUX_PAD(0x294, 0x09c, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D10__GPIO_4_10                IOMUX_PAD(0x294, 0x09c, 0x05, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D10__USBOTG_OC                IOMUX_PAD(0x294, 0x09c, 0x06, 0x57c, 0, PAD_CTL_PUS_100K_UP)
-
-#define MX25_PAD_D9__D9                        IOMUX_PAD(0x298, 0x0a0, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D9__GPIO_4_11         IOMUX_PAD(0x298, 0x0a0, 0x05, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D9__USBH2_PWR         IOMUX_PAD(0x298, 0x0a0, 0x06, 0, 0, PAD_CTL_PKE)
-
-#define MX25_PAD_D8__D8                        IOMUX_PAD(0x29c, 0x0a4, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D8__GPIO_4_12         IOMUX_PAD(0x29c, 0x0a4, 0x05, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D8__USBH2_OC          IOMUX_PAD(0x29c, 0x0a4, 0x06, 0x580, 0, PAD_CTL_PUS_100K_UP)
-
-#define MX25_PAD_D7__D7                        IOMUX_PAD(0x2a0, 0x0a8, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D7__GPIO_4_13         IOMUX_PAD(0x2a0, 0x0a8, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D6__D6                        IOMUX_PAD(0x2a4, 0x0ac, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D6__GPIO_4_14         IOMUX_PAD(0x2a4, 0x0ac, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D5__D5                        IOMUX_PAD(0x2a8, 0x0b0, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D5__GPIO_4_15         IOMUX_PAD(0x2a8, 0x0b0, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D4__D4                        IOMUX_PAD(0x2ac, 0x0b4, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D4__GPIO_4_16         IOMUX_PAD(0x2ac, 0x0b4, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D3__D3                        IOMUX_PAD(0x2b0, 0x0b8, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D3__GPIO_4_17         IOMUX_PAD(0x2b0, 0x0b8, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D2__D2                        IOMUX_PAD(0x2b4, 0x0bc, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D2__GPIO_4_18         IOMUX_PAD(0x2b4, 0x0bc, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D1__D1                        IOMUX_PAD(0x2b8, 0x0c0, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D1__GPIO_4_19         IOMUX_PAD(0x2b8, 0x0c0, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_D0__D0                        IOMUX_PAD(0x2bc, 0x0c4, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_D0__GPIO_4_20         IOMUX_PAD(0x2bc, 0x0c4, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD0__LD0              IOMUX_PAD(0x2c0, 0x0c8, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD0__CSI_D0           IOMUX_PAD(0x2c0, 0x0c8, 0x12, 0x488, 0, NO_PAD_CTRL)
-#define MX25_PAD_LD0__GPIO_2_15                IOMUX_PAD(0x2c0, 0x0c8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD1__LD1              IOMUX_PAD(0x2c4, 0x0cc, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD1__CSI_D1           IOMUX_PAD(0x2c4, 0x0cc, 0x12, 0x48c, 0, NO_PAD_CTRL)
-#define MX25_PAD_LD1__GPIO_2_16                IOMUX_PAD(0x2c4, 0x0cc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD2__LD2              IOMUX_PAD(0x2c8, 0x0d0, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD2__GPIO_2_17                IOMUX_PAD(0x2c8, 0x0d0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD3__LD3              IOMUX_PAD(0x2cc, 0x0d4, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD3__GPIO_2_18                IOMUX_PAD(0x2cc, 0x0d4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD4__LD4              IOMUX_PAD(0x2d0, 0x0d8, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD4__GPIO_2_19                IOMUX_PAD(0x2d0, 0x0d8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD5__LD5              IOMUX_PAD(0x2d4, 0x0dc, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD5__GPIO_1_19                IOMUX_PAD(0x2d4, 0x0dc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD6__LD6              IOMUX_PAD(0x2d8, 0x0e0, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD6__GPIO_1_20                IOMUX_PAD(0x2d8, 0x0e0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD7__LD7              IOMUX_PAD(0x2dc, 0x0e4, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD7__GPIO_1_21                IOMUX_PAD(0x2dc, 0x0e4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD8__LD8              IOMUX_PAD(0x2e0, 0x0e8, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD8__FEC_TX_ERR       IOMUX_PAD(0x2e0, 0x0e8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD9__LD9              IOMUX_PAD(0x2e4, 0x0ec, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD9__FEC_COL          IOMUX_PAD(0x2e4, 0x0ec, 0x15, 0x504, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_LD10__LD10            IOMUX_PAD(0x2e8, 0x0f0, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD10__FEC_RX_ER       IOMUX_PAD(0x2e8, 0x0f0, 0x15, 0x518, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_LD11__LD11            IOMUX_PAD(0x2ec, 0x0f4, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD11__FEC_RDATA2      IOMUX_PAD(0x2ec, 0x0f4, 0x15, 0x50c, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_LD12__LD12            IOMUX_PAD(0x2f0, 0x0f8, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD12__FEC_RDATA3      IOMUX_PAD(0x2f0, 0x0f8, 0x15, 0x510, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_LD13__LD13            IOMUX_PAD(0x2f4, 0x0fc, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD13__FEC_TDATA2      IOMUX_PAD(0x2f4, 0x0fc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD14__LD14            IOMUX_PAD(0x2f8, 0x100, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD14__FEC_TDATA3      IOMUX_PAD(0x2f8, 0x100, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LD15__LD15            IOMUX_PAD(0x2fc, 0x104, 0x10, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_LD15__FEC_RX_CLK      IOMUX_PAD(0x2fc, 0x104, 0x15, 0x514, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_HSYNC__HSYNC          IOMUX_PAD(0x300, 0x108, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_HSYNC__GPIO_1_22      IOMUX_PAD(0x300, 0x108, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_VSYNC__VSYNC          IOMUX_PAD(0x304, 0x10c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_VSYNC__GPIO_1_23      IOMUX_PAD(0x304, 0x10c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_LSCLK__LSCLK          IOMUX_PAD(0x308, 0x110, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_LSCLK__GPIO_1_24      IOMUX_PAD(0x308, 0x110, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_OE_ACD__OE_ACD                IOMUX_PAD(0x30c, 0x114, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_OE_ACD__GPIO_1_25     IOMUX_PAD(0x30c, 0x114, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CONTRAST__CONTRAST    IOMUX_PAD(0x310, 0x118, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CONTRAST__PWM4_PWMO   IOMUX_PAD(0x310, 0x118, 0x14, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CONTRAST__FEC_CRS     IOMUX_PAD(0x310, 0x118, 0x15, 0x508, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_PWM__PWM              IOMUX_PAD(0x314, 0x11c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_PWM__GPIO_1_26                IOMUX_PAD(0x314, 0x11c, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_PWM__USBH2_OC         IOMUX_PAD(0x314, 0x11c, 0x16, 0x580, 1, PAD_CTL_PUS_100K_UP)
-
-#define MX25_PAD_CSI_D2__CSI_D2                IOMUX_PAD(0x318, 0x120, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D2__UART5_RXD_MUX IOMUX_PAD(0x318, 0x120, 0x11, 0x578, 1, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D2__GPIO_1_27     IOMUX_PAD(0x318, 0x120, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D2__CSPI3_MOSI    IOMUX_PAD(0x318, 0x120, 0x17, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D3__CSI_D3                IOMUX_PAD(0x31c, 0x124, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D3__GPIO_1_28     IOMUX_PAD(0x31c, 0x124, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D3__CSPI3_MISO    IOMUX_PAD(0x31c, 0x124, 0x17, 0x4b4, 1, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D4__CSI_D4                IOMUX_PAD(0x320, 0x128, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D4__UART5_RTS     IOMUX_PAD(0x320, 0x128, 0x11, 0x574, 1, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D4__GPIO_1_29     IOMUX_PAD(0x320, 0x128, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D4__CSPI3_SCLK    IOMUX_PAD(0x320, 0x128, 0x17, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D5__CSI_D5                IOMUX_PAD(0x324, 0x12c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D5__GPIO_1_30     IOMUX_PAD(0x324, 0x12c, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D5__CSPI3_RDY     IOMUX_PAD(0x324, 0x12c, 0x17, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D6__CSI_D6                IOMUX_PAD(0x328, 0x130, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D6__GPIO_1_31     IOMUX_PAD(0x328, 0x130, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D7__CSI_D7                IOMUX_PAD(0x32c, 0x134, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D7__GPIO_1_6      IOMUX_PAD(0x32c, 0x134, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D8__CSI_D8                IOMUX_PAD(0x330, 0x138, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D8__GPIO_1_7      IOMUX_PAD(0x330, 0x138, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_D9__CSI_D9                IOMUX_PAD(0x334, 0x13c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_D9__GPIO_4_21     IOMUX_PAD(0x334, 0x13c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_MCLK__CSI_MCLK    IOMUX_PAD(0x338, 0x140, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_MCLK__GPIO_1_8    IOMUX_PAD(0x338, 0x140, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_VSYNC__CSI_VSYNC  IOMUX_PAD(0x33c, 0x144, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_VSYNC__GPIO_1_9   IOMUX_PAD(0x33c, 0x144, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_HSYNC__CSI_HSYNC  IOMUX_PAD(0x340, 0x148, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_HSYNC__GPIO_1_10  IOMUX_PAD(0x340, 0x148, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSI_PIXCLK__CSI_PIXCLK        IOMUX_PAD(0x344, 0x14c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSI_PIXCLK__GPIO_1_11 IOMUX_PAD(0x344, 0x14c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_I2C1_CLK__I2C1_CLK    IOMUX_PAD(0x348, 0x150, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_I2C1_CLK__GPIO_1_12   IOMUX_PAD(0x348, 0x150, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_I2C1_DAT__I2C1_DAT    IOMUX_PAD(0x34c, 0x154, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_I2C1_DAT__GPIO_1_13   IOMUX_PAD(0x34c, 0x154, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_MOSI__CSPI1_MOSI        IOMUX_PAD(0x350, 0x158, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSPI1_MOSI__GPIO_1_14 IOMUX_PAD(0x350, 0x158, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_MISO__CSPI1_MISO        IOMUX_PAD(0x354, 0x15c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSPI1_MISO__GPIO_1_15 IOMUX_PAD(0x354, 0x15c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_SS0__CSPI1_SS0  IOMUX_PAD(0x358, 0x160, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSPI1_SS0__GPIO_1_16  IOMUX_PAD(0x358, 0x160, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_SS1__CSPI1_SS1  IOMUX_PAD(0x35c, 0x164, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSPI1_SS1__GPIO_1_17  IOMUX_PAD(0x35c, 0x164, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_SCLK__CSPI1_SCLK        IOMUX_PAD(0x360, 0x168, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CSPI1_SCLK__GPIO_1_18 IOMUX_PAD(0x360, 0x168, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CSPI1_RDY__CSPI1_RDY  IOMUX_PAD(0x364, 0x16c, 0x10, 0, 0, PAD_CTL_PKE)
-#define MX25_PAD_CSPI1_RDY__GPIO_2_22  IOMUX_PAD(0x364, 0x16c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART1_RXD__UART1_RXD  IOMUX_PAD(0x368, 0x170, 0x10, 0, 0, PAD_CTL_PUS_100K_DOWN)
-#define MX25_PAD_UART1_RXD__GPIO_4_22  IOMUX_PAD(0x368, 0x170, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART1_TXD__UART1_TXD  IOMUX_PAD(0x36c, 0x174, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UART1_TXD__GPIO_4_23  IOMUX_PAD(0x36c, 0x174, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART1_RTS__UART1_RTS  IOMUX_PAD(0x370, 0x178, 0x10, 0, 0, PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_UART1_RTS__CSI_D0     IOMUX_PAD(0x370, 0x178, 0x11, 0x488, 1, NO_PAD_CTRL)
-#define MX25_PAD_UART1_RTS__GPIO_4_24  IOMUX_PAD(0x370, 0x178, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART1_CTS__UART1_CTS  IOMUX_PAD(0x374, 0x17c, 0x10, 0, 0, PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_UART1_CTS__CSI_D1     IOMUX_PAD(0x374, 0x17c, 0x11, 0x48c, 1, NO_PAD_CTRL)
-#define MX25_PAD_UART1_CTS__GPIO_4_25  IOMUX_PAD(0x374, 0x17c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART2_RXD__UART2_RXD  IOMUX_PAD(0x378, 0x180, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UART2_RXD__GPIO_4_26  IOMUX_PAD(0x378, 0x180, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART2_TXD__UART2_TXD  IOMUX_PAD(0x37c, 0x184, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UART2_TXD__GPIO_4_27  IOMUX_PAD(0x37c, 0x184, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART2_RTS__UART2_RTS  IOMUX_PAD(0x380, 0x188, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UART2_RTS__FEC_COL    IOMUX_PAD(0x380, 0x188, 0x12, 0x504, 2, NO_PAD_CTRL)
-#define MX25_PAD_UART2_RTS__GPIO_4_28  IOMUX_PAD(0x380, 0x188, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UART2_CTS__FEC_RX_ER  IOMUX_PAD(0x384, 0x18c, 0x12, 0x518, 2, NO_PAD_CTRL)
-#define MX25_PAD_UART2_CTS__UART2_CTS  IOMUX_PAD(0x384, 0x18c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UART2_CTS__GPIO_4_29  IOMUX_PAD(0x384, 0x18c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_CMD__SD1_CMD      IOMUX_PAD(0x388, 0x190, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_CMD__FEC_RDATA2   IOMUX_PAD(0x388, 0x190, 0x12, 0x50c, 2, NO_PAD_CTRL)
-#define MX25_PAD_SD1_CMD__GPIO_2_23    IOMUX_PAD(0x388, 0x190, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_CLK__SD1_CLK      IOMUX_PAD(0x38c, 0x194, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_CLK__FEC_RDATA3   IOMUX_PAD(0x38c, 0x194, 0x12, 0x510, 2, NO_PAD_CTRL)
-#define MX25_PAD_SD1_CLK__GPIO_2_24    IOMUX_PAD(0x38c, 0x194, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_DATA0__SD1_DATA0  IOMUX_PAD(0x390, 0x198, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_DATA0__GPIO_2_25  IOMUX_PAD(0x390, 0x198, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_DATA1__SD1_DATA1  IOMUX_PAD(0x394, 0x19c, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_DATA1__AUD7_RXD   IOMUX_PAD(0x394, 0x19c, 0x13, 0x478, 0, NO_PAD_CTRL)
-#define MX25_PAD_SD1_DATA1__GPIO_2_26  IOMUX_PAD(0x394, 0x19c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_DATA2__SD1_DATA2  IOMUX_PAD(0x398, 0x1a0, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_DATA2__FEC_RX_CLK IOMUX_PAD(0x398, 0x1a0, 0x15, 0x514, 2, NO_PAD_CTRL)
-#define MX25_PAD_SD1_DATA2__GPIO_2_27  IOMUX_PAD(0x398, 0x1a0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_SD1_DATA3__SD1_DATA3  IOMUX_PAD(0x39c, 0x1a4, 0x10, 0, 0, PAD_CTL_PUS_47K_UP)
-#define MX25_PAD_SD1_DATA3__FEC_CRS    IOMUX_PAD(0x39c, 0x1a4, 0x10, 0x508, 2, NO_PAD_CTRL)
-#define MX25_PAD_SD1_DATA3__GPIO_2_28  IOMUX_PAD(0x39c, 0x1a4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define KPP_CTL_ROW    (PAD_CTL_PKE | PAD_CTL_PUE | PAD_CTL_PUS_100K_UP)
-#define KPP_CTL_COL    (PAD_CTL_PKE | PAD_CTL_PUE | PAD_CTL_PUS_100K_UP | PAD_CTL_ODE)
-
-#define MX25_PAD_KPP_ROW0__KPP_ROW0    IOMUX_PAD(0x3a0, 0x1a8, 0x10, 0, 0, KPP_CTL_ROW)
-#define MX25_PAD_KPP_ROW0__GPIO_2_29   IOMUX_PAD(0x3a0, 0x1a8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_ROW1__KPP_ROW1    IOMUX_PAD(0x3a4, 0x1ac, 0x10, 0, 0, KPP_CTL_ROW)
-#define MX25_PAD_KPP_ROW1__GPIO_2_30   IOMUX_PAD(0x3a4, 0x1ac, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_ROW2__KPP_ROW2    IOMUX_PAD(0x3a8, 0x1b0, 0x10, 0, 0, KPP_CTL_ROW)
-#define MX25_PAD_KPP_ROW2__CSI_D0      IOMUX_PAD(0x3a8, 0x1b0, 0x13, 0x488, 2, NO_PAD_CTRL)
-#define MX25_PAD_KPP_ROW2__GPIO_2_31   IOMUX_PAD(0x3a8, 0x1b0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_ROW3__KPP_ROW3    IOMUX_PAD(0x3ac, 0x1b4, 0x10, 0, 0, KPP_CTL_ROW)
-#define MX25_PAD_KPP_ROW3__CSI_LD1     IOMUX_PAD(0x3ac, 0x1b4, 0x13, 0x48c, 2, NO_PAD_CTRL)
-#define MX25_PAD_KPP_ROW3__GPIO_3_0    IOMUX_PAD(0x3ac, 0x1b4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_COL0__KPP_COL0    IOMUX_PAD(0x3b0, 0x1b8, 0x10, 0, 0, KPP_CTL_COL)
-#define MX25_PAD_KPP_COL0__UART4_RXD_MUX IOMUX_PAD(0x3b0, 0x1b8, 0x11, 0x570, 1, NO_PAD_CTRL)
-#define MX25_PAD_KPP_COL0__AUD5_TXD    IOMUX_PAD(0x3b0, 0x1b8, 0x12, 0, 0, PAD_CTL_PKE | PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_KPP_COL0__GPIO_3_1    IOMUX_PAD(0x3b0, 0x1b8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_COL1__KPP_COL1    IOMUX_PAD(0x3b4, 0x1bc, 0x10, 0, 0, KPP_CTL_COL)
-#define MX25_PAD_KPP_COL1__UART4_TXD_MUX IOMUX_PAD(0x3b4, 0x1bc, 0x11, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_KPP_COL1__AUD5_RXD    IOMUX_PAD(0x3b4, 0x1bc, 0x12, 0, 0, PAD_CTL_PKE | PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_KPP_COL1__GPIO_3_2    IOMUX_PAD(0x3b4, 0x1bc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_COL2__KPP_COL2    IOMUX_PAD(0x3b8, 0x1c0, 0x10, 0, 0, KPP_CTL_COL)
-#define MX25_PAD_KPP_COL2__UART4_RTS   IOMUX_PAD(0x3b8, 0x1c0, 0x11, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_KPP_COL2__AUD5_TXC    IOMUX_PAD(0x3b8, 0x1c0, 0x12, 0, 0, PAD_CTL_PKE | PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_KPP_COL2__GPIO_3_3    IOMUX_PAD(0x3b8, 0x1c0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_KPP_COL3__KPP_COL3    IOMUX_PAD(0x3bc, 0x1c4, 0x10, 0, 0, KPP_CTL_COL)
-#define MX25_PAD_KPP_COL3__UART4_CTS   IOMUX_PAD(0x3bc, 0x1c4, 0x11, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_KPP_COL3__AUD5_TXFS   IOMUX_PAD(0x3bc, 0x1c4, 0x12, 0, 0, PAD_CTL_PKE | PAD_CTL_PUS_100K_UP)
-#define MX25_PAD_KPP_COL3__GPIO_3_4    IOMUX_PAD(0x3bc, 0x1c4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_MDC__FEC_MDC      IOMUX_PAD(0x3c0, 0x1c8, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_FEC_MDC__AUD4_TXD     IOMUX_PAD(0x3c0, 0x1c8, 0x12, 0x464, 1, NO_PAD_CTRL)
-#define MX25_PAD_FEC_MDC__GPIO_3_5     IOMUX_PAD(0x3c0, 0x1c8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_MDIO__FEC_MDIO    IOMUX_PAD(0x3c4, 0x1cc, 0x10, 0, 0, PAD_CTL_HYS | PAD_CTL_PUS_22K_UP)
-#define MX25_PAD_FEC_MDIO__AUD4_RXD    IOMUX_PAD(0x3c4, 0x1cc, 0x12, 0x460, 1, NO_PAD_CTRL)
-#define MX25_PAD_FEC_MDIO__GPIO_3_6    IOMUX_PAD(0x3c4, 0x1cc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_TDATA0__FEC_TDATA0        IOMUX_PAD(0x3c8, 0x1d0, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_FEC_TDATA0__GPIO_3_7  IOMUX_PAD(0x3c8, 0x1d0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_TDATA1__FEC_TDATA1        IOMUX_PAD(0x3cc, 0x1d4, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_FEC_TDATA1__AUD4_TXFS IOMUX_PAD(0x3cc, 0x1d4, 0x12, 0x474, 1, NO_PAD_CTRL)
-#define MX25_PAD_FEC_TDATA1__GPIO_3_8  IOMUX_PAD(0x3cc, 0x1d4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_TX_EN__FEC_TX_EN  IOMUX_PAD(0x3d0, 0x1d8, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_FEC_TX_EN__GPIO_3_9           IOMUX_PAD(0x3d0, 0x1d8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_RDATA0__FEC_RDATA0        IOMUX_PAD(0x3d4, 0x1dc, 0x10, 0, 0, PAD_CTL_PUS_100K_DOWN | NO_PAD_CTRL)
-#define MX25_PAD_FEC_RDATA0__GPIO_3_10 IOMUX_PAD(0x3d4, 0x1dc, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_RDATA1__FEC_RDATA1        IOMUX_PAD(0x3d8, 0x1e0, 0x10, 0, 0, PAD_CTL_PUS_100K_DOWN | NO_PAD_CTRL)
-#define MX25_PAD_FEC_RDATA1__GPIO_3_11 IOMUX_PAD(0x3d8, 0x1e0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_RX_DV__FEC_RX_DV  IOMUX_PAD(0x3dc, 0x1e4, 0x10, 0, 0, PAD_CTL_PUS_100K_DOWN | NO_PAD_CTRL)
-#define MX25_PAD_FEC_RX_DV__CAN2_RX    IOMUX_PAD(0x3dc, 0x1e4, 0x14, 0x484, 0, PAD_CTL_PUS_22K_UP)
-#define MX25_PAD_FEC_RX_DV__GPIO_3_12  IOMUX_PAD(0x3dc, 0x1e4, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_FEC_TX_CLK__FEC_TX_CLK        IOMUX_PAD(0x3e0, 0x1e8, 0x10, 0, 0, PAD_CTL_HYS | PAD_CTL_PUS_100K_DOWN)
-#define MX25_PAD_FEC_TX_CLK__GPIO_3_13 IOMUX_PAD(0x3e0, 0x1e8, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_RTCK__RTCK            IOMUX_PAD(0x3e4, 0x1ec, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_RTCK__OWIRE           IOMUX_PAD(0x3e4, 0x1ec, 0x11, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_RTCK__GPIO_3_14       IOMUX_PAD(0x3e4, 0x1ec, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_DE_B__DE_B            IOMUX_PAD(0x3ec, 0x1f0, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_DE_B__GPIO_2_20       IOMUX_PAD(0x3ec, 0x1f0, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_TDO__TDO              IOMUX_PAD(0x3e8, 0x000, 0x00, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_GPIO_A__GPIO_A                IOMUX_PAD(0x3f0, 0x1f4, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_A__CAN1_TX       IOMUX_PAD(0x3f0, 0x1f4, 0x16, 0, 0, PAD_CTL_PUS_22K_UP)
-#define MX25_PAD_GPIO_A__USBOTG_PWR    IOMUX_PAD(0x3f0, 0x1f4, 0x12, 0, 0, PAD_CTL_PKE)
-
-#define MX25_PAD_GPIO_B__GPIO_B                IOMUX_PAD(0x3f4, 0x1f8, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_B__CAN1_RX       IOMUX_PAD(0x3f4, 0x1f8, 0x16, 0x480, 1, PAD_CTL_PUS_22K_UP)
-#define MX25_PAD_GPIO_B__USBOTG_OC     IOMUX_PAD(0x3f4, 0x1f8, 0x12, 0x57c, 1, PAD_CTL_PUS_100K_UP)
-
-#define MX25_PAD_GPIO_C__GPIO_C                IOMUX_PAD(0x3f8, 0x1fc, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_C__CAN2_TX       IOMUX_PAD(0x3f8, 0x1fc, 0x16, 0, 0, PAD_CTL_PUS_22K_UP)
-
-#define MX25_PAD_GPIO_D__GPIO_D                IOMUX_PAD(0x3fc, 0x200, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_E__LD16          IOMUX_PAD(0x400, 0x204, 0x02, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_GPIO_D__CAN2_RX       IOMUX_PAD(0x3fc, 0x200, 0x16, 0x484, 1, PAD_CTL_PUS_22K_UP)
-
-#define MX25_PAD_GPIO_E__GPIO_E                IOMUX_PAD(0x400, 0x204, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_F__LD17          IOMUX_PAD(0x404, 0x208, 0x02, 0, 0, PAD_CTL_SRE_FAST)
-#define MX25_PAD_GPIO_E__AUD7_TXD      IOMUX_PAD(0x400, 0x204, 0x14, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_GPIO_F__GPIO_F                IOMUX_PAD(0x404, 0x208, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_GPIO_F__AUD7_TXC      IOMUX_PAD(0x404, 0x208, 0x14, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_EXT_ARMCLK__EXT_ARMCLK        IOMUX_PAD(0x000, 0x20c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_EXT_ARMCLK__GPIO_3_15 IOMUX_PAD(0x000, 0x20c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_UPLL_BYPCLK__UPLL_BYPCLK IOMUX_PAD(0x000, 0x210, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_UPLL_BYPCLK__GPIO_3_16        IOMUX_PAD(0x000, 0x210, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_VSTBY_REQ__VSTBY_REQ  IOMUX_PAD(0x408, 0x214, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_VSTBY_REQ__AUD7_TXFS  IOMUX_PAD(0x408, 0x214, 0x14, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_VSTBY_REQ__GPIO_3_17  IOMUX_PAD(0x408, 0x214, 0x15, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_VSTBY_ACK__VSTBY_ACK  IOMUX_PAD(0x40c, 0x218, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_VSTBY_ACK__GPIO_3_18  IOMUX_PAD(0x40c, 0x218, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_POWER_FAIL__POWER_FAIL        IOMUX_PAD(0x410, 0x21c, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_POWER_FAIL__AUD7_RXD  IOMUX_PAD(0x410, 0x21c, 0x14, 0x478, 1, NO_PAD_CTRL)
-#define MX25_PAD_POWER_FAIL__GPIO_3_19 IOMUX_PAD(0x410, 0x21c, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CLKO__CLKO            IOMUX_PAD(0x414, 0x220, 0x10, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CLKO__GPIO_2_21       IOMUX_PAD(0x414, 0x220, 0x15, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_BOOT_MODE0__BOOT_MODE0        IOMUX_PAD(0x000, 0x224, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_BOOT_MODE0__GPIO_4_30 IOMUX_PAD(0x000, 0x224, 0x05, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_BOOT_MODE1__BOOT_MODE1        IOMUX_PAD(0x000, 0x228, 0x00, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_BOOT_MODE1__GPIO_4_31 IOMUX_PAD(0x000, 0x228, 0x05, 0, 0, NO_PAD_CTRL)
-
-#define MX25_PAD_CTL_GRP_DVS_MISC      IOMUX_PAD(0x418, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_FEC       IOMUX_PAD(0x41c, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_JTAG      IOMUX_PAD(0x420, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_NFC       IOMUX_PAD(0x424, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_CSI       IOMUX_PAD(0x428, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_WEIM      IOMUX_PAD(0x42c, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_DDR       IOMUX_PAD(0x430, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_CRM       IOMUX_PAD(0x434, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_KPP       IOMUX_PAD(0x438, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_SDHC1     IOMUX_PAD(0x43c, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_LCD       IOMUX_PAD(0x440, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_UART      IOMUX_PAD(0x444, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_NFC       IOMUX_PAD(0x448, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_CSI       IOMUX_PAD(0x44c, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DSE_CSPI1     IOMUX_PAD(0x450, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DDRTYPE       IOMUX_PAD(0x454, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_SDHC1     IOMUX_PAD(0x458, 0x000, 0, 0, 0, NO_PAD_CTRL)
-#define MX25_PAD_CTL_GRP_DVS_LCD       IOMUX_PAD(0x45c, 0x000, 0, 0, 0, NO_PAD_CTRL)
-
-#endif /* __MACH_IOMUX_MX25_H__ */
index 0a5adba61e0b989e84604e95ecb2f2a9daa11113..2e4a0ddca76c29e5a98c8554f789293b394a3ad2 100644 (file)
@@ -114,7 +114,7 @@ enum iomux_gp_func {
  */
 int mxc_iomux_alloc_pin(unsigned int pin, const char *label);
 /*
- * setups mutliple pins
+ * setups multiple pins
  * convenient way to call the above function with tables
  */
 int mxc_iomux_setup_multiple_pins(const unsigned int *pin_list, unsigned count,
index d61f9606fc56e45c6cc0ecc2a93b20ff94f0e362..a53b2e64f98d547594243a67bf3581ac63250ea7 100644 (file)
@@ -56,9 +56,10 @@ int mxc_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
        return 0;
 }
 
-int mxc_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count)
+int mxc_iomux_v3_setup_multiple_pads(const iomux_v3_cfg_t *pad_list,
+               unsigned count)
 {
-       iomux_v3_cfg_t *p = pad_list;
+       const iomux_v3_cfg_t *p = pad_list;
        int i;
        int ret;
 
index 2fa3b5430102ed862da4a52d43e8bfe559072630..f79e165a3b3c28f25920f679ef51c37be1cb10a3 100644 (file)
@@ -128,10 +128,11 @@ typedef u64 iomux_v3_cfg_t;
 int mxc_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
 
 /*
- * setups mutliple pads
+ * setups multiple pads
  * convenient way to call the above function with tables
  */
-int mxc_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t *pad_list, unsigned count);
+int mxc_iomux_v3_setup_multiple_pads(const iomux_v3_cfg_t *pad_list,
+               unsigned count);
 
 /*
  * Initialise the iomux controller
index 62a6e02f476318593171c38fe5c5c5b80fab1bec..922ffd6ca03936637a363ed5e34ef66f97831985 100644 (file)
@@ -75,7 +75,7 @@ static struct i2c_board_info eukrea_cpuimx35_i2c_devices[] = {
        },
 };
 
-static iomux_v3_cfg_t eukrea_cpuimx35_pads[] = {
+static const iomux_v3_cfg_t eukrea_cpuimx35_pads[] __initconst = {
        /* UART1 */
        MX35_PAD_CTS1__UART1_CTS,
        MX35_PAD_RTS1__UART1_RTS,
diff --git a/arch/arm/mach-imx/mach-eukrea_cpuimx25.c b/arch/arm/mach-imx/mach-eukrea_cpuimx25.c
deleted file mode 100644 (file)
index b2ee6e0..0000000
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * Copyright 2009 Sascha Hauer, <kernel@pengutronix.de>
- * Copyright 2010 Eric Bénard - Eukréa Electromatique, <eric@eukrea.com>
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA  02110-1301, USA.
- */
-
-#include <linux/types.h>
-#include <linux/init.h>
-#include <linux/delay.h>
-#include <linux/clk.h>
-#include <linux/irq.h>
-#include <linux/gpio.h>
-#include <linux/platform_device.h>
-#include <linux/usb/otg.h>
-#include <linux/usb/ulpi.h>
-
-#include <asm/mach-types.h>
-#include <asm/mach/arch.h>
-#include <asm/mach/time.h>
-#include <asm/memory.h>
-#include <asm/mach/map.h>
-
-#include "common.h"
-#include "devices-imx25.h"
-#include "ehci.h"
-#include "eukrea-baseboards.h"
-#include "hardware.h"
-#include "iomux-mx25.h"
-#include "mx25.h"
-
-static const struct imxuart_platform_data uart_pdata __initconst = {
-       .flags = IMXUART_HAVE_RTSCTS,
-};
-
-static iomux_v3_cfg_t eukrea_cpuimx25_pads[] = {
-       /* FEC - RMII */
-       MX25_PAD_FEC_MDC__FEC_MDC,
-       MX25_PAD_FEC_MDIO__FEC_MDIO,
-       MX25_PAD_FEC_TDATA0__FEC_TDATA0,
-       MX25_PAD_FEC_TDATA1__FEC_TDATA1,
-       MX25_PAD_FEC_TX_EN__FEC_TX_EN,
-       MX25_PAD_FEC_RDATA0__FEC_RDATA0,
-       MX25_PAD_FEC_RDATA1__FEC_RDATA1,
-       MX25_PAD_FEC_RX_DV__FEC_RX_DV,
-       MX25_PAD_FEC_TX_CLK__FEC_TX_CLK,
-       /* I2C1 */
-       MX25_PAD_I2C1_CLK__I2C1_CLK,
-       MX25_PAD_I2C1_DAT__I2C1_DAT,
-};
-
-static const struct fec_platform_data mx25_fec_pdata __initconst = {
-       .phy    = PHY_INTERFACE_MODE_RMII,
-};
-
-static const struct mxc_nand_platform_data
-eukrea_cpuimx25_nand_board_info __initconst = {
-       .width          = 1,
-       .hw_ecc         = 1,
-       .flash_bbt      = 1,
-};
-
-static const struct imxi2c_platform_data
-eukrea_cpuimx25_i2c0_data __initconst = {
-       .bitrate = 100000,
-};
-
-static struct i2c_board_info eukrea_cpuimx25_i2c_devices[] = {
-       {
-               I2C_BOARD_INFO("pcf8563", 0x51),
-       },
-};
-
-static int eukrea_cpuimx25_otg_init(struct platform_device *pdev)
-{
-       return mx25_initialize_usb_hw(pdev->id, MXC_EHCI_INTERFACE_DIFF_UNI);
-}
-
-static const struct mxc_usbh_platform_data otg_pdata __initconst = {
-       .init   = eukrea_cpuimx25_otg_init,
-       .portsc = MXC_EHCI_MODE_UTMI,
-};
-
-static int eukrea_cpuimx25_usbh2_init(struct platform_device *pdev)
-{
-       return mx25_initialize_usb_hw(pdev->id, MXC_EHCI_INTERFACE_SINGLE_UNI |
-                       MXC_EHCI_INTERNAL_PHY | MXC_EHCI_IPPUE_DOWN);
-}
-
-static const struct mxc_usbh_platform_data usbh2_pdata __initconst = {
-       .init   = eukrea_cpuimx25_usbh2_init,
-       .portsc = MXC_EHCI_MODE_SERIAL,
-};
-
-static const struct fsl_usb2_platform_data otg_device_pdata __initconst = {
-       .operating_mode = FSL_USB2_DR_DEVICE,
-       .phy_mode       = FSL_USB2_PHY_UTMI,
-       .workaround     = FLS_USB2_WORKAROUND_ENGCM09152,
-};
-
-static bool otg_mode_host __initdata;
-
-static int __init eukrea_cpuimx25_otg_mode(char *options)
-{
-       if (!strcmp(options, "host"))
-               otg_mode_host = true;
-       else if (!strcmp(options, "device"))
-               otg_mode_host = false;
-       else
-               pr_info("otg_mode neither \"host\" nor \"device\". "
-                       "Defaulting to device\n");
-       return 1;
-}
-__setup("otg_mode=", eukrea_cpuimx25_otg_mode);
-
-static void __init eukrea_cpuimx25_init(void)
-{
-       imx25_soc_init();
-
-       if (mxc_iomux_v3_setup_multiple_pads(eukrea_cpuimx25_pads,
-                       ARRAY_SIZE(eukrea_cpuimx25_pads)))
-               printk(KERN_ERR "error setting cpuimx25 pads !\n");
-
-       imx25_add_imx_uart0(&uart_pdata);
-       imx25_add_mxc_nand(&eukrea_cpuimx25_nand_board_info);
-       imx25_add_imxdi_rtc();
-       imx25_add_fec(&mx25_fec_pdata);
-       imx25_add_imx2_wdt();
-
-       i2c_register_board_info(0, eukrea_cpuimx25_i2c_devices,
-                               ARRAY_SIZE(eukrea_cpuimx25_i2c_devices));
-       imx25_add_imx_i2c0(&eukrea_cpuimx25_i2c0_data);
-
-       if (otg_mode_host)
-               imx25_add_mxc_ehci_otg(&otg_pdata);
-       else
-               imx25_add_fsl_usb2_udc(&otg_device_pdata);
-
-       imx25_add_mxc_ehci_hs(&usbh2_pdata);
-
-#ifdef CONFIG_MACH_EUKREA_MBIMXSD25_BASEBOARD
-       eukrea_mbimxsd25_baseboard_init();
-#endif
-}
-
-static void __init eukrea_cpuimx25_timer_init(void)
-{
-       mx25_clocks_init();
-}
-
-MACHINE_START(EUKREA_CPUIMX25SD, "Eukrea CPUIMX25")
-       /* Maintainer: Eukrea Electromatique */
-       .atag_offset = 0x100,
-       .map_io = mx25_map_io,
-       .init_early = imx25_init_early,
-       .init_irq = mx25_init_irq,
-       .init_time = eukrea_cpuimx25_timer_init,
-       .init_machine = eukrea_cpuimx25_init,
-       .restart        = mxc_restart,
-MACHINE_END
similarity index 68%
rename from arch/arm/mach-imx/imx25-dt.c
rename to arch/arm/mach-imx/mach-imx25.c
index 25defbdb06c434ca93837b3a259c10fefadf28c2..9379fd0a7b4de840d3801576601a1e10bbfb0ce8 100644 (file)
  */
 
 #include <linux/irq.h>
+#include <linux/of_address.h>
 #include <linux/of_irq.h>
 #include <linux/of_platform.h>
 #include <asm/mach/arch.h>
 #include <asm/mach/time.h>
 #include "common.h"
-#include "mx25.h"
+#include "hardware.h"
+
+static void __init imx25_init_early(void)
+{
+       mxc_set_cpu_type(MXC_CPU_MX25);
+}
+
+static void __init mx25_init_irq(void)
+{
+       struct device_node *np;
+       void __iomem *avic_base;
+
+       np = of_find_compatible_node(NULL, NULL, "fsl,avic");
+       avic_base = of_iomap(np, 0);
+       BUG_ON(!avic_base);
+       mxc_init_irq(avic_base);
+}
 
 static const char * const imx25_dt_board_compat[] __initconst = {
        "fsl,imx25",
@@ -23,7 +40,6 @@ static const char * const imx25_dt_board_compat[] __initconst = {
 };
 
 DT_MACHINE_START(IMX25_DT, "Freescale i.MX25 (Device Tree Support)")
-       .map_io         = mx25_map_io,
        .init_early     = imx25_init_early,
        .init_irq       = mx25_init_irq,
        .dt_compat      = imx25_dt_board_compat,
index 4ad6e473cf83ab82e3a769ddcae8956762f47be9..e21a693fc984960a67adcd4d9ba4b2da060f4ee7 100644 (file)
@@ -387,10 +387,10 @@ static void __init imx6q_map_io(void)
 
 static void __init imx6q_init_irq(void)
 {
+       imx_gpc_check_dt();
        imx_init_revision_from_anatop();
        imx_init_l2cache();
        imx_src_init();
-       imx_gpc_init();
        irqchip_init();
 }
 
index 24bfaaf944c8459f4e2947b1d855ce37cb8dd9b7..12a1b098fc6a98bd80de68161b94ae6377f04e37 100644 (file)
@@ -61,10 +61,10 @@ static void __init imx6sl_init_machine(void)
 
 static void __init imx6sl_init_irq(void)
 {
+       imx_gpc_check_dt();
        imx_init_revision_from_anatop();
        imx_init_l2cache();
        imx_src_init();
-       imx_gpc_init();
        irqchip_init();
 }
 
index 66988eb6a3a4dc5ac520bd2a19421e76eaaf28fd..f17b7004c24ba809caf27186c56cded060682586 100644 (file)
@@ -81,10 +81,10 @@ static void __init imx6sx_init_machine(void)
 
 static void __init imx6sx_init_irq(void)
 {
+       imx_gpc_check_dt();
        imx_init_revision_from_anatop();
        imx_init_l2cache();
        imx_src_init();
-       imx_gpc_init();
        irqchip_init();
 }
 
diff --git a/arch/arm/mach-imx/mach-mx25_3ds.c b/arch/arm/mach-imx/mach-mx25_3ds.c
deleted file mode 100644 (file)
index 0d01e36..0000000
+++ /dev/null
@@ -1,270 +0,0 @@
-/*
- * Copyright 2009 Sascha Hauer, <kernel@pengutronix.de>
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * as published by the Free Software Foundation; either version 2
- * of the License, or (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA  02110-1301, USA.
- */
-
-/*
- * This machine is known as:
- *  - i.MX25 3-Stack Development System
- *  - i.MX25 Platform Development Kit (i.MX25 PDK)
- */
-
-#include <linux/types.h>
-#include <linux/init.h>
-#include <linux/delay.h>
-#include <linux/clk.h>
-#include <linux/irq.h>
-#include <linux/gpio.h>
-#include <linux/platform_device.h>
-#include <linux/usb/otg.h>
-
-#include <asm/mach-types.h>
-#include <asm/mach/arch.h>
-#include <asm/mach/time.h>
-#include <asm/memory.h>
-#include <asm/mach/map.h>
-
-#include "common.h"
-#include "devices-imx25.h"
-#include "ehci.h"
-#include "hardware.h"
-#include "iomux-mx25.h"
-#include "mx25.h"
-
-#define MX25PDK_CAN_PWDN       IMX_GPIO_NR(4, 6)
-
-static const struct imxuart_platform_data uart_pdata __initconst = {
-       .flags = IMXUART_HAVE_RTSCTS,
-};
-
-static iomux_v3_cfg_t mx25pdk_pads[] = {
-       MX25_PAD_FEC_MDC__FEC_MDC,
-       MX25_PAD_FEC_MDIO__FEC_MDIO,
-       MX25_PAD_FEC_TDATA0__FEC_TDATA0,
-       MX25_PAD_FEC_TDATA1__FEC_TDATA1,
-       MX25_PAD_FEC_TX_EN__FEC_TX_EN,
-       MX25_PAD_FEC_RDATA0__FEC_RDATA0,
-       MX25_PAD_FEC_RDATA1__FEC_RDATA1,
-       MX25_PAD_FEC_RX_DV__FEC_RX_DV,
-       MX25_PAD_FEC_TX_CLK__FEC_TX_CLK,
-       MX25_PAD_A17__GPIO_2_3, /* FEC_EN, GPIO 35 */
-       MX25_PAD_D12__GPIO_4_8, /* FEC_RESET_B, GPIO 104 */
-
-       /* LCD */
-       MX25_PAD_LD0__LD0,
-       MX25_PAD_LD1__LD1,
-       MX25_PAD_LD2__LD2,
-       MX25_PAD_LD3__LD3,
-       MX25_PAD_LD4__LD4,
-       MX25_PAD_LD5__LD5,
-       MX25_PAD_LD6__LD6,
-       MX25_PAD_LD7__LD7,
-       MX25_PAD_LD8__LD8,
-       MX25_PAD_LD9__LD9,
-       MX25_PAD_LD10__LD10,
-       MX25_PAD_LD11__LD11,
-       MX25_PAD_LD12__LD12,
-       MX25_PAD_LD13__LD13,
-       MX25_PAD_LD14__LD14,
-       MX25_PAD_LD15__LD15,
-       MX25_PAD_GPIO_E__LD16,
-       MX25_PAD_GPIO_F__LD17,
-       MX25_PAD_HSYNC__HSYNC,
-       MX25_PAD_VSYNC__VSYNC,
-       MX25_PAD_LSCLK__LSCLK,
-       MX25_PAD_OE_ACD__OE_ACD,
-       MX25_PAD_CONTRAST__CONTRAST,
-
-       /* Keypad */
-       MX25_PAD_KPP_ROW0__KPP_ROW0,
-       MX25_PAD_KPP_ROW1__KPP_ROW1,
-       MX25_PAD_KPP_ROW2__KPP_ROW2,
-       MX25_PAD_KPP_ROW3__KPP_ROW3,
-       MX25_PAD_KPP_COL0__KPP_COL0,
-       MX25_PAD_KPP_COL1__KPP_COL1,
-       MX25_PAD_KPP_COL2__KPP_COL2,
-       MX25_PAD_KPP_COL3__KPP_COL3,
-
-       /* SD1 */
-       MX25_PAD_SD1_CMD__SD1_CMD,
-       MX25_PAD_SD1_CLK__SD1_CLK,
-       MX25_PAD_SD1_DATA0__SD1_DATA0,
-       MX25_PAD_SD1_DATA1__SD1_DATA1,
-       MX25_PAD_SD1_DATA2__SD1_DATA2,
-       MX25_PAD_SD1_DATA3__SD1_DATA3,
-       MX25_PAD_A14__GPIO_2_0, /* WriteProtect */
-       MX25_PAD_A15__GPIO_2_1, /* CardDetect */
-
-       /* I2C1 */
-       MX25_PAD_I2C1_CLK__I2C1_CLK,
-       MX25_PAD_I2C1_DAT__I2C1_DAT,
-
-       /* CAN1 */
-       MX25_PAD_GPIO_A__CAN1_TX,
-       MX25_PAD_GPIO_B__CAN1_RX,
-       MX25_PAD_D14__GPIO_4_6, /* CAN_PWDN */
-};
-
-static const struct fec_platform_data mx25_fec_pdata __initconst = {
-       .phy    = PHY_INTERFACE_MODE_RMII,
-};
-
-#define FEC_ENABLE_GPIO                IMX_GPIO_NR(2, 3)
-#define FEC_RESET_B_GPIO       IMX_GPIO_NR(4, 8)
-
-static void __init mx25pdk_fec_reset(void)
-{
-       gpio_request(FEC_ENABLE_GPIO, "FEC PHY enable");
-       gpio_request(FEC_RESET_B_GPIO, "FEC PHY reset");
-
-       gpio_direction_output(FEC_ENABLE_GPIO, 0);  /* drop PHY power */
-       gpio_direction_output(FEC_RESET_B_GPIO, 0); /* assert reset */
-       udelay(2);
-
-       /* turn on PHY power and lift reset */
-       gpio_set_value(FEC_ENABLE_GPIO, 1);
-       gpio_set_value(FEC_RESET_B_GPIO, 1);
-}
-
-static const struct mxc_nand_platform_data
-mx25pdk_nand_board_info __initconst = {
-       .width          = 1,
-       .hw_ecc         = 1,
-       .flash_bbt      = 1,
-};
-
-static struct imx_fb_videomode mx25pdk_modes[] = {
-       {
-               .mode   = {
-                       .name           = "CRT-VGA",
-                       .refresh        = 60,
-                       .xres           = 640,
-                       .yres           = 480,
-                       .pixclock       = 39683,
-                       .left_margin    = 45,
-                       .right_margin   = 114,
-                       .upper_margin   = 33,
-                       .lower_margin   = 11,
-                       .hsync_len      = 1,
-                       .vsync_len      = 1,
-               },
-               .bpp    = 16,
-               .pcr    = 0xFA208B80,
-       },
-};
-
-static const struct imx_fb_platform_data mx25pdk_fb_pdata __initconst = {
-       .mode           = mx25pdk_modes,
-       .num_modes      = ARRAY_SIZE(mx25pdk_modes),
-       .pwmr           = 0x00A903FF,
-       .lscr1          = 0x00120300,
-       .dmacr          = 0x00020010,
-};
-
-static const uint32_t mx25pdk_keymap[] = {
-       KEY(0, 0, KEY_UP),
-       KEY(0, 1, KEY_DOWN),
-       KEY(0, 2, KEY_VOLUMEDOWN),
-       KEY(0, 3, KEY_HOME),
-       KEY(1, 0, KEY_RIGHT),
-       KEY(1, 1, KEY_LEFT),
-       KEY(1, 2, KEY_ENTER),
-       KEY(1, 3, KEY_VOLUMEUP),
-       KEY(2, 0, KEY_F6),
-       KEY(2, 1, KEY_F8),
-       KEY(2, 2, KEY_F9),
-       KEY(2, 3, KEY_F10),
-       KEY(3, 0, KEY_F1),
-       KEY(3, 1, KEY_F2),
-       KEY(3, 2, KEY_F3),
-       KEY(3, 3, KEY_POWER),
-};
-
-static const struct matrix_keymap_data mx25pdk_keymap_data __initconst = {
-       .keymap         = mx25pdk_keymap,
-       .keymap_size    = ARRAY_SIZE(mx25pdk_keymap),
-};
-
-static int mx25pdk_usbh2_init(struct platform_device *pdev)
-{
-       return mx25_initialize_usb_hw(pdev->id, MXC_EHCI_INTERNAL_PHY);
-}
-
-static const struct mxc_usbh_platform_data usbh2_pdata __initconst = {
-       .init   = mx25pdk_usbh2_init,
-       .portsc = MXC_EHCI_MODE_SERIAL,
-};
-
-static const struct fsl_usb2_platform_data otg_device_pdata __initconst = {
-       .operating_mode = FSL_USB2_DR_DEVICE,
-       .phy_mode       = FSL_USB2_PHY_UTMI,
-};
-
-static const struct imxi2c_platform_data mx25_3ds_i2c0_data __initconst = {
-       .bitrate = 100000,
-};
-
-#define SD1_GPIO_WP    IMX_GPIO_NR(2, 0)
-#define SD1_GPIO_CD    IMX_GPIO_NR(2, 1)
-
-static const struct esdhc_platform_data mx25pdk_esdhc_pdata __initconst = {
-       .wp_gpio = SD1_GPIO_WP,
-       .cd_gpio = SD1_GPIO_CD,
-       .wp_type = ESDHC_WP_GPIO,
-       .cd_type = ESDHC_CD_GPIO,
-};
-
-static void __init mx25pdk_init(void)
-{
-       imx25_soc_init();
-
-       mxc_iomux_v3_setup_multiple_pads(mx25pdk_pads,
-                       ARRAY_SIZE(mx25pdk_pads));
-
-       imx25_add_imx_uart0(&uart_pdata);
-       imx25_add_fsl_usb2_udc(&otg_device_pdata);
-       imx25_add_mxc_ehci_hs(&usbh2_pdata);
-       imx25_add_mxc_nand(&mx25pdk_nand_board_info);
-       imx25_add_imxdi_rtc();
-       imx25_add_imx_fb(&mx25pdk_fb_pdata);
-       imx25_add_imx2_wdt();
-
-       mx25pdk_fec_reset();
-       imx25_add_fec(&mx25_fec_pdata);
-       imx25_add_imx_keypad(&mx25pdk_keymap_data);
-
-       imx25_add_sdhci_esdhc_imx(0, &mx25pdk_esdhc_pdata);
-       imx25_add_imx_i2c0(&mx25_3ds_i2c0_data);
-
-       gpio_request_one(MX25PDK_CAN_PWDN, GPIOF_OUT_INIT_LOW, "can-pwdn");
-       imx25_add_flexcan0();
-}
-
-static void __init mx25pdk_timer_init(void)
-{
-       mx25_clocks_init();
-}
-
-MACHINE_START(MX25_3DS, "Freescale MX25PDK (3DS)")
-       /* Maintainer: Freescale Semiconductor, Inc. */
-       .atag_offset = 0x100,
-       .map_io = mx25_map_io,
-       .init_early = imx25_init_early,
-       .init_irq = mx25_init_irq,
-       .init_time      = mx25pdk_timer_init,
-       .init_machine = mx25pdk_init,
-       .restart        = mxc_restart,
-MACHINE_END
index 72cd77d21f638c82f62736c75ab4d43e151277a9..7e315f00648d64122cee910af0466fad66c1550c 100644 (file)
@@ -166,7 +166,7 @@ static struct platform_device *devices[] __initdata = {
        &mx35pdk_flash,
 };
 
-static iomux_v3_cfg_t mx35pdk_pads[] = {
+static const iomux_v3_cfg_t mx35pdk_pads[] __initconst = {
        /* UART1 */
        MX35_PAD_CTS1__UART1_CTS,
        MX35_PAD_RTS1__UART1_RTS,
index b623bcaca76ca92624effb5fe780c3f67e0c89ae..e447e59c0604072ab02d5dd6c1834c8bb699b87d 100644 (file)
@@ -129,7 +129,7 @@ static struct platform_device *devices[] __initdata = {
        &pcm043_flash,
 };
 
-static iomux_v3_cfg_t pcm043_pads[] = {
+static const iomux_v3_cfg_t pcm043_pads[] __initconst = {
        /* UART1 */
        MX35_PAD_CTS1__UART1_CTS,
        MX35_PAD_RTS1__UART1_RTS,
index 97836e94451c471e50033aef17599bad80413585..27a8f7e3ec08016e16998e8472ba7aa1d1a9a457 100644 (file)
@@ -161,7 +161,7 @@ static struct i2c_board_info vpr200_i2c_devices[] = {
        }
 };
 
-static iomux_v3_cfg_t vpr200_pads[] = {
+static const iomux_v3_cfg_t vpr200_pads[] __initconst = {
        /* UART1 */
        MX35_PAD_TXD1__UART1_TXD_MUX,
        MX35_PAD_RXD1__UART1_RXD_MUX,
diff --git a/arch/arm/mach-imx/mm-imx25.c b/arch/arm/mach-imx/mm-imx25.c
deleted file mode 100644 (file)
index 5211f62..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- *  Copyright (C) 1999,2000 Arm Limited
- *  Copyright (C) 2000 Deep Blue Solutions Ltd
- *  Copyright (C) 2002 Shane Nay (shane@minirl.com)
- *  Copyright 2005-2007 Freescale Semiconductor, Inc. All Rights Reserved.
- *    - add MX31 specific definitions
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- */
-
-#include <linux/mm.h>
-#include <linux/init.h>
-#include <linux/err.h>
-#include <linux/pinctrl/machine.h>
-
-#include <asm/pgtable.h>
-#include <asm/mach/map.h>
-
-#include "common.h"
-#include "devices/devices-common.h"
-#include "hardware.h"
-#include "iomux-v3.h"
-#include "mx25.h"
-
-/*
- * This table defines static virtual address mappings for I/O regions.
- * These are the mappings common across all MX25 boards.
- */
-static struct map_desc mx25_io_desc[] __initdata = {
-       imx_map_entry(MX25, AVIC, MT_DEVICE_NONSHARED),
-       imx_map_entry(MX25, AIPS1, MT_DEVICE_NONSHARED),
-       imx_map_entry(MX25, AIPS2, MT_DEVICE_NONSHARED),
-};
-
-/*
- * This function initializes the memory map. It is called during the
- * system startup to create static physical to virtual memory mappings
- * for the IO modules.
- */
-void __init mx25_map_io(void)
-{
-       iotable_init(mx25_io_desc, ARRAY_SIZE(mx25_io_desc));
-}
-
-void __init imx25_init_early(void)
-{
-       mxc_set_cpu_type(MXC_CPU_MX25);
-       mxc_iomux_v3_init(MX25_IO_ADDRESS(MX25_IOMUXC_BASE_ADDR));
-}
-
-void __init mx25_init_irq(void)
-{
-       mxc_init_irq(MX25_IO_ADDRESS(MX25_AVIC_BASE_ADDR));
-}
-
-static struct sdma_platform_data imx25_sdma_pdata __initdata = {
-       .fw_name = "sdma-imx25.bin",
-};
-
-static const struct resource imx25_audmux_res[] __initconst = {
-       DEFINE_RES_MEM(MX25_AUDMUX_BASE_ADDR, SZ_16K),
-};
-
-void __init imx25_soc_init(void)
-{
-       mxc_arch_reset_init(MX25_IO_ADDRESS(MX25_WDOG_BASE_ADDR));
-       mxc_device_init();
-
-       /* i.mx25 has the i.mx35 type gpio */
-       mxc_register_gpio("imx35-gpio", 0, MX25_GPIO1_BASE_ADDR, SZ_16K, MX25_INT_GPIO1, 0);
-       mxc_register_gpio("imx35-gpio", 1, MX25_GPIO2_BASE_ADDR, SZ_16K, MX25_INT_GPIO2, 0);
-       mxc_register_gpio("imx35-gpio", 2, MX25_GPIO3_BASE_ADDR, SZ_16K, MX25_INT_GPIO3, 0);
-       mxc_register_gpio("imx35-gpio", 3, MX25_GPIO4_BASE_ADDR, SZ_16K, MX25_INT_GPIO4, 0);
-
-       pinctrl_provide_dummies();
-       /* i.mx25 has the i.mx35 type sdma */
-       imx_add_imx_sdma("imx35-sdma", MX25_SDMA_BASE_ADDR, MX25_INT_SDMA, &imx25_sdma_pdata);
-       /* i.mx25 has the i.mx31 type audmux */
-       platform_device_register_simple("imx31-audmux", 0, imx25_audmux_res,
-                                       ARRAY_SIZE(imx25_audmux_res));
-}
diff --git a/arch/arm/mach-imx/mx25.h b/arch/arm/mach-imx/mx25.h
deleted file mode 100644 (file)
index ec46640..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-#ifndef __MACH_MX25_H__
-#define __MACH_MX25_H__
-
-#define MX25_AIPS1_BASE_ADDR           0x43f00000
-#define MX25_AIPS1_SIZE                        SZ_1M
-#define MX25_AIPS2_BASE_ADDR           0x53f00000
-#define MX25_AIPS2_SIZE                        SZ_1M
-#define MX25_AVIC_BASE_ADDR            0x68000000
-#define MX25_AVIC_SIZE                 SZ_1M
-
-#define MX25_I2C1_BASE_ADDR            (MX25_AIPS1_BASE_ADDR + 0x80000)
-#define MX25_I2C3_BASE_ADDR            (MX25_AIPS1_BASE_ADDR + 0x84000)
-#define MX25_CAN1_BASE_ADDR            (MX25_AIPS1_BASE_ADDR + 0x88000)
-#define MX25_CAN2_BASE_ADDR            (MX25_AIPS1_BASE_ADDR + 0x8c000)
-#define MX25_I2C2_BASE_ADDR            (MX25_AIPS1_BASE_ADDR + 0x98000)
-#define MX25_CSPI1_BASE_ADDR           (MX25_AIPS1_BASE_ADDR + 0xa4000)
-#define MX25_IOMUXC_BASE_ADDR          (MX25_AIPS1_BASE_ADDR + 0xac000)
-
-#define MX25_CRM_BASE_ADDR             (MX25_AIPS2_BASE_ADDR + 0x80000)
-#define MX25_GPT1_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0x90000)
-#define MX25_GPIO4_BASE_ADDR           (MX25_AIPS2_BASE_ADDR + 0x9c000)
-#define MX25_PWM2_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0xa0000)
-#define MX25_GPIO3_BASE_ADDR           (MX25_AIPS2_BASE_ADDR + 0xa4000)
-#define MX25_PWM3_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0xa8000)
-#define MX25_PWM4_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0xc8000)
-#define MX25_GPIO1_BASE_ADDR           (MX25_AIPS2_BASE_ADDR + 0xcc000)
-#define MX25_GPIO2_BASE_ADDR           (MX25_AIPS2_BASE_ADDR + 0xd0000)
-#define MX25_WDOG_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0xdc000)
-#define MX25_PWM1_BASE_ADDR            (MX25_AIPS2_BASE_ADDR + 0xe0000)
-
-#define MX25_UART1_BASE_ADDR           0x43f90000
-#define MX25_UART2_BASE_ADDR           0x43f94000
-#define MX25_AUDMUX_BASE_ADDR          0x43fb0000
-#define MX25_UART3_BASE_ADDR           0x5000c000
-#define MX25_UART4_BASE_ADDR           0x50008000
-#define MX25_UART5_BASE_ADDR           0x5002c000
-
-#define MX25_CSPI3_BASE_ADDR           0x50004000
-#define MX25_CSPI2_BASE_ADDR           0x50010000
-#define MX25_FEC_BASE_ADDR             0x50038000
-#define MX25_SSI2_BASE_ADDR            0x50014000
-#define MX25_SSI1_BASE_ADDR            0x50034000
-#define MX25_NFC_BASE_ADDR             0xbb000000
-#define MX25_IIM_BASE_ADDR             0x53ff0000
-#define MX25_DRYICE_BASE_ADDR          0x53ffc000
-#define MX25_ESDHC1_BASE_ADDR          0x53fb4000
-#define MX25_ESDHC2_BASE_ADDR          0x53fb8000
-#define MX25_LCDC_BASE_ADDR            0x53fbc000
-#define MX25_KPP_BASE_ADDR             0x43fa8000
-#define MX25_SDMA_BASE_ADDR            0x53fd4000
-#define MX25_USB_BASE_ADDR             0x53ff4000
-#define MX25_USB_OTG_BASE_ADDR                 (MX25_USB_BASE_ADDR + 0x0000)
-/*
- * The reference manual (IMX25RM, Rev. 1, 06/2009) specifies an offset of 0x200
- * for the host controller.  Early documentation drafts specified 0x400 and
- * Freescale internal sources confirm only the latter value to work.
- */
-#define MX25_USB_HS_BASE_ADDR                  (MX25_USB_BASE_ADDR + 0x0400)
-#define MX25_CSI_BASE_ADDR             0x53ff8000
-
-#define MX25_IO_P2V(x)                 IMX_IO_P2V(x)
-#define MX25_IO_ADDRESS(x)             IOMEM(MX25_IO_P2V(x))
-
-/*
- * Interrupt numbers
- */
-#include <asm/irq.h>
-#define MX25_INT_CSPI3         (NR_IRQS_LEGACY + 0)
-#define MX25_INT_I2C1          (NR_IRQS_LEGACY + 3)
-#define MX25_INT_I2C2          (NR_IRQS_LEGACY + 4)
-#define MX25_INT_UART4         (NR_IRQS_LEGACY + 5)
-#define MX25_INT_ESDHC2                (NR_IRQS_LEGACY + 8)
-#define MX25_INT_ESDHC1                (NR_IRQS_LEGACY + 9)
-#define MX25_INT_I2C3          (NR_IRQS_LEGACY + 10)
-#define MX25_INT_SSI2          (NR_IRQS_LEGACY + 11)
-#define MX25_INT_SSI1          (NR_IRQS_LEGACY + 12)
-#define MX25_INT_CSPI2         (NR_IRQS_LEGACY + 13)
-#define MX25_INT_CSPI1         (NR_IRQS_LEGACY + 14)
-#define MX25_INT_GPIO3         (NR_IRQS_LEGACY + 16)
-#define MX25_INT_CSI           (NR_IRQS_LEGACY + 17)
-#define MX25_INT_UART3         (NR_IRQS_LEGACY + 18)
-#define MX25_INT_GPIO4         (NR_IRQS_LEGACY + 23)
-#define MX25_INT_KPP           (NR_IRQS_LEGACY + 24)
-#define MX25_INT_DRYICE                (NR_IRQS_LEGACY + 25)
-#define MX25_INT_PWM1          (NR_IRQS_LEGACY + 26)
-#define MX25_INT_UART2         (NR_IRQS_LEGACY + 32)
-#define MX25_INT_NFC           (NR_IRQS_LEGACY + 33)
-#define MX25_INT_SDMA          (NR_IRQS_LEGACY + 34)
-#define MX25_INT_USB_HS                (NR_IRQS_LEGACY + 35)
-#define MX25_INT_PWM2          (NR_IRQS_LEGACY + 36)
-#define MX25_INT_USB_OTG       (NR_IRQS_LEGACY + 37)
-#define MX25_INT_LCDC          (NR_IRQS_LEGACY + 39)
-#define MX25_INT_UART5         (NR_IRQS_LEGACY + 40)
-#define MX25_INT_PWM3          (NR_IRQS_LEGACY + 41)
-#define MX25_INT_PWM4          (NR_IRQS_LEGACY + 42)
-#define MX25_INT_CAN1          (NR_IRQS_LEGACY + 43)
-#define MX25_INT_CAN2          (NR_IRQS_LEGACY + 44)
-#define MX25_INT_UART1         (NR_IRQS_LEGACY + 45)
-#define MX25_INT_GPIO2         (NR_IRQS_LEGACY + 51)
-#define MX25_INT_GPIO1         (NR_IRQS_LEGACY + 52)
-#define MX25_INT_GPT1          (NR_IRQS_LEGACY + 54)
-#define MX25_INT_FEC           (NR_IRQS_LEGACY + 57)
-
-#define MX25_DMA_REQ_SSI2_RX1  22
-#define MX25_DMA_REQ_SSI2_TX1  23
-#define MX25_DMA_REQ_SSI2_RX0  24
-#define MX25_DMA_REQ_SSI2_TX0  25
-#define MX25_DMA_REQ_SSI1_RX1  26
-#define MX25_DMA_REQ_SSI1_TX1  27
-#define MX25_DMA_REQ_SSI1_RX0  28
-#define MX25_DMA_REQ_SSI1_TX0  29
-
-#ifndef __ASSEMBLY__
-extern int mx25_revision(void);
-#endif
-
-#endif /* ifndef __MACH_MX25_H__ */
index 46fd695203c70a22fdc4389b39161d1e6ef5a5b8..6a7c6fc780cce686650ea684d2965c30de3746df 100644 (file)
@@ -310,10 +310,12 @@ int imx6q_set_lpm(enum mxc_cpu_pwr_mode mode)
         *    Low-Power mode.
         * 3) Software should mask IRQ #32 right after CCM Low-Power mode
         *    is set (set bits 0-1 of CCM_CLPCR).
+        *
+        * Note that IRQ #32 is GIC SPI #0.
         */
-       imx_gpc_hwirq_unmask(32);
+       imx_gpc_hwirq_unmask(0);
        writel_relaxed(val, ccm_base + CLPCR);
-       imx_gpc_hwirq_mask(32);
+       imx_gpc_hwirq_mask(0);
 
        return 0;
 }
index 34b4c0044961eefaf3dac6094a3a215152aae6bd..dd94567c36289c16303a267a86cde69cfba82e75 100644 (file)
@@ -71,13 +71,7 @@ static unsigned int mpui7xx_sleep_save[MPUI7XX_SLEEP_SAVE_SIZE];
 static unsigned int mpui1510_sleep_save[MPUI1510_SLEEP_SAVE_SIZE];
 static unsigned int mpui1610_sleep_save[MPUI1610_SLEEP_SAVE_SIZE];
 
-#ifndef CONFIG_OMAP_32K_TIMER
-
-static unsigned short enable_dyn_sleep = 0;
-
-#else
-
-static unsigned short enable_dyn_sleep = 1;
+static unsigned short enable_dyn_sleep;
 
 static ssize_t idle_show(struct kobject *kobj, struct kobj_attribute *attr,
                         char *buf)
@@ -90,8 +84,9 @@ static ssize_t idle_store(struct kobject *kobj, struct kobj_attribute *attr,
 {
        unsigned short value;
        if (sscanf(buf, "%hu", &value) != 1 ||
-           (value != 0 && value != 1)) {
-               printk(KERN_ERR "idle_sleep_store: Invalid value\n");
+           (value != 0 && value != 1) ||
+           (value != 0 && !IS_ENABLED(CONFIG_OMAP_32K_TIMER))) {
+               pr_err("idle_sleep_store: Invalid value\n");
                return -EINVAL;
        }
        enable_dyn_sleep = value;
@@ -101,7 +96,6 @@ static ssize_t idle_store(struct kobject *kobj, struct kobj_attribute *attr,
 static struct kobj_attribute sleep_while_idle_attr =
        __ATTR(sleep_while_idle, 0644, idle_show, idle_store);
 
-#endif
 
 static void (*omap_sram_suspend)(unsigned long r0, unsigned long r1) = NULL;
 
@@ -115,16 +109,11 @@ void omap1_pm_idle(void)
 {
        extern __u32 arm_idlect1_mask;
        __u32 use_idlect1 = arm_idlect1_mask;
-       int do_sleep = 0;
 
        local_fiq_disable();
 
 #if defined(CONFIG_OMAP_MPU_TIMER) && !defined(CONFIG_OMAP_DM_TIMER)
-#warning Enable 32kHz OS timer in order to allow sleep states in idle
        use_idlect1 = use_idlect1 & ~(1 << 9);
-#else
-       if (enable_dyn_sleep)
-               do_sleep = 1;
 #endif
 
 #ifdef CONFIG_OMAP_DM_TIMER
@@ -134,10 +123,12 @@ void omap1_pm_idle(void)
        if (omap_dma_running())
                use_idlect1 &= ~(1 << 6);
 
-       /* We should be able to remove the do_sleep variable and multiple
+       /*
+        * We should be able to remove the do_sleep variable and multiple
         * tests above as soon as drivers, timer and DMA code have been fixed.
-        * Even the sleep block count should become obsolete. */
-       if ((use_idlect1 != ~0) || !do_sleep) {
+        * Even the sleep block count should become obsolete.
+        */
+       if ((use_idlect1 != ~0) || !enable_dyn_sleep) {
 
                __u32 saved_idlect1 = omap_readl(ARM_IDLECT1);
                if (cpu_is_omap15xx())
@@ -635,15 +626,25 @@ static const struct platform_suspend_ops omap_pm_ops = {
 
 static int __init omap_pm_init(void)
 {
-
-#ifdef CONFIG_OMAP_32K_TIMER
-       int error;
-#endif
+       int error = 0;
 
        if (!cpu_class_is_omap1())
                return -ENODEV;
 
-       printk("Power Management for TI OMAP.\n");
+       pr_info("Power Management for TI OMAP.\n");
+
+       if (!IS_ENABLED(CONFIG_OMAP_32K_TIMER))
+               pr_info("OMAP1 PM: sleep states in idle disabled due to no 32KiHz timer\n");
+
+       if (!IS_ENABLED(CONFIG_OMAP_DM_TIMER))
+               pr_info("OMAP1 PM: sleep states in idle disabled due to no DMTIMER support\n");
+
+       if (IS_ENABLED(CONFIG_OMAP_32K_TIMER) &&
+           IS_ENABLED(CONFIG_OMAP_DM_TIMER)) {
+               /* OMAP16xx only */
+               pr_info("OMAP1 PM: sleep states in idle enabled\n");
+               enable_dyn_sleep = 1;
+       }
 
        /*
         * We copy the assembler sleep/wakeup routines to SRAM.
@@ -693,17 +694,15 @@ static int __init omap_pm_init(void)
        omap_pm_init_debugfs();
 #endif
 
-#ifdef CONFIG_OMAP_32K_TIMER
        error = sysfs_create_file(power_kobj, &sleep_while_idle_attr.attr);
        if (error)
                printk(KERN_ERR "sysfs_create_file failed: %d\n", error);
-#endif
 
        if (cpu_is_omap16xx()) {
                /* configure LOW_PWR pin */
                omap_cfg_reg(T20_1610_LOW_PWR);
        }
 
-       return 0;
+       return error;
 }
 __initcall(omap_pm_init);
index 2b8e47788062d7744bdffc6281714c07f6e0e38e..1041b19485ab84a6f780ad85def3b408dbd0fd93 100644 (file)
@@ -69,6 +69,7 @@ config SOC_DRA7XX
        select ARM_GIC
        select HAVE_ARM_ARCH_TIMER
        select IRQ_CROSSBAR
+       select ARM_ERRATA_798181 if SMP
 
 config ARCH_OMAP2PLUS
        bool
@@ -278,27 +279,6 @@ config OMAP3_SDRC_AC_TIMING
          wish to say no.  Selecting yes without understanding what is
          going on could result in system crashes;
 
-config OMAP4_ERRATA_I688
-       bool "OMAP4 errata: Async Bridge Corruption"
-       depends on (ARCH_OMAP4 || SOC_OMAP5) && !ARCH_MULTIPLATFORM
-       select ARCH_HAS_BARRIERS
-       help
-         If a data is stalled inside asynchronous bridge because of back
-         pressure, it may be accepted multiple times, creating pointer
-         misalignment that will corrupt next transfers on that data path
-         until next reset of the system (No recovery procedure once the
-         issue is hit, the path remains consistently broken). Async bridge
-         can be found on path between MPU to EMIF and MPU to L3 interconnect.
-         This situation can happen only when the idle is initiated by a
-         Master Request Disconnection (which is trigged by software when
-         executing WFI on CPU).
-         The work-around for this errata needs all the initiators connected
-         through async bridge must ensure that data path is properly drained
-         before issuing WFI. This condition will be met if one Strongly ordered
-         access is performed to the target right before executing the WFI.
-         In MPU case, L3 T2ASYNC FIFO and DDR T2ASYNC FIFO needs to be drained.
-         IO barrier ensure that there is no synchronisation loss on initiators
-         operating on both interconnect port simultaneously.
 endmenu
 
 endif
index 6124db5c37aebf5d3092b66c355c326bdf6815f9..a699d716930746d4f37bd603be865b248d5986bc 100644 (file)
@@ -23,6 +23,9 @@
 #include <linux/clk-provider.h>
 #include <linux/io.h>
 #include <linux/bitops.h>
+#include <linux/regmap.h>
+#include <linux/of_address.h>
+#include <linux/bootmem.h>
 #include <asm/cpu.h>
 
 #include <trace/events/power.h>
@@ -72,30 +75,110 @@ struct ti_clk_features ti_clk_features;
 static bool clkdm_control = true;
 
 static LIST_HEAD(clk_hw_omap_clocks);
-void __iomem *clk_memmaps[CLK_MAX_MEMMAPS];
+
+struct clk_iomap {
+       struct regmap *regmap;
+       void __iomem *mem;
+};
+
+static struct clk_iomap *clk_memmaps[CLK_MAX_MEMMAPS];
+
+static void clk_memmap_writel(u32 val, void __iomem *reg)
+{
+       struct clk_omap_reg *r = (struct clk_omap_reg *)&reg;
+       struct clk_iomap *io = clk_memmaps[r->index];
+
+       if (io->regmap)
+               regmap_write(io->regmap, r->offset, val);
+       else
+               writel_relaxed(val, io->mem + r->offset);
+}
+
+static u32 clk_memmap_readl(void __iomem *reg)
+{
+       u32 val;
+       struct clk_omap_reg *r = (struct clk_omap_reg *)&reg;
+       struct clk_iomap *io = clk_memmaps[r->index];
+
+       if (io->regmap)
+               regmap_read(io->regmap, r->offset, &val);
+       else
+               val = readl_relaxed(io->mem + r->offset);
+
+       return val;
+}
 
 void omap2_clk_writel(u32 val, struct clk_hw_omap *clk, void __iomem *reg)
 {
-       if (clk->flags & MEMMAP_ADDRESSING) {
-               struct clk_omap_reg *r = (struct clk_omap_reg *)&reg;
-               writel_relaxed(val, clk_memmaps[r->index] + r->offset);
-       } else {
+       if (WARN_ON_ONCE(!(clk->flags & MEMMAP_ADDRESSING)))
                writel_relaxed(val, reg);
-       }
+       else
+               clk_memmap_writel(val, reg);
 }
 
 u32 omap2_clk_readl(struct clk_hw_omap *clk, void __iomem *reg)
 {
-       u32 val;
+       if (WARN_ON_ONCE(!(clk->flags & MEMMAP_ADDRESSING)))
+               return readl_relaxed(reg);
+       else
+               return clk_memmap_readl(reg);
+}
 
-       if (clk->flags & MEMMAP_ADDRESSING) {
-               struct clk_omap_reg *r = (struct clk_omap_reg *)&reg;
-               val = readl_relaxed(clk_memmaps[r->index] + r->offset);
-       } else {
-               val = readl_relaxed(reg);
-       }
+static struct ti_clk_ll_ops omap_clk_ll_ops = {
+       .clk_readl = clk_memmap_readl,
+       .clk_writel = clk_memmap_writel,
+};
 
-       return val;
+/**
+ * omap2_clk_provider_init - initialize a clock provider
+ * @match_table: DT device table to match for devices to init
+ * @np: device node pointer for the this clock provider
+ * @index: index for the clock provider
+ + @syscon: syscon regmap pointer
+ * @mem: iomem pointer for the clock provider memory area, only used if
+ *      syscon is not provided
+ *
+ * Initializes a clock provider module (CM/PRM etc.), registering
+ * the memory mapping at specified index and initializing the
+ * low level driver infrastructure. Returns 0 in success.
+ */
+int __init omap2_clk_provider_init(struct device_node *np, int index,
+                                  struct regmap *syscon, void __iomem *mem)
+{
+       struct clk_iomap *io;
+
+       ti_clk_ll_ops = &omap_clk_ll_ops;
+
+       io = kzalloc(sizeof(*io), GFP_KERNEL);
+
+       io->regmap = syscon;
+       io->mem = mem;
+
+       clk_memmaps[index] = io;
+
+       ti_dt_clk_init_provider(np, index);
+
+       return 0;
+}
+
+/**
+ * omap2_clk_legacy_provider_init - initialize a legacy clock provider
+ * @index: index for the clock provider
+ * @mem: iomem pointer for the clock provider memory area
+ *
+ * Initializes a legacy clock provider memory mapping.
+ */
+void __init omap2_clk_legacy_provider_init(int index, void __iomem *mem)
+{
+       struct clk_iomap *io;
+
+       ti_clk_ll_ops = &omap_clk_ll_ops;
+
+       io = memblock_virt_alloc(sizeof(*io), 0);
+
+       io->mem = mem;
+
+       clk_memmaps[index] = io;
 }
 
 /*
index a56742f96000a64eb125010903304fb0d7e37414..652ed0ab86ec022cffdb55271e3c1e9fb6a78e0c 100644 (file)
@@ -271,10 +271,14 @@ extern const struct clksel_rate div_1_3_rates[];
 extern const struct clksel_rate div_1_4_rates[];
 extern const struct clksel_rate div31_1to31_rates[];
 
-extern void __iomem *clk_memmaps[];
-
 extern int omap2_clkops_enable_clkdm(struct clk_hw *hw);
 extern void omap2_clkops_disable_clkdm(struct clk_hw *hw);
 
+struct regmap;
+
+int __init omap2_clk_provider_init(struct device_node *np, int index,
+                                  struct regmap *syscon, void __iomem *mem);
+void __init omap2_clk_legacy_provider_init(int index, void __iomem *mem);
+
 void __init ti_clk_init_features(void);
 #endif
index 6222e87a79b623e7299e2c694e01246979d1accd..1fe3e6b833d255e76a8c564b68c532c1a63f0c83 100644 (file)
@@ -70,6 +70,8 @@ int omap_cm_module_enable(u8 mode, u8 part, u16 inst, u16 clkctrl_offs);
 int omap_cm_module_disable(u8 part, u16 inst, u16 clkctrl_offs);
 extern int cm_register(struct cm_ll_data *cld);
 extern int cm_unregister(struct cm_ll_data *cld);
+int omap_cm_init(void);
+int omap2_cm_base_init(void);
 
 # endif
 
index ef62ac9dcd0516452cda05309594e3b8008080b7..3e5fd3587eb1870e16daa70d2e27001cb449f01a 100644 (file)
@@ -393,7 +393,7 @@ static struct cm_ll_data omap2xxx_cm_ll_data = {
        .wait_module_ready      = &omap2xxx_cm_wait_module_ready,
 };
 
-int __init omap2xxx_cm_init(void)
+int __init omap2xxx_cm_init(const struct omap_prcm_init_data *data)
 {
        return cm_register(&omap2xxx_cm_ll_data);
 }
index 83b6c597b0e185e1d0e5d40c1768d729e23a7595..7b8c79c0ce27b11bf6b4fea313ab625d4c738779 100644 (file)
@@ -63,7 +63,7 @@ extern u32 omap2xxx_cm_get_core_pll_config(void);
 extern void omap2xxx_cm_set_mod_dividers(u32 mpu, u32 dsp, u32 gfx, u32 core,
                                         u32 mdm);
 
-extern int __init omap2xxx_cm_init(void);
+int __init omap2xxx_cm_init(const struct omap_prcm_init_data *data);
 
 #endif
 
index cc5aac784278b5e27fc8d90e080bec971a751eff..7b181f92952557b777e5e0bbbcedae0c6cb647f8 100644 (file)
@@ -352,7 +352,7 @@ static struct cm_ll_data am33xx_cm_ll_data = {
        .module_disable         = &am33xx_cm_module_disable,
 };
 
-int __init am33xx_cm_init(void)
+int __init am33xx_cm_init(const struct omap_prcm_init_data *data)
 {
        return cm_register(&am33xx_cm_ll_data);
 }
index 046b4b2bc9d93db7a584554c3dc4f93ae0342639..a91f7d2824559887f30088740f2defc551f7487b 100644 (file)
@@ -19,6 +19,7 @@
 
 #include "cm.h"
 #include "cm-regbits-33xx.h"
+#include "prcm-common.h"
 
 /* CM base address */
 #define AM33XX_CM_BASE         0x44e00000
 
 
 #ifndef __ASSEMBLER__
-int am33xx_cm_init(void);
+int am33xx_cm_init(const struct omap_prcm_init_data *data);
 #endif /* ASSEMBLER */
 #endif
index ebead8f035f986d257e7d406bbe12d4bcf3089fa..187fa438671860c8edaa48b04769c09fe5d358ea 100644 (file)
@@ -671,8 +671,9 @@ static struct cm_ll_data omap3xxx_cm_ll_data = {
        .wait_module_ready      = &omap3xxx_cm_wait_module_ready,
 };
 
-int __init omap3xxx_cm_init(void)
+int __init omap3xxx_cm_init(const struct omap_prcm_init_data *data)
 {
+       omap2_clk_legacy_provider_init(TI_CLKM_CM, cm_base + OMAP3430_IVA2_MOD);
        return cm_register(&omap3xxx_cm_ll_data);
 }
 
index 734a8581c0c4e07d8286e7cd7725357955481384..bc444e2080a174fa49bb9da016d81fcf2f78ce05 100644 (file)
@@ -72,7 +72,7 @@ extern void omap3_cm_save_context(void);
 extern void omap3_cm_restore_context(void);
 extern void omap3_cm_save_scratchpad_contents(u32 *ptr);
 
-extern int __init omap3xxx_cm_init(void);
+int __init omap3xxx_cm_init(const struct omap_prcm_init_data *data);
 
 #endif
 
index 728d06a4af198f16cd5afab63ecccb752c68936f..309a4c91344847f41cb2074cb7060452c03474a3 100644 (file)
@@ -23,7 +23,6 @@
 #define OMAP4_CM_CLKSTCTRL                             0x0000
 #define OMAP4_CM_STATICDEP                             0x0004
 
-void omap_cm_base_init(void);
-int omap4_cm_init(void);
+int omap4_cm_init(const struct omap_prcm_init_data *data);
 
 #endif
index 8fe02fcedc48e3974bc90388753efa8a9c27aab6..23e8bcec34e33c89d7f9f196badb57136db57378 100644 (file)
 #include <linux/init.h>
 #include <linux/errno.h>
 #include <linux/bug.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
 
 #include "cm2xxx.h"
 #include "cm3xxx.h"
+#include "cm33xx.h"
 #include "cm44xx.h"
+#include "clock.h"
 
 /*
  * cm_ll_data: function pointers to SoC-specific implementations of
@@ -33,6 +37,9 @@ void __iomem *cm_base;
 /* cm2_base: base virtual address of the CM2 IP block (OMAP44xx only) */
 void __iomem *cm2_base;
 
+#define CM_NO_CLOCKS           0x1
+#define CM_SINGLE_INSTANCE     0x2
+
 /**
  * omap2_set_globals_cm - set the CM/CM2 base addresses (for early use)
  * @cm: CM base virtual address
@@ -212,3 +219,152 @@ int cm_unregister(struct cm_ll_data *cld)
 
        return 0;
 }
+
+#if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5) || \
+       defined(CONFIG_SOC_DRA7XX)
+static struct omap_prcm_init_data cm_data __initdata = {
+       .index = TI_CLKM_CM,
+       .init = omap4_cm_init,
+};
+
+static struct omap_prcm_init_data cm2_data __initdata = {
+       .index = TI_CLKM_CM2,
+       .init = omap4_cm_init,
+};
+#endif
+
+#ifdef CONFIG_ARCH_OMAP2
+static struct omap_prcm_init_data omap2_prcm_data __initdata = {
+       .index = TI_CLKM_CM,
+       .init = omap2xxx_cm_init,
+       .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE,
+};
+#endif
+
+#ifdef CONFIG_ARCH_OMAP3
+static struct omap_prcm_init_data omap3_cm_data __initdata = {
+       .index = TI_CLKM_CM,
+       .init = omap3xxx_cm_init,
+       .flags = CM_SINGLE_INSTANCE,
+
+       /*
+        * IVA2 offset is a negative value, must offset the cm_base address
+        * by this to get it to positive side on the iomap
+        */
+       .offset = -OMAP3430_IVA2_MOD,
+};
+#endif
+
+#if defined(CONFIG_SOC_AM33XX) || defined(CONFIG_SOC_TI81XX)
+static struct omap_prcm_init_data am3_prcm_data __initdata = {
+       .index = TI_CLKM_CM,
+       .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE,
+       .init = am33xx_cm_init,
+};
+#endif
+
+#ifdef CONFIG_SOC_AM43XX
+static struct omap_prcm_init_data am4_prcm_data __initdata = {
+       .index = TI_CLKM_CM,
+       .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE,
+       .init = omap4_cm_init,
+};
+#endif
+
+static const struct of_device_id omap_cm_dt_match_table[] __initconst = {
+#ifdef CONFIG_ARCH_OMAP2
+       { .compatible = "ti,omap2-prcm", .data = &omap2_prcm_data },
+#endif
+#ifdef CONFIG_ARCH_OMAP3
+       { .compatible = "ti,omap3-cm", .data = &omap3_cm_data },
+#endif
+#ifdef CONFIG_ARCH_OMAP4
+       { .compatible = "ti,omap4-cm1", .data = &cm_data },
+       { .compatible = "ti,omap4-cm2", .data = &cm2_data },
+#endif
+#ifdef CONFIG_SOC_OMAP5
+       { .compatible = "ti,omap5-cm-core-aon", .data = &cm_data },
+       { .compatible = "ti,omap5-cm-core", .data = &cm2_data },
+#endif
+#ifdef CONFIG_SOC_DRA7XX
+       { .compatible = "ti,dra7-cm-core-aon", .data = &cm_data },
+       { .compatible = "ti,dra7-cm-core", .data = &cm2_data },
+#endif
+#ifdef CONFIG_SOC_AM33XX
+       { .compatible = "ti,am3-prcm", .data = &am3_prcm_data },
+#endif
+#ifdef CONFIG_SOC_AM43XX
+       { .compatible = "ti,am4-prcm", .data = &am4_prcm_data },
+#endif
+#ifdef CONFIG_SOC_TI81XX
+       { .compatible = "ti,dm814-prcm", .data = &am3_prcm_data },
+       { .compatible = "ti,dm816-prcm", .data = &am3_prcm_data },
+#endif
+       { }
+};
+
+/**
+ * omap2_cm_base_init - initialize iomappings for the CM drivers
+ *
+ * Detects and initializes the iomappings for the CM driver, based
+ * on the DT data. Returns 0 in success, negative error value
+ * otherwise.
+ */
+int __init omap2_cm_base_init(void)
+{
+       struct device_node *np;
+       const struct of_device_id *match;
+       struct omap_prcm_init_data *data;
+       void __iomem *mem;
+
+       for_each_matching_node_and_match(np, omap_cm_dt_match_table, &match) {
+               data = (struct omap_prcm_init_data *)match->data;
+
+               mem = of_iomap(np, 0);
+               if (!mem)
+                       return -ENOMEM;
+
+               if (data->index == TI_CLKM_CM)
+                       cm_base = mem + data->offset;
+
+               if (data->index == TI_CLKM_CM2)
+                       cm2_base = mem + data->offset;
+
+               data->mem = mem;
+
+               data->np = np;
+
+               if (data->init && (data->flags & CM_SINGLE_INSTANCE ||
+                                  (cm_base && cm2_base)))
+                       data->init(data);
+       }
+
+       return 0;
+}
+
+/**
+ * omap_cm_init - low level init for the CM drivers
+ *
+ * Initializes the low level clock infrastructure for CM drivers.
+ * Returns 0 in success, negative error value in failure.
+ */
+int __init omap_cm_init(void)
+{
+       struct device_node *np;
+       const struct of_device_id *match;
+       const struct omap_prcm_init_data *data;
+       int ret;
+
+       for_each_matching_node_and_match(np, omap_cm_dt_match_table, &match) {
+               data = match->data;
+
+               if (data->flags & CM_NO_CLOCKS)
+                       continue;
+
+               ret = omap2_clk_provider_init(np, data->index, NULL, data->mem);
+               if (ret)
+                       return ret;
+       }
+
+       return 0;
+}
index 95a8cff66aff5adf51320dda23c58b773adf67b6..2c0e07ed6b995b77b2c3a01aaaba457173251335 100644 (file)
@@ -63,7 +63,7 @@ static void __iomem *_cm_bases[OMAP4_MAX_PRCM_PARTITIONS];
  * Populates the base addresses of the _cm_bases
  * array used for read/write of cm module registers.
  */
-void omap_cm_base_init(void)
+static void omap_cm_base_init(void)
 {
        _cm_bases[OMAP4430_PRM_PARTITION] = prm_base;
        _cm_bases[OMAP4430_CM1_PARTITION] = cm_base;
@@ -514,8 +514,10 @@ static struct cm_ll_data omap4xxx_cm_ll_data = {
        .module_disable         = &omap4_cminst_module_disable,
 };
 
-int __init omap4_cm_init(void)
+int __init omap4_cm_init(const struct omap_prcm_init_data *data)
 {
+       omap_cm_base_init();
+
        return cm_register(&omap4xxx_cm_ll_data);
 }
 
index 484cdadfb18785ade051c29bab4d5e608dd56218..eae6a0e87c90d33649bccb350ed1f5732deae25d 100644 (file)
@@ -30,5 +30,4 @@ int __weak omap_secure_ram_reserve_memblock(void)
 void __init omap_reserve(void)
 {
        omap_secure_ram_reserve_memblock();
-       omap_barrier_reserve_memblock();
 }
index 46e24581d6245a45ff316a9c00dfe74284539238..cf3cf22ecd42696da3de4371ad11d38e46d95b33 100644 (file)
@@ -200,9 +200,6 @@ void __init omap4_map_io(void);
 void __init omap5_map_io(void);
 void __init ti81xx_map_io(void);
 
-/* omap_barriers_init() is OMAP4 only */
-void omap_barriers_init(void);
-
 /**
  * omap_test_timeout - busy-loop, testing a condition
  * @cond: condition to test until it evaluates to true
index da041b4ab29c6bb0b5ae5e67aee2271887b8b73e..af95a624fe71ea2a6d4f56f2ee11b2d2d51230c6 100644 (file)
@@ -14,6 +14,9 @@
 
 #include <linux/kernel.h>
 #include <linux/io.h>
+#include <linux/of_address.h>
+#include <linux/regmap.h>
+#include <linux/mfd/syscon.h>
 
 #include "soc.h"
 #include "iomap.h"
 #include "sdrc.h"
 #include "pm.h"
 #include "control.h"
+#include "clock.h"
 
 /* Used by omap3_ctrl_save_padconf() */
 #define START_PADCONF_SAVE             0x2
 #define PADCONF_SAVE_DONE              0x1
 
 static void __iomem *omap2_ctrl_base;
-static void __iomem *omap4_ctrl_pad_base;
+static s16 omap2_ctrl_offset;
+static struct regmap *omap2_ctrl_syscon;
 
 #if defined(CONFIG_ARCH_OMAP3) && defined(CONFIG_PM)
 struct omap3_scratchpad {
@@ -133,66 +138,79 @@ struct omap3_control_regs {
 static struct omap3_control_regs control_context;
 #endif /* CONFIG_ARCH_OMAP3 && CONFIG_PM */
 
-#define OMAP_CTRL_REGADDR(reg)         (omap2_ctrl_base + (reg))
-#define OMAP4_CTRL_PAD_REGADDR(reg)    (omap4_ctrl_pad_base + (reg))
-
-void __init omap2_set_globals_control(void __iomem *ctrl,
-                                     void __iomem *ctrl_pad)
+void __init omap2_set_globals_control(void __iomem *ctrl)
 {
        omap2_ctrl_base = ctrl;
-       omap4_ctrl_pad_base = ctrl_pad;
-}
-
-void __iomem *omap_ctrl_base_get(void)
-{
-       return omap2_ctrl_base;
 }
 
 u8 omap_ctrl_readb(u16 offset)
 {
-       return readb_relaxed(OMAP_CTRL_REGADDR(offset));
+       u32 val;
+       u8 byte_offset = offset & 0x3;
+
+       val = omap_ctrl_readl(offset);
+
+       return (val >> (byte_offset * 8)) & 0xff;
 }
 
 u16 omap_ctrl_readw(u16 offset)
 {
-       return readw_relaxed(OMAP_CTRL_REGADDR(offset));
+       u32 val;
+       u16 byte_offset = offset & 0x2;
+
+       val = omap_ctrl_readl(offset);
+
+       return (val >> (byte_offset * 8)) & 0xffff;
 }
 
 u32 omap_ctrl_readl(u16 offset)
 {
-       return readl_relaxed(OMAP_CTRL_REGADDR(offset));
+       u32 val;
+
+       offset &= 0xfffc;
+       if (!omap2_ctrl_syscon)
+               val = readl_relaxed(omap2_ctrl_base + offset);
+       else
+               regmap_read(omap2_ctrl_syscon, omap2_ctrl_offset + offset,
+                           &val);
+
+       return val;
 }
 
 void omap_ctrl_writeb(u8 val, u16 offset)
 {
-       writeb_relaxed(val, OMAP_CTRL_REGADDR(offset));
+       u32 tmp;
+       u8 byte_offset = offset & 0x3;
+
+       tmp = omap_ctrl_readl(offset);
+
+       tmp &= 0xffffffff ^ (0xff << (byte_offset * 8));
+       tmp |= val << (byte_offset * 8);
+
+       omap_ctrl_writel(tmp, offset);
 }
 
 void omap_ctrl_writew(u16 val, u16 offset)
 {
-       writew_relaxed(val, OMAP_CTRL_REGADDR(offset));
-}
+       u32 tmp;
+       u8 byte_offset = offset & 0x2;
 
-void omap_ctrl_writel(u32 val, u16 offset)
-{
-       writel_relaxed(val, OMAP_CTRL_REGADDR(offset));
-}
+       tmp = omap_ctrl_readl(offset);
 
-/*
- * On OMAP4 control pad are not addressable from control
- * core base. So the common omap_ctrl_read/write APIs breaks
- * Hence export separate APIs to manage the omap4 pad control
- * registers. This APIs will work only for OMAP4
- */
+       tmp &= 0xffffffff ^ (0xffff << (byte_offset * 8));
+       tmp |= val << (byte_offset * 8);
 
-u32 omap4_ctrl_pad_readl(u16 offset)
-{
-       return readl_relaxed(OMAP4_CTRL_PAD_REGADDR(offset));
+       omap_ctrl_writel(tmp, offset);
 }
 
-void omap4_ctrl_pad_writel(u32 val, u16 offset)
+void omap_ctrl_writel(u32 val, u16 offset)
 {
-       writel_relaxed(val, OMAP4_CTRL_PAD_REGADDR(offset));
+       offset &= 0xfffc;
+       if (!omap2_ctrl_syscon)
+               writel_relaxed(val, omap2_ctrl_base + offset);
+       else
+               regmap_write(omap2_ctrl_syscon, omap2_ctrl_offset + offset,
+                            val);
 }
 
 #ifdef CONFIG_ARCH_OMAP3
@@ -611,3 +629,120 @@ void __init omap3_ctrl_init(void)
        omap3_ctrl_setup_d2d_padconf();
 }
 #endif /* CONFIG_ARCH_OMAP3 && CONFIG_PM */
+
+struct control_init_data {
+       int index;
+       s16 offset;
+};
+
+static struct control_init_data ctrl_data = {
+       .index = TI_CLKM_CTRL,
+};
+
+static const struct control_init_data omap2_ctrl_data = {
+       .index = TI_CLKM_CTRL,
+       .offset = -OMAP2_CONTROL_GENERAL,
+};
+
+static const struct of_device_id omap_scrm_dt_match_table[] = {
+       { .compatible = "ti,am3-scm", .data = &ctrl_data },
+       { .compatible = "ti,am4-scm", .data = &ctrl_data },
+       { .compatible = "ti,omap2-scm", .data = &omap2_ctrl_data },
+       { .compatible = "ti,omap3-scm", .data = &omap2_ctrl_data },
+       { .compatible = "ti,dm816-scrm", .data = &ctrl_data },
+       { .compatible = "ti,omap4-scm-core", .data = &ctrl_data },
+       { .compatible = "ti,omap5-scm-core", .data = &ctrl_data },
+       { .compatible = "ti,dra7-scm-core", .data = &ctrl_data },
+       { }
+};
+
+/**
+ * omap2_control_base_init - initialize iomappings for the control driver
+ *
+ * Detects and initializes the iomappings for the control driver, based
+ * on the DT data. Returns 0 in success, negative error value
+ * otherwise.
+ */
+int __init omap2_control_base_init(void)
+{
+       struct device_node *np;
+       const struct of_device_id *match;
+       struct control_init_data *data;
+
+       for_each_matching_node_and_match(np, omap_scrm_dt_match_table, &match) {
+               data = (struct control_init_data *)match->data;
+
+               omap2_ctrl_base = of_iomap(np, 0);
+               if (!omap2_ctrl_base)
+                       return -ENOMEM;
+
+               omap2_ctrl_offset = data->offset;
+       }
+
+       return 0;
+}
+
+/**
+ * omap_control_init - low level init for the control driver
+ *
+ * Initializes the low level clock infrastructure for control driver.
+ * Returns 0 in success, negative error value in failure.
+ */
+int __init omap_control_init(void)
+{
+       struct device_node *np, *scm_conf;
+       const struct of_device_id *match;
+       const struct omap_prcm_init_data *data;
+       int ret;
+       struct regmap *syscon;
+
+       for_each_matching_node_and_match(np, omap_scrm_dt_match_table, &match) {
+               data = match->data;
+
+               /*
+                * Check if we have scm_conf node, if yes, use this to
+                * access clock registers.
+                */
+               scm_conf = of_get_child_by_name(np, "scm_conf");
+
+               if (scm_conf) {
+                       syscon = syscon_node_to_regmap(scm_conf);
+
+                       if (IS_ERR(syscon))
+                               return PTR_ERR(syscon);
+
+                       omap2_ctrl_syscon = syscon;
+
+                       if (of_get_child_by_name(scm_conf, "clocks")) {
+                               ret = omap2_clk_provider_init(scm_conf,
+                                                             data->index,
+                                                             syscon, NULL);
+                               if (ret)
+                                       return ret;
+                       }
+
+                       iounmap(omap2_ctrl_base);
+                       omap2_ctrl_base = NULL;
+               } else {
+                       /* No scm_conf found, direct access */
+                       ret = omap2_clk_provider_init(np, data->index, NULL,
+                                                     omap2_ctrl_base);
+                       if (ret)
+                               return ret;
+               }
+       }
+
+       return 0;
+}
+
+/**
+ * omap3_control_legacy_iomap_init - legacy iomap init for clock providers
+ *
+ * Legacy iomap init for clock provider. Needed only by legacy boot mode,
+ * where the base addresses are not parsed from DT, but still required
+ * by the clock driver to be setup properly.
+ */
+void __init omap3_control_legacy_iomap_init(void)
+{
+       omap2_clk_legacy_provider_init(TI_CLKM_SCRM, omap2_ctrl_base);
+}
index b8a48718121015931c1d7d90092dd1161a5c4efb..80d2b7d8e36ed56e76dfb585fb04995e5b04a18b 100644 (file)
 
 #ifndef __ASSEMBLY__
 #ifdef CONFIG_ARCH_OMAP2PLUS
-extern void __iomem *omap_ctrl_base_get(void);
 extern u8 omap_ctrl_readb(u16 offset);
 extern u16 omap_ctrl_readw(u16 offset);
 extern u32 omap_ctrl_readl(u16 offset);
-extern u32 omap4_ctrl_pad_readl(u16 offset);
 extern void omap_ctrl_writeb(u8 val, u16 offset);
 extern void omap_ctrl_writew(u16 val, u16 offset);
 extern void omap_ctrl_writel(u32 val, u16 offset);
-extern void omap4_ctrl_pad_writel(u32 val, u16 offset);
 
 extern void omap3_save_scratchpad_contents(void);
 extern void omap3_clear_scratchpad_contents(void);
@@ -464,10 +461,11 @@ extern void omap_ctrl_write_dsp_boot_mode(u8 bootmode);
 extern void omap3630_ctrl_disable_rta(void);
 extern int omap3_ctrl_save_padconf(void);
 void omap3_ctrl_init(void);
-extern void omap2_set_globals_control(void __iomem *ctrl,
-                                     void __iomem *ctrl_pad);
+int omap2_control_base_init(void);
+int omap_control_init(void);
+void omap2_set_globals_control(void __iomem *ctrl);
+void __init omap3_control_legacy_iomap_init(void);
 #else
-#define omap_ctrl_base_get()           0
 #define omap_ctrl_readb(x)             0
 #define omap_ctrl_readw(x)             0
 #define omap_ctrl_readl(x)             0
index 7a050f9c37ff2bf9bd5e8c0ccd75f8f16510b86f..f492ae147c6ac6752aaeb74b921c2861a1d8cd2a 100644 (file)
@@ -26,6 +26,8 @@
 #include <linux/of.h>
 #include <linux/of_platform.h>
 #include <linux/slab.h>
+#include <linux/mfd/syscon.h>
+#include <linux/regmap.h>
 
 #include <video/omapdss.h>
 #include "omap_hwmod.h"
@@ -104,6 +106,10 @@ static const struct omap_dss_hwmod_data omap4_dss_hwmod_data[] __initconst = {
        { "dss_hdmi", "omapdss_hdmi", -1 },
 };
 
+#define OMAP4_DSIPHY_SYSCON_OFFSET             0x78
+
+static struct regmap *omap4_dsi_mux_syscon;
+
 static int omap4_dsi_mux_pads(int dsi_id, unsigned lanes)
 {
        u32 enable_mask, enable_shift;
@@ -124,7 +130,7 @@ static int omap4_dsi_mux_pads(int dsi_id, unsigned lanes)
                return -ENODEV;
        }
 
-       reg = omap4_ctrl_pad_readl(OMAP4_CTRL_MODULE_PAD_CORE_CONTROL_DSIPHY);
+       regmap_read(omap4_dsi_mux_syscon, OMAP4_DSIPHY_SYSCON_OFFSET, &reg);
 
        reg &= ~enable_mask;
        reg &= ~pipd_mask;
@@ -132,7 +138,7 @@ static int omap4_dsi_mux_pads(int dsi_id, unsigned lanes)
        reg |= (lanes << enable_shift) & enable_mask;
        reg |= (lanes << pipd_shift) & pipd_mask;
 
-       omap4_ctrl_pad_writel(reg, OMAP4_CTRL_MODULE_PAD_CORE_CONTROL_DSIPHY);
+       regmap_write(omap4_dsi_mux_syscon, OMAP4_DSIPHY_SYSCON_OFFSET, reg);
 
        return 0;
 }
@@ -665,5 +671,10 @@ int __init omapdss_init_of(void)
                return r;
        }
 
+       /* add DSI info for omap4 */
+       node = of_find_node_by_name(NULL, "omap4_padconf_global");
+       if (node)
+               omap4_dsi_mux_syscon = syscon_node_to_regmap(node);
+
        return 0;
 }
index 2a2f4d56e4c85ea599b295a10d09c2bf922bdc79..f8121dbc9d487bc1a85dc0ed091e216d73517ea8 100644 (file)
@@ -52,7 +52,10 @@ EXPORT_SYMBOL(omap_rev);
 
 int omap_type(void)
 {
-       u32 val = 0;
+       static u32 val = OMAP2_DEVICETYPE_MASK;
+
+       if (val < OMAP2_DEVICETYPE_MASK)
+               return val;
 
        if (cpu_is_omap24xx()) {
                val = omap_ctrl_readl(OMAP24XX_CONTROL_STATUS);
index c4871c55bd8b641544a86a281121cad4c9219e42..820dde8b5b0453f96a6a3c53a4db8e4c3c9abca6 100644 (file)
@@ -306,7 +306,6 @@ void __init am33xx_map_io(void)
 void __init omap4_map_io(void)
 {
        iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc));
-       omap_barriers_init();
 }
 #endif
 
@@ -314,7 +313,6 @@ void __init omap4_map_io(void)
 void __init omap5_map_io(void)
 {
        iotable_init(omap54xx_io_desc, ARRAY_SIZE(omap54xx_io_desc));
-       omap_barriers_init();
 }
 #endif
 /*
@@ -384,13 +382,9 @@ void __init omap2420_init_early(void)
        omap2_set_globals_tap(OMAP242X_CLASS, OMAP2_L4_IO_ADDRESS(0x48014000));
        omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP2420_SDRC_BASE),
                               OMAP2_L3_IO_ADDRESS(OMAP2420_SMS_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP242X_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2420_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2420_CM_BASE), NULL);
+       omap2_control_base_init();
        omap2xxx_check_revision();
-       omap2xxx_prm_init();
-       omap2xxx_cm_init();
+       omap2_prcm_base_init();
        omap2xxx_voltagedomains_init();
        omap242x_powerdomains_init();
        omap242x_clockdomains_init();
@@ -414,13 +408,9 @@ void __init omap2430_init_early(void)
        omap2_set_globals_tap(OMAP243X_CLASS, OMAP2_L4_IO_ADDRESS(0x4900a000));
        omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP243X_SDRC_BASE),
                               OMAP2_L3_IO_ADDRESS(OMAP243X_SMS_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP243X_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP2430_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP2430_CM_BASE), NULL);
+       omap2_control_base_init();
        omap2xxx_check_revision();
-       omap2xxx_prm_init();
-       omap2xxx_cm_init();
+       omap2_prcm_base_init();
        omap2xxx_voltagedomains_init();
        omap243x_powerdomains_init();
        omap243x_clockdomains_init();
@@ -448,21 +438,30 @@ void __init omap3_init_early(void)
        omap2_set_globals_tap(OMAP343X_CLASS, OMAP2_L4_IO_ADDRESS(0x4830A000));
        omap2_set_globals_sdrc(OMAP2_L3_IO_ADDRESS(OMAP343X_SDRC_BASE),
                               OMAP2_L3_IO_ADDRESS(OMAP343X_SMS_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP3430_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP3430_CM_BASE), NULL);
+       /* XXX: remove these once OMAP3 is DT only */
+       if (!of_have_populated_dt()) {
+               omap2_set_globals_control(
+                       OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE));
+               omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP3430_PRM_BASE));
+               omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP3430_CM_BASE),
+                                    NULL);
+       }
+       omap2_control_base_init();
        omap3xxx_check_revision();
        omap3xxx_check_features();
-       omap3xxx_prm_init();
-       omap3xxx_cm_init();
+       omap2_prcm_base_init();
+       /* XXX: remove these once OMAP3 is DT only */
+       if (!of_have_populated_dt()) {
+               omap3xxx_prm_init(NULL);
+               omap3xxx_cm_init(NULL);
+       }
        omap3xxx_voltagedomains_init();
        omap3xxx_powerdomains_init();
        omap3xxx_clockdomains_init();
        omap3xxx_hwmod_init();
        omap_hwmod_init_postsetup();
        if (!of_have_populated_dt()) {
-               omap3_prcm_legacy_iomaps_init();
+               omap3_control_legacy_iomap_init();
                if (soc_is_am35xx())
                        omap_clk_soc_init = am35xx_clk_legacy_init;
                else if (cpu_is_omap3630())
@@ -549,14 +548,10 @@ void __init ti814x_init_early(void)
 {
        omap2_set_globals_tap(TI814X_CLASS,
                              OMAP2_L4_IO_ADDRESS(TI81XX_TAP_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(TI81XX_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE), NULL);
+       omap2_control_base_init();
        omap3xxx_check_revision();
        ti81xx_check_features();
-       am33xx_prm_init();
-       am33xx_cm_init();
+       omap2_prcm_base_init();
        omap3xxx_voltagedomains_init();
        omap3xxx_powerdomains_init();
        ti81xx_clockdomains_init();
@@ -570,14 +565,10 @@ void __init ti816x_init_early(void)
 {
        omap2_set_globals_tap(TI816X_CLASS,
                              OMAP2_L4_IO_ADDRESS(TI81XX_TAP_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(TI81XX_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(TI81XX_PRCM_BASE), NULL);
+       omap2_control_base_init();
        omap3xxx_check_revision();
        ti81xx_check_features();
-       am33xx_prm_init();
-       am33xx_cm_init();
+       omap2_prcm_base_init();
        omap3xxx_voltagedomains_init();
        omap3xxx_powerdomains_init();
        ti81xx_clockdomains_init();
@@ -593,14 +584,10 @@ void __init am33xx_init_early(void)
 {
        omap2_set_globals_tap(AM335X_CLASS,
                              AM33XX_L4_WK_IO_ADDRESS(AM33XX_TAP_BASE));
-       omap2_set_globals_control(AM33XX_L4_WK_IO_ADDRESS(AM33XX_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE));
-       omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM33XX_PRCM_BASE), NULL);
+       omap2_control_base_init();
        omap3xxx_check_revision();
        am33xx_check_features();
-       am33xx_prm_init();
-       am33xx_cm_init();
+       omap2_prcm_base_init();
        am33xx_powerdomains_init();
        am33xx_clockdomains_init();
        am33xx_hwmod_init();
@@ -619,16 +606,10 @@ void __init am43xx_init_early(void)
 {
        omap2_set_globals_tap(AM335X_CLASS,
                              AM33XX_L4_WK_IO_ADDRESS(AM33XX_TAP_BASE));
-       omap2_set_globals_control(AM33XX_L4_WK_IO_ADDRESS(AM33XX_CTRL_BASE),
-                                 NULL);
-       omap2_set_globals_prm(AM33XX_L4_WK_IO_ADDRESS(AM43XX_PRCM_BASE));
-       omap2_set_globals_cm(AM33XX_L4_WK_IO_ADDRESS(AM43XX_PRCM_BASE), NULL);
-       omap_prm_base_init();
-       omap_cm_base_init();
+       omap2_control_base_init();
        omap3xxx_check_revision();
        am33xx_check_features();
-       omap44xx_prm_init();
-       omap4_cm_init();
+       omap2_prcm_base_init();
        am43xx_powerdomains_init();
        am43xx_clockdomains_init();
        am43xx_hwmod_init();
@@ -648,19 +629,12 @@ void __init omap4430_init_early(void)
 {
        omap2_set_globals_tap(OMAP443X_CLASS,
                              OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP443X_SCM_BASE),
-                                 OMAP2_L4_IO_ADDRESS(OMAP443X_CTRL_BASE));
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP4430_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP4430_CM_BASE),
-                            OMAP2_L4_IO_ADDRESS(OMAP4430_CM2_BASE));
        omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP4430_PRCM_MPU_BASE));
-       omap_prm_base_init();
-       omap_cm_base_init();
+       omap2_control_base_init();
        omap4xxx_check_revision();
        omap4xxx_check_features();
-       omap4_cm_init();
+       omap2_prcm_base_init();
        omap4_pm_init_early();
-       omap44xx_prm_init();
        omap44xx_voltagedomains_init();
        omap44xx_powerdomains_init();
        omap44xx_clockdomains_init();
@@ -683,18 +657,11 @@ void __init omap5_init_early(void)
 {
        omap2_set_globals_tap(OMAP54XX_CLASS,
                              OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE),
-                                 OMAP2_L4_IO_ADDRESS(OMAP54XX_CTRL_BASE));
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_AON_BASE),
-                            OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_BASE));
        omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRCM_MPU_BASE));
+       omap2_control_base_init();
        omap4_pm_init_early();
-       omap_prm_base_init();
-       omap_cm_base_init();
-       omap44xx_prm_init();
+       omap2_prcm_base_init();
        omap5xxx_check_revision();
-       omap4_cm_init();
        omap54xx_voltagedomains_init();
        omap54xx_powerdomains_init();
        omap54xx_clockdomains_init();
@@ -715,18 +682,11 @@ void __init omap5_init_late(void)
 void __init dra7xx_init_early(void)
 {
        omap2_set_globals_tap(-1, OMAP2_L4_IO_ADDRESS(DRA7XX_TAP_BASE));
-       omap2_set_globals_control(OMAP2_L4_IO_ADDRESS(OMAP54XX_SCM_BASE),
-                                 OMAP2_L4_IO_ADDRESS(DRA7XX_CTRL_BASE));
-       omap2_set_globals_prm(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRM_BASE));
-       omap2_set_globals_cm(OMAP2_L4_IO_ADDRESS(DRA7XX_CM_CORE_AON_BASE),
-                            OMAP2_L4_IO_ADDRESS(OMAP54XX_CM_CORE_BASE));
        omap2_set_globals_prcm_mpu(OMAP2_L4_IO_ADDRESS(OMAP54XX_PRCM_MPU_BASE));
+       omap2_control_base_init();
        omap4_pm_init_early();
-       omap_prm_base_init();
-       omap_cm_base_init();
-       omap44xx_prm_init();
+       omap2_prcm_base_init();
        dra7xxx_check_revision();
-       omap4_cm_init();
        dra7xx_powerdomains_init();
        dra7xx_clockdomains_init();
        dra7xx_hwmod_init();
@@ -764,7 +724,11 @@ int __init omap_clk_init(void)
        ti_clk_init_features();
 
        if (of_have_populated_dt()) {
-               ret = of_prcm_init();
+               ret = omap_control_init();
+               if (ret)
+                       return ret;
+
+               ret = omap_prcm_init();
                if (ret)
                        return ret;
 
index 78064b0d4db56be1154a1262107e26801ee0eeee..176eef6ef338267f8ab67d1adf47b49ca0cdc72a 100644 (file)
@@ -1053,7 +1053,7 @@ static void __init omap_mux_init_list(struct omap_mux_partition *partition,
                struct omap_mux *entry;
 
 #ifdef CONFIG_OMAP_MUX
-               if (!superset->muxnames || !superset->muxnames[0]) {
+               if (!superset->muxnames[0]) {
                        superset++;
                        continue;
                }
index dec2b05d184bd329cf990fef3477bfe36f1bb7cb..af2851fbcdf02e224bb196dc805500b788e0a400 100644 (file)
@@ -70,13 +70,6 @@ extern u32 rx51_secure_dispatcher(u32 idx, u32 process, u32 flag, u32 nargs,
 extern u32 rx51_secure_update_aux_cr(u32 set_bits, u32 clear_bits);
 extern u32 rx51_secure_rng_call(u32 ptr, u32 count, u32 flag);
 
-#ifdef CONFIG_OMAP4_ERRATA_I688
-extern int omap_barrier_reserve_memblock(void);
-#else
-static inline void omap_barrier_reserve_memblock(void)
-{ }
-#endif
-
 #ifdef CONFIG_SOC_HAS_REALTIME_COUNTER
 void set_cntfreq(void);
 #else
index cee0fe1ee6ffb0d3e5026a7328458feb34dc2732..afaac9e257646df7de4b3a316ac1e13bee095afb 100644 (file)
@@ -52,75 +52,6 @@ static void __iomem *twd_base;
 
 #define IRQ_LOCALTIMER         29
 
-#ifdef CONFIG_OMAP4_ERRATA_I688
-/* Used to implement memory barrier on DRAM path */
-#define OMAP4_DRAM_BARRIER_VA                  0xfe600000
-
-void __iomem *dram_sync, *sram_sync;
-
-static phys_addr_t paddr;
-static u32 size;
-
-void omap_bus_sync(void)
-{
-       if (dram_sync && sram_sync) {
-               writel_relaxed(readl_relaxed(dram_sync), dram_sync);
-               writel_relaxed(readl_relaxed(sram_sync), sram_sync);
-               isb();
-       }
-}
-EXPORT_SYMBOL(omap_bus_sync);
-
-static int __init omap4_sram_init(void)
-{
-       struct device_node *np;
-       struct gen_pool *sram_pool;
-
-       np = of_find_compatible_node(NULL, NULL, "ti,omap4-mpu");
-       if (!np)
-               pr_warn("%s:Unable to allocate sram needed to handle errata I688\n",
-                       __func__);
-       sram_pool = of_get_named_gen_pool(np, "sram", 0);
-       if (!sram_pool)
-               pr_warn("%s:Unable to get sram pool needed to handle errata I688\n",
-                       __func__);
-       else
-               sram_sync = (void *)gen_pool_alloc(sram_pool, PAGE_SIZE);
-
-       return 0;
-}
-omap_arch_initcall(omap4_sram_init);
-
-/* Steal one page physical memory for barrier implementation */
-int __init omap_barrier_reserve_memblock(void)
-{
-
-       size = ALIGN(PAGE_SIZE, SZ_1M);
-       paddr = arm_memblock_steal(size, SZ_1M);
-
-       return 0;
-}
-
-void __init omap_barriers_init(void)
-{
-       struct map_desc dram_io_desc[1];
-
-       dram_io_desc[0].virtual = OMAP4_DRAM_BARRIER_VA;
-       dram_io_desc[0].pfn = __phys_to_pfn(paddr);
-       dram_io_desc[0].length = size;
-       dram_io_desc[0].type = MT_MEMORY_RW_SO;
-       iotable_init(dram_io_desc, ARRAY_SIZE(dram_io_desc));
-       dram_sync = (void __iomem *) dram_io_desc[0].virtual;
-
-       pr_info("OMAP4: Map 0x%08llx to 0x%08lx for dram barrier\n",
-               (long long) paddr, dram_io_desc[0].virtual);
-
-}
-#else
-void __init omap_barriers_init(void)
-{}
-#endif
-
 void gic_dist_disable(void)
 {
        if (gic_dist_base_addr)
index fe01c5a03aa242ccf3abd62bdd8d65e84ae29a27..b1aad7e1426c62e9a394b72a09dfc48ab361f348 100644 (file)
@@ -75,9 +75,9 @@ static int omap2_enter_full_retention(void)
 
        /* Clear old wake-up events */
        /* REVISIT: These write to reserved bits? */
-       omap2xxx_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
-       omap2xxx_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
-       omap2xxx_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, ~0);
+       omap_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
+       omap_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
+       omap_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, ~0);
 
        pwrdm_set_next_pwrst(core_pwrdm, PWRDM_POWER_RET);
        pwrdm_set_next_pwrst(mpu_pwrdm, PWRDM_POWER_RET);
@@ -104,18 +104,16 @@ no_sleep:
        clk_enable(osc_ck);
 
        /* clear CORE wake-up events */
-       omap2xxx_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
-       omap2xxx_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
+       omap_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
+       omap_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
 
        /* wakeup domain events - bit 1: GPT1, bit5 GPIO */
-       omap2xxx_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, 0x4 | 0x1);
+       omap_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, 0x4 | 0x1);
 
        /* MPU domain wake events */
-       omap2xxx_prm_clear_mod_irqs(OCP_MOD, OMAP2_PRCM_IRQSTATUS_MPU_OFFSET,
-                                   0x1);
+       omap_prm_clear_mod_irqs(OCP_MOD, OMAP2_PRCM_IRQSTATUS_MPU_OFFSET, 0x1);
 
-       omap2xxx_prm_clear_mod_irqs(OCP_MOD, OMAP2_PRCM_IRQSTATUS_MPU_OFFSET,
-                                   0x20);
+       omap_prm_clear_mod_irqs(OCP_MOD, OMAP2_PRCM_IRQSTATUS_MPU_OFFSET, 0x20);
 
        pwrdm_set_next_pwrst(mpu_pwrdm, PWRDM_POWER_ON);
        pwrdm_set_next_pwrst(core_pwrdm, PWRDM_POWER_ON);
@@ -143,9 +141,9 @@ static void omap2_enter_mpu_retention(void)
         * it is in retention mode. */
        if (omap2_allow_mpu_retention()) {
                /* REVISIT: These write to reserved bits? */
-               omap2xxx_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
-               omap2xxx_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
-               omap2xxx_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, ~0);
+               omap_prm_clear_mod_irqs(CORE_MOD, PM_WKST1, ~0);
+               omap_prm_clear_mod_irqs(CORE_MOD, OMAP24XX_PM_WKST2, ~0);
+               omap_prm_clear_mod_irqs(WKUP_MOD, PM_WKST, ~0);
 
                /* Try to enter MPU retention */
                pwrdm_set_next_pwrst(mpu_pwrdm, PWRDM_POWER_RET);
index 88721df6001d0ef7741aa377ef853dc89cb67bca..87b98bf92366f4f816ca4f53a32ecae305930016 100644 (file)
@@ -137,9 +137,8 @@ static irqreturn_t _prcm_int_handle_io(int irq, void *unused)
 {
        int c;
 
-       c = omap3xxx_prm_clear_mod_irqs(WKUP_MOD, 1,
-                                       ~(OMAP3430_ST_IO_MASK |
-                                         OMAP3430_ST_IO_CHAIN_MASK));
+       c = omap_prm_clear_mod_irqs(WKUP_MOD, 1, OMAP3430_ST_IO_MASK |
+                                   OMAP3430_ST_IO_CHAIN_MASK);
 
        return c ? IRQ_HANDLED : IRQ_NONE;
 }
@@ -153,14 +152,13 @@ static irqreturn_t _prcm_int_handle_wakeup(int irq, void *unused)
         * these are handled in a separate handler to avoid acking
         * IO events before parsing in mux code
         */
-       c = omap3xxx_prm_clear_mod_irqs(WKUP_MOD, 1,
-                                       OMAP3430_ST_IO_MASK |
-                                       OMAP3430_ST_IO_CHAIN_MASK);
-       c += omap3xxx_prm_clear_mod_irqs(CORE_MOD, 1, 0);
-       c += omap3xxx_prm_clear_mod_irqs(OMAP3430_PER_MOD, 1, 0);
+       c = omap_prm_clear_mod_irqs(WKUP_MOD, 1, ~(OMAP3430_ST_IO_MASK |
+                                                  OMAP3430_ST_IO_CHAIN_MASK));
+       c += omap_prm_clear_mod_irqs(CORE_MOD, 1, ~0);
+       c += omap_prm_clear_mod_irqs(OMAP3430_PER_MOD, 1, ~0);
        if (omap_rev() > OMAP3430_REV_ES1_0) {
-               c += omap3xxx_prm_clear_mod_irqs(CORE_MOD, 3, 0);
-               c += omap3xxx_prm_clear_mod_irqs(OMAP3430ES2_USBHOST_MOD, 1, 0);
+               c += omap_prm_clear_mod_irqs(CORE_MOD, 3, ~0);
+               c += omap_prm_clear_mod_irqs(OMAP3430ES2_USBHOST_MOD, 1, ~0);
        }
 
        return c ? IRQ_HANDLED : IRQ_NONE;
index 6163d66102a3561890240487a592964874cb260c..6ae0b3a1781e99deee4f2cdc8699a4f434ad7fa3 100644 (file)
@@ -518,6 +518,26 @@ struct omap_prcm_irq_setup {
        .priority = _priority                           \
        }
 
+/**
+ * struct omap_prcm_init_data - PRCM driver init data
+ * @index: clock memory mapping index to be used
+ * @mem: IO mem pointer for this module
+ * @offset: module base address offset from the IO base
+ * @flags: PRCM module init flags
+ * @device_inst_offset: device instance offset within the module address space
+ * @init: low level PRCM init function for this module
+ * @np: device node for this PRCM module
+ */
+struct omap_prcm_init_data {
+       int index;
+       void __iomem *mem;
+       s16 offset;
+       u16 flags;
+       s32 device_inst_offset;
+       int (*init)(const struct omap_prcm_init_data *data);
+       struct device_node *np;
+};
+
 extern void omap_prcm_irq_cleanup(void);
 extern int omap_prcm_register_chain_handler(
        struct omap_prcm_irq_setup *irq_setup);
index b9061a6a2db8998314cf83dc0aa98dab2899ce43..233bc84fbc0e4ee13248a388a76e7c0270b819a4 100644 (file)
@@ -19,8 +19,9 @@
 extern void __iomem *prm_base;
 extern u16 prm_features;
 extern void omap2_set_globals_prm(void __iomem *prm);
-int of_prcm_init(void);
-void omap3_prcm_legacy_iomaps_init(void);
+int omap_prcm_init(void);
+int omap2_prm_base_init(void);
+int omap2_prcm_base_init(void);
 # endif
 
 /*
@@ -28,9 +29,11 @@ void omap3_prcm_legacy_iomaps_init(void);
  *
  * PRM_HAS_IO_WAKEUP: has IO wakeup capability
  * PRM_HAS_VOLTAGE: has voltage domains
+ * PRM_IRQ_DEFAULT: use default irq number for PRM irq
  */
-#define PRM_HAS_IO_WAKEUP      (1 << 0)
-#define PRM_HAS_VOLTAGE                (1 << 1)
+#define PRM_HAS_IO_WAKEUP      BIT(0)
+#define PRM_HAS_VOLTAGE                BIT(1)
+#define PRM_IRQ_DEFAULT                BIT(2)
 
 /*
  * MAX_MODULE_SOFTRESET_WAIT: Maximum microseconds to wait for OMAP
@@ -146,6 +149,9 @@ struct prm_ll_data {
        int (*is_hardreset_asserted)(u8 shift, u8 part, s16 prm_mod,
                                     u16 offset);
        void (*reset_system)(void);
+       int (*clear_mod_irqs)(s16 module, u8 regs, u32 wkst_mask);
+       u32 (*vp_check_txdone)(u8 vp_id);
+       void (*vp_clear_txdone)(u8 vp_id);
 };
 
 extern int prm_register(struct prm_ll_data *pld);
@@ -161,6 +167,19 @@ extern void prm_clear_context_loss_flags_old(u8 part, s16 inst, u16 idx);
 void omap_prm_reset_system(void);
 
 void omap_prm_reconfigure_io_chain(void);
+int omap_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask);
+
+/*
+ * Voltage Processor (VP) identifiers
+ */
+#define OMAP3_VP_VDD_MPU_ID    0
+#define OMAP3_VP_VDD_CORE_ID   1
+#define OMAP4_VP_VDD_CORE_ID   0
+#define OMAP4_VP_VDD_IVA_ID    1
+#define OMAP4_VP_VDD_MPU_ID    2
+
+u32 omap_prm_vp_check_txdone(u8 vp_id);
+void omap_prm_vp_clear_txdone(u8 vp_id);
 
 #endif
 
index af0f15278fc2afc2d7480da370cba6cafac9d2f6..752018ce129ca953669686445371143962e12376 100644 (file)
@@ -123,13 +123,14 @@ static void omap2xxx_prm_dpll_reset(void)
  * Clears wakeup status bits for a given module, so that the device can
  * re-enter idle.
  */
-void omap2xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask)
+static int omap2xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask)
 {
        u32 wkst;
 
        wkst = omap2_prm_read_mod_reg(module, regs);
        wkst &= wkst_mask;
        omap2_prm_write_mod_reg(wkst, module, regs);
+       return 0;
 }
 
 int omap2xxx_clkdm_sleep(struct clockdomain *clkdm)
@@ -216,9 +217,10 @@ static struct prm_ll_data omap2xxx_prm_ll_data = {
        .deassert_hardreset = &omap2_prm_deassert_hardreset,
        .is_hardreset_asserted = &omap2_prm_is_hardreset_asserted,
        .reset_system = &omap2xxx_prm_dpll_reset,
+       .clear_mod_irqs = &omap2xxx_prm_clear_mod_irqs,
 };
 
-int __init omap2xxx_prm_init(void)
+int __init omap2xxx_prm_init(const struct omap_prcm_init_data *data)
 {
        return prm_register(&omap2xxx_prm_ll_data);
 }
index 1d51643062f7957dec8b9be7a66fcbf11d3e5de9..9008a9e55a1ac750535034c0ce48b6c9f8413eaf 100644 (file)
 extern int omap2xxx_clkdm_sleep(struct clockdomain *clkdm);
 extern int omap2xxx_clkdm_wakeup(struct clockdomain *clkdm);
 
-void omap2xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask);
-
-extern int __init omap2xxx_prm_init(void);
+int __init omap2xxx_prm_init(const struct omap_prcm_init_data *data);
 
 #endif
 
index 02f628601b098799e2b73354215ac33a411abe3b..dcb5001d77da3d487c9bfb8674f4de6d3aab9db2 100644 (file)
@@ -378,7 +378,7 @@ static struct prm_ll_data am33xx_prm_ll_data = {
        .reset_system                   = am33xx_prm_global_warm_sw_reset,
 };
 
-int __init am33xx_prm_init(void)
+int __init am33xx_prm_init(const struct omap_prcm_init_data *data)
 {
        return prm_register(&am33xx_prm_ll_data);
 }
index 98ac41f271da3460378a11a44468504f11ed0f32..2bc4ec52ba78da3d17d33be25936db3a91cf5f1e 100644 (file)
 #define AM33XX_PM_CEFUSE_PWRSTST               AM33XX_PRM_REGADDR(AM33XX_PRM_CEFUSE_MOD, 0x0004)
 
 #ifndef __ASSEMBLER__
-int am33xx_prm_init(void);
+int am33xx_prm_init(const struct omap_prcm_init_data *data);
 
 #endif /* ASSEMBLER */
 #endif
index 5713bbdf83bc57ac7314f6e27455e3851772bc09..62680aad212666af7f07131546ff1e9bc01c2572 100644 (file)
@@ -29,6 +29,7 @@
 #include "prm-regbits-34xx.h"
 #include "cm3xxx.h"
 #include "cm-regbits-34xx.h"
+#include "clock.h"
 
 static void omap3xxx_prm_read_pending_irqs(unsigned long *events);
 static void omap3xxx_prm_ocp_barrier(void);
@@ -96,7 +97,7 @@ static struct omap3_vp omap3_vp[] = {
 
 #define MAX_VP_ID ARRAY_SIZE(omap3_vp);
 
-u32 omap3_prm_vp_check_txdone(u8 vp_id)
+static u32 omap3_prm_vp_check_txdone(u8 vp_id)
 {
        struct omap3_vp *vp = &omap3_vp[vp_id];
        u32 irqstatus;
@@ -106,7 +107,7 @@ u32 omap3_prm_vp_check_txdone(u8 vp_id)
        return irqstatus & vp->tranxdone_status;
 }
 
-void omap3_prm_vp_clear_txdone(u8 vp_id)
+static void omap3_prm_vp_clear_txdone(u8 vp_id)
 {
        struct omap3_vp *vp = &omap3_vp[vp_id];
 
@@ -217,7 +218,7 @@ static void omap3xxx_prm_restore_irqen(u32 *saved_mask)
  * omap3xxx_prm_clear_mod_irqs - clear wake-up events from PRCM interrupt
  * @module: PRM module to clear wakeups from
  * @regs: register set to clear, 1 or 3
- * @ignore_bits: wakeup status bits to ignore
+ * @wkst_mask: wkst bits to clear
  *
  * The purpose of this function is to clear any wake-up events latched
  * in the PRCM PM_WKST_x registers. It is possible that a wake-up event
@@ -226,7 +227,7 @@ static void omap3xxx_prm_restore_irqen(u32 *saved_mask)
  * that any peripheral wake-up events occurring while attempting to
  * clear the PM_WKST_x are detected and cleared.
  */
-int omap3xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 ignore_bits)
+static int omap3xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask)
 {
        u32 wkst, fclk, iclk, clken;
        u16 wkst_off = (regs == 3) ? OMAP3430ES2_PM_WKST3 : PM_WKST1;
@@ -238,7 +239,7 @@ int omap3xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 ignore_bits)
 
        wkst = omap2_prm_read_mod_reg(module, wkst_off);
        wkst &= omap2_prm_read_mod_reg(module, grpsel_off);
-       wkst &= ~ignore_bits;
+       wkst &= wkst_mask;
        if (wkst) {
                iclk = omap2_cm_read_mod_reg(module, iclk_off);
                fclk = omap2_cm_read_mod_reg(module, fclk_off);
@@ -254,7 +255,7 @@ int omap3xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 ignore_bits)
                        omap2_cm_set_mod_reg_bits(clken, module, fclk_off);
                        omap2_prm_write_mod_reg(wkst, module, wkst_off);
                        wkst = omap2_prm_read_mod_reg(module, wkst_off);
-                       wkst &= ~ignore_bits;
+                       wkst &= wkst_mask;
                        c++;
                }
                omap2_cm_write_mod_reg(iclk, module, iclk_off);
@@ -664,10 +665,15 @@ static struct prm_ll_data omap3xxx_prm_ll_data = {
        .deassert_hardreset = &omap2_prm_deassert_hardreset,
        .is_hardreset_asserted = &omap2_prm_is_hardreset_asserted,
        .reset_system = &omap3xxx_prm_dpll3_reset,
+       .clear_mod_irqs = &omap3xxx_prm_clear_mod_irqs,
+       .vp_check_txdone = &omap3_prm_vp_check_txdone,
+       .vp_clear_txdone = &omap3_prm_vp_clear_txdone,
 };
 
-int __init omap3xxx_prm_init(void)
+int __init omap3xxx_prm_init(const struct omap_prcm_init_data *data)
 {
+       omap2_clk_legacy_provider_init(TI_CLKM_PRM,
+                                      prm_base + OMAP3430_IVA2_MOD);
        if (omap3_has_io_wakeup())
                prm_features |= PRM_HAS_IO_WAKEUP;
 
index ed8a3d8b739a87578416775bf135fc8ce139a0de..5f095eec339c0627fc6c93faff62201d5990d4ca 100644 (file)
 
 #ifndef __ASSEMBLER__
 
-/* OMAP3-specific VP functions */
-u32 omap3_prm_vp_check_txdone(u8 vp_id);
-void omap3_prm_vp_clear_txdone(u8 vp_id);
-
 /*
  * OMAP3 access functions for voltage controller (VC) and
  * voltage proccessor (VP) in the PRM.
@@ -144,8 +140,7 @@ extern u32 omap3_prm_vcvp_read(u8 offset);
 extern void omap3_prm_vcvp_write(u32 val, u8 offset);
 extern u32 omap3_prm_vcvp_rmw(u32 mask, u32 bits, u8 offset);
 
-extern int __init omap3xxx_prm_init(void);
-int omap3xxx_prm_clear_mod_irqs(s16 module, u8 regs, u32 ignore_bits);
+int __init omap3xxx_prm_init(const struct omap_prcm_init_data *data);
 void omap3xxx_prm_iva_idle(void);
 void omap3_prm_reset_modem(void);
 int omap3xxx_prm_clear_global_cold_reset(void);
index a08a617a6c110365cf20ce9c5df54edef19c20c5..c35ad0bedf81f0fff6aae4a3dac9c8efb8b59c49 100644 (file)
@@ -138,7 +138,7 @@ static struct omap4_vp omap4_vp[] = {
        },
 };
 
-u32 omap4_prm_vp_check_txdone(u8 vp_id)
+static u32 omap4_prm_vp_check_txdone(u8 vp_id)
 {
        struct omap4_vp *vp = &omap4_vp[vp_id];
        u32 irqstatus;
@@ -149,7 +149,7 @@ u32 omap4_prm_vp_check_txdone(u8 vp_id)
        return irqstatus & vp->tranxdone_status;
 }
 
-void omap4_prm_vp_clear_txdone(u8 vp_id)
+static void omap4_prm_vp_clear_txdone(u8 vp_id)
 {
        struct omap4_vp *vp = &omap4_vp[vp_id];
 
@@ -699,29 +699,31 @@ static struct prm_ll_data omap44xx_prm_ll_data = {
        .deassert_hardreset     = omap4_prminst_deassert_hardreset,
        .is_hardreset_asserted  = omap4_prminst_is_hardreset_asserted,
        .reset_system           = omap4_prminst_global_warm_sw_reset,
+       .vp_check_txdone        = omap4_prm_vp_check_txdone,
+       .vp_clear_txdone        = omap4_prm_vp_clear_txdone,
 };
 
-int __init omap44xx_prm_init(void)
+static const struct omap_prcm_init_data *prm_init_data;
+
+int __init omap44xx_prm_init(const struct omap_prcm_init_data *data)
 {
-       if (cpu_is_omap44xx() || soc_is_omap54xx() || soc_is_dra7xx())
+       omap_prm_base_init();
+
+       prm_init_data = data;
+
+       if (data->flags & PRM_HAS_IO_WAKEUP)
                prm_features |= PRM_HAS_IO_WAKEUP;
 
-       if (!soc_is_dra7xx())
+       if (data->flags & PRM_HAS_VOLTAGE)
                prm_features |= PRM_HAS_VOLTAGE;
 
+       omap4_prminst_set_prm_dev_inst(data->device_inst_offset);
+
        return prm_register(&omap44xx_prm_ll_data);
 }
 
-static const struct of_device_id omap_prm_dt_match_table[] = {
-       { .compatible = "ti,omap4-prm" },
-       { .compatible = "ti,omap5-prm" },
-       { .compatible = "ti,dra7-prm" },
-       { }
-};
-
 static int omap44xx_prm_late_init(void)
 {
-       struct device_node *np;
        int irq_num;
 
        if (!(prm_features & PRM_HAS_IO_WAKEUP))
@@ -731,31 +733,23 @@ static int omap44xx_prm_late_init(void)
        if (!of_have_populated_dt())
                return 0;
 
-       np = of_find_matching_node(NULL, omap_prm_dt_match_table);
-
-       if (!np) {
-               /* Default loaded up with OMAP4 values */
-               if (!cpu_is_omap44xx())
-                       return 0;
-       } else {
-               irq_num = of_irq_get(np, 0);
-               /*
-                * Already have OMAP4 IRQ num. For all other platforms, we need
-                * IRQ numbers from DT
-                */
-               if (irq_num < 0 && !cpu_is_omap44xx()) {
-                       if (irq_num == -EPROBE_DEFER)
-                               return irq_num;
-
-                       /* Have nothing to do */
-                       return 0;
-               }
-
-               /* Once OMAP4 DT is filled as well */
-               if (irq_num >= 0) {
-                       omap4_prcm_irq_setup.irq = irq_num;
-                       omap4_prcm_irq_setup.xlate_irq = NULL;
-               }
+       irq_num = of_irq_get(prm_init_data->np, 0);
+       /*
+        * Already have OMAP4 IRQ num. For all other platforms, we need
+        * IRQ numbers from DT
+        */
+       if (irq_num < 0 && !(prm_init_data->flags & PRM_IRQ_DEFAULT)) {
+               if (irq_num == -EPROBE_DEFER)
+                       return irq_num;
+
+               /* Have nothing to do */
+               return 0;
+       }
+
+       /* Once OMAP4 DT is filled as well */
+       if (irq_num >= 0) {
+               omap4_prcm_irq_setup.irq = irq_num;
+               omap4_prcm_irq_setup.xlate_irq = NULL;
        }
 
        omap44xx_prm_enable_io_wakeup();
index 7db2422faa16e8b788901c8f1a8396226a0e1123..efd6035d0871d4fdcf211c69adabec288d20f414 100644 (file)
@@ -26,7 +26,6 @@
 #define __ARCH_ARM_MACH_OMAP2_PRM44XX_H
 
 #include "prm44xx_54xx.h"
-#include "prcm-common.h"
 #include "prm.h"
 
 #define OMAP4430_PRM_BASE              0x4a306000
index 714329565b90b70e4509a8b4ae4583c223afdc9a..3f139ebc839895137ff5488dfb07b0b0b81047cf 100644 (file)
 #ifndef __ARCH_ARM_MACH_OMAP2_PRM44XX_54XX_H
 #define __ARCH_ARM_MACH_OMAP2_PRM44XX_54XX_H
 
+#include "prcm-common.h"
+
 /* Function prototypes */
 #ifndef __ASSEMBLER__
 
-/* OMAP4/OMAP5-specific VP functions */
-u32 omap4_prm_vp_check_txdone(u8 vp_id);
-void omap4_prm_vp_clear_txdone(u8 vp_id);
-
 /*
  * OMAP4/OMAP5 access functions for voltage controller (VC) and
  * voltage proccessor (VP) in the PRM.
@@ -38,7 +36,7 @@ extern u32 omap4_prm_vcvp_read(u8 offset);
 extern void omap4_prm_vcvp_write(u32 val, u8 offset);
 extern u32 omap4_prm_vcvp_rmw(u32 mask, u32 bits, u8 offset);
 
-extern int __init omap44xx_prm_init(void);
+int __init omap44xx_prm_init(const struct omap_prcm_init_data *data);
 
 #endif
 
index e4411010309c566cb708ef1a39dad9a01d29c81b..1eb22ff087dc207bc8ce4ec57e012c142415f38c 100644 (file)
@@ -22,7 +22,6 @@
 #define __ARCH_ARM_MACH_OMAP2_PRM54XX_H
 
 #include "prm44xx_54xx.h"
-#include "prcm-common.h"
 #include "prm.h"
 
 #define OMAP54XX_PRM_BASE              0x4ae06000
index 4bb50fbf29bebb5f546edf866665dcd29bb11d36..cc1e6a2b97f66af3b9ea53f0a1a57115aaac77a4 100644 (file)
@@ -22,8 +22,8 @@
 #ifndef __ARCH_ARM_MACH_OMAP2_PRM7XX_H
 #define __ARCH_ARM_MACH_OMAP2_PRM7XX_H
 
-#include "prm44xx_54xx.h"
 #include "prcm-common.h"
+#include "prm44xx_54xx.h"
 #include "prm.h"
 
 #define DRA7XX_PRM_BASE                0x4ae06000
index bfaa7ba595cc832ec7783e759db4425c5e1e58c0..7add7994dbfcf01496eec5182500833ab26cdd5f 100644 (file)
 #include "prm2xxx_3xxx.h"
 #include "prm2xxx.h"
 #include "prm3xxx.h"
+#include "prm33xx.h"
 #include "prm44xx.h"
+#include "prm54xx.h"
+#include "prm7xx.h"
+#include "prcm43xx.h"
 #include "common.h"
 #include "clock.h"
 #include "cm.h"
@@ -533,6 +537,61 @@ void omap_prm_reset_system(void)
                cpu_relax();
 }
 
+/**
+ * omap_prm_clear_mod_irqs - clear wake-up events from PRCM interrupt
+ * @module: PRM module to clear wakeups from
+ * @regs: register to clear
+ * @wkst_mask: wkst bits to clear
+ *
+ * Clears any wakeup events for the module and register set defined.
+ * Uses SoC specific implementation to do the actual wakeup status
+ * clearing.
+ */
+int omap_prm_clear_mod_irqs(s16 module, u8 regs, u32 wkst_mask)
+{
+       if (!prm_ll_data->clear_mod_irqs) {
+               WARN_ONCE(1, "prm: %s: no mapping function defined\n",
+                         __func__);
+               return -EINVAL;
+       }
+
+       return prm_ll_data->clear_mod_irqs(module, regs, wkst_mask);
+}
+
+/**
+ * omap_prm_vp_check_txdone - check voltage processor TX done status
+ *
+ * Checks if voltage processor transmission has been completed.
+ * Returns non-zero if a transmission has completed, 0 otherwise.
+ */
+u32 omap_prm_vp_check_txdone(u8 vp_id)
+{
+       if (!prm_ll_data->vp_check_txdone) {
+               WARN_ONCE(1, "prm: %s: no mapping function defined\n",
+                         __func__);
+               return 0;
+       }
+
+       return prm_ll_data->vp_check_txdone(vp_id);
+}
+
+/**
+ * omap_prm_vp_clear_txdone - clears voltage processor TX done status
+ *
+ * Clears the status bit for completed voltage processor transmission
+ * returned by prm_vp_check_txdone.
+ */
+void omap_prm_vp_clear_txdone(u8 vp_id)
+{
+       if (!prm_ll_data->vp_clear_txdone) {
+               WARN_ONCE(1, "prm: %s: no mapping function defined\n",
+                         __func__);
+               return;
+       }
+
+       prm_ll_data->vp_clear_txdone(vp_id);
+}
+
 /**
  * prm_register - register per-SoC low-level data with the PRM
  * @pld: low-level per-SoC OMAP PRM data & function pointers to register
@@ -578,78 +637,175 @@ int prm_unregister(struct prm_ll_data *pld)
        return 0;
 }
 
-static const struct of_device_id omap_prcm_dt_match_table[] = {
-       { .compatible = "ti,am3-prcm" },
-       { .compatible = "ti,am3-scrm" },
-       { .compatible = "ti,am4-prcm" },
-       { .compatible = "ti,am4-scrm" },
-       { .compatible = "ti,dm814-prcm" },
-       { .compatible = "ti,dm814-scrm" },
-       { .compatible = "ti,dm816-prcm" },
-       { .compatible = "ti,dm816-scrm" },
-       { .compatible = "ti,omap2-prcm" },
-       { .compatible = "ti,omap2-scrm" },
-       { .compatible = "ti,omap3-prm" },
-       { .compatible = "ti,omap3-cm" },
-       { .compatible = "ti,omap3-scrm" },
-       { .compatible = "ti,omap4-cm1" },
-       { .compatible = "ti,omap4-prm" },
-       { .compatible = "ti,omap4-cm2" },
-       { .compatible = "ti,omap4-scrm" },
-       { .compatible = "ti,omap5-prm" },
-       { .compatible = "ti,omap5-cm-core-aon" },
-       { .compatible = "ti,omap5-scrm" },
-       { .compatible = "ti,omap5-cm-core" },
-       { .compatible = "ti,dra7-prm" },
-       { .compatible = "ti,dra7-cm-core-aon" },
-       { .compatible = "ti,dra7-cm-core" },
-       { }
+#ifdef CONFIG_ARCH_OMAP2
+static struct omap_prcm_init_data omap2_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap2xxx_prm_init,
 };
+#endif
+
+#ifdef CONFIG_ARCH_OMAP3
+static struct omap_prcm_init_data omap3_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap3xxx_prm_init,
 
-static struct clk_hw_omap memmap_dummy_ck = {
-       .flags = MEMMAP_ADDRESSING,
+       /*
+        * IVA2 offset is a negative value, must offset the prm_base
+        * address by this to get it to positive
+        */
+       .offset = -OMAP3430_IVA2_MOD,
 };
+#endif
 
-static u32 prm_clk_readl(void __iomem *reg)
-{
-       return omap2_clk_readl(&memmap_dummy_ck, reg);
-}
+#if defined(CONFIG_SOC_AM33XX) || defined(CONFIG_SOC_TI81XX)
+static struct omap_prcm_init_data am3_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = am33xx_prm_init,
+};
+#endif
+
+#ifdef CONFIG_ARCH_OMAP4
+static struct omap_prcm_init_data omap4_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap44xx_prm_init,
+       .device_inst_offset = OMAP4430_PRM_DEVICE_INST,
+       .flags = PRM_HAS_IO_WAKEUP | PRM_HAS_VOLTAGE | PRM_IRQ_DEFAULT,
+};
+#endif
+
+#ifdef CONFIG_SOC_OMAP5
+static struct omap_prcm_init_data omap5_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap44xx_prm_init,
+       .device_inst_offset = OMAP54XX_PRM_DEVICE_INST,
+       .flags = PRM_HAS_IO_WAKEUP | PRM_HAS_VOLTAGE,
+};
+#endif
+
+#ifdef CONFIG_SOC_DRA7XX
+static struct omap_prcm_init_data dra7_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap44xx_prm_init,
+       .device_inst_offset = DRA7XX_PRM_DEVICE_INST,
+       .flags = PRM_HAS_IO_WAKEUP,
+};
+#endif
 
-static void prm_clk_writel(u32 val, void __iomem *reg)
-{
-       omap2_clk_writel(val, &memmap_dummy_ck, reg);
-}
+#ifdef CONFIG_SOC_AM43XX
+static struct omap_prcm_init_data am4_prm_data __initdata = {
+       .index = TI_CLKM_PRM,
+       .init = omap44xx_prm_init,
+       .device_inst_offset = AM43XX_PRM_DEVICE_INST,
+};
+#endif
 
-static struct ti_clk_ll_ops omap_clk_ll_ops = {
-       .clk_readl = prm_clk_readl,
-       .clk_writel = prm_clk_writel,
+#if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5)
+static struct omap_prcm_init_data scrm_data __initdata = {
+       .index = TI_CLKM_SCRM,
+};
+#endif
+
+static const struct of_device_id omap_prcm_dt_match_table[] __initconst = {
+#ifdef CONFIG_SOC_AM33XX
+       { .compatible = "ti,am3-prcm", .data = &am3_prm_data },
+#endif
+#ifdef CONFIG_SOC_AM43XX
+       { .compatible = "ti,am4-prcm", .data = &am4_prm_data },
+#endif
+#ifdef CONFIG_SOC_TI81XX
+       { .compatible = "ti,dm814-prcm", .data = &am3_prm_data },
+       { .compatible = "ti,dm816-prcm", .data = &am3_prm_data },
+#endif
+#ifdef CONFIG_ARCH_OMAP2
+       { .compatible = "ti,omap2-prcm", .data = &omap2_prm_data },
+#endif
+#ifdef CONFIG_ARCH_OMAP3
+       { .compatible = "ti,omap3-prm", .data = &omap3_prm_data },
+#endif
+#ifdef CONFIG_ARCH_OMAP4
+       { .compatible = "ti,omap4-prm", .data = &omap4_prm_data },
+       { .compatible = "ti,omap4-scrm", .data = &scrm_data },
+#endif
+#ifdef CONFIG_SOC_OMAP5
+       { .compatible = "ti,omap5-prm", .data = &omap5_prm_data },
+       { .compatible = "ti,omap5-scrm", .data = &scrm_data },
+#endif
+#ifdef CONFIG_SOC_DRA7XX
+       { .compatible = "ti,dra7-prm", .data = &dra7_prm_data },
+#endif
+       { }
 };
 
-int __init of_prcm_init(void)
+/**
+ * omap2_prm_base_init - initialize iomappings for the PRM driver
+ *
+ * Detects and initializes the iomappings for the PRM driver, based
+ * on the DT data. Returns 0 in success, negative error value
+ * otherwise.
+ */
+int __init omap2_prm_base_init(void)
 {
        struct device_node *np;
+       const struct of_device_id *match;
+       struct omap_prcm_init_data *data;
        void __iomem *mem;
-       int memmap_index = 0;
 
-       ti_clk_ll_ops = &omap_clk_ll_ops;
+       for_each_matching_node_and_match(np, omap_prcm_dt_match_table, &match) {
+               data = (struct omap_prcm_init_data *)match->data;
 
-       for_each_matching_node(np, omap_prcm_dt_match_table) {
                mem = of_iomap(np, 0);
-               clk_memmaps[memmap_index] = mem;
-               ti_dt_clk_init_provider(np, memmap_index);
-               memmap_index++;
+               if (!mem)
+                       return -ENOMEM;
+
+               if (data->index == TI_CLKM_PRM)
+                       prm_base = mem + data->offset;
+
+               data->mem = mem;
+
+               data->np = np;
+
+               if (data->init)
+                       data->init(data);
        }
 
        return 0;
 }
 
-void __init omap3_prcm_legacy_iomaps_init(void)
+int __init omap2_prcm_base_init(void)
 {
-       ti_clk_ll_ops = &omap_clk_ll_ops;
+       int ret;
 
-       clk_memmaps[TI_CLKM_CM] = cm_base + OMAP3430_IVA2_MOD;
-       clk_memmaps[TI_CLKM_PRM] = prm_base + OMAP3430_IVA2_MOD;
-       clk_memmaps[TI_CLKM_SCRM] = omap_ctrl_base_get();
+       ret = omap2_prm_base_init();
+       if (ret)
+               return ret;
+
+       return omap2_cm_base_init();
+}
+
+/**
+ * omap_prcm_init - low level init for the PRCM drivers
+ *
+ * Initializes the low level clock infrastructure for PRCM drivers.
+ * Returns 0 in success, negative error value in failure.
+ */
+int __init omap_prcm_init(void)
+{
+       struct device_node *np;
+       const struct of_device_id *match;
+       const struct omap_prcm_init_data *data;
+       int ret;
+
+       for_each_matching_node_and_match(np, omap_prcm_dt_match_table, &match) {
+               data = match->data;
+
+               ret = omap2_clk_provider_init(np, data->index, NULL, data->mem);
+               if (ret)
+                       return ret;
+       }
+
+       omap_cm_init();
+
+       return 0;
 }
 
 static int __init prm_late_init(void)
index 8adf7b1a1dce68cd9139854e2f4785e1511e8c43..c4859c4d364692b575199f0287b4ee4751ccdee2 100644 (file)
@@ -47,22 +47,14 @@ void omap_prm_base_init(void)
 
 s32 omap4_prmst_get_prm_dev_inst(void)
 {
-       if (prm_dev_inst != PRM_INSTANCE_UNKNOWN)
-               return prm_dev_inst;
-
-       /* This cannot be done way early at boot.. as things are not setup */
-       if (cpu_is_omap44xx())
-               prm_dev_inst = OMAP4430_PRM_DEVICE_INST;
-       else if (soc_is_omap54xx())
-               prm_dev_inst = OMAP54XX_PRM_DEVICE_INST;
-       else if (soc_is_dra7xx())
-               prm_dev_inst = DRA7XX_PRM_DEVICE_INST;
-       else if (soc_is_am43xx())
-               prm_dev_inst = AM43XX_PRM_DEVICE_INST;
-
        return prm_dev_inst;
 }
 
+void omap4_prminst_set_prm_dev_inst(s32 dev_inst)
+{
+       prm_dev_inst = dev_inst;
+}
+
 /* Read a register in a PRM instance */
 u32 omap4_prminst_read_inst_reg(u8 part, s16 inst, u16 idx)
 {
index fb1c9d7a2f9defe6b9255cbf193cae32c2eaef14..0c03d0731d7fb32b69fcb0d56e65c420b6964781 100644 (file)
@@ -14,6 +14,7 @@
 
 #define PRM_INSTANCE_UNKNOWN   -1
 extern s32 omap4_prmst_get_prm_dev_inst(void);
+void omap4_prminst_set_prm_dev_inst(s32 dev_inst);
 
 /*
  * In an ideal world, we would not export these low-level functions,
index b84a0122d823a88b8655b0a4c761a460e3cf4cbc..ad1bb9431e941c6fd084fa5d8f0867f24667b72c 100644 (file)
@@ -333,11 +333,9 @@ ENDPROC(omap4_cpu_resume)
 
 #endif /* defined(CONFIG_SMP) && defined(CONFIG_PM) */
 
-#ifndef CONFIG_OMAP4_ERRATA_I688
 ENTRY(omap_bus_sync)
        ret     lr
 ENDPROC(omap_bus_sync)
-#endif
 
 ENTRY(omap_do_wfi)
        stmfd   sp!, {lr}
index 0fdf7080e4a641002796a0f9fe34b76c363b95c3..7e0829682bd02cba1b1897d837c8cd5960eca489 100644 (file)
 
 struct voltagedomain;
 
-/*
- * Voltage Processor (VP) identifiers
- */
-#define OMAP3_VP_VDD_MPU_ID 0
-#define OMAP3_VP_VDD_CORE_ID 1
-#define OMAP4_VP_VDD_CORE_ID 0
-#define OMAP4_VP_VDD_IVA_ID 1
-#define OMAP4_VP_VDD_MPU_ID 2
-
 /* XXX document */
 #define VP_IDLE_TIMEOUT                200
 #define VP_TRANXDONE_TIMEOUT   300
index 1914e026245e0464f77d9bd49d6c4aba29fefb3a..b0590fe6ab01dc3a3f653fb8e9d22f3a333ea1cb 100644 (file)
@@ -28,8 +28,8 @@
 #include "prm2xxx_3xxx.h"
 
 static const struct omap_vp_ops omap3_vp_ops = {
-       .check_txdone = omap3_prm_vp_check_txdone,
-       .clear_txdone = omap3_prm_vp_clear_txdone,
+       .check_txdone = omap_prm_vp_check_txdone,
+       .clear_txdone = omap_prm_vp_clear_txdone,
 };
 
 /*
index e62f6b018beb2379ad5dde520cfa84fe6e39e454..2448bb9a871608e102033dd76a9796186b339ea1 100644 (file)
@@ -28,8 +28,8 @@
 #include "vp.h"
 
 static const struct omap_vp_ops omap4_vp_ops = {
-       .check_txdone = omap4_prm_vp_check_txdone,
-       .clear_txdone = omap4_prm_vp_clear_txdone,
+       .check_txdone = omap_prm_vp_check_txdone,
+       .clear_txdone = omap_prm_vp_clear_txdone,
 };
 
 /*
index 0958b6981773c19527973916c65b3e703c5633f8..e98d15eaa7994c7349d1db8df4dd19f684b85ba6 100644 (file)
@@ -142,7 +142,7 @@ static int __init weim_parse_dt(struct platform_device *pdev,
                                                           &pdev->dev);
        const struct imx_weim_devtype *devtype = of_id->data;
        struct device_node *child;
-       int ret;
+       int ret, have_child = 0;
 
        if (devtype == &imx50_weim_devtype) {
                ret = imx_weim_gpr_setup(pdev);
@@ -155,14 +155,15 @@ static int __init weim_parse_dt(struct platform_device *pdev,
                        continue;
 
                ret = weim_timing_setup(child, base, devtype);
-               if (ret) {
-                       dev_err(&pdev->dev, "%s set timing failed.\n",
+               if (ret)
+                       dev_warn(&pdev->dev, "%s set timing failed.\n",
                                child->full_name);
-                       return ret;
-               }
+               else
+                       have_child = 1;
        }
 
-       ret = of_platform_populate(pdev->dev.of_node,
+       if (have_child)
+               ret = of_platform_populate(pdev->dev.of_node,
                                   of_default_bus_match_table,
                                   NULL, &pdev->dev);
        if (ret)
index 723ec06ad2c8209d211fa58e6377625882d74754..9f185694875850427e9613aaf725859c7efbfc63 100644 (file)
@@ -16,6 +16,7 @@
  *
  */
 
+#include <linux/io.h>
 #include <linux/module.h>
 #include <linux/platform_device.h>
 #include <linux/err.h>
@@ -23,6 +24,9 @@
 #include <linux/of.h>
 #include <linux/of_platform.h>
 
+#define OCP2SCP_TIMING 0x18
+#define SYNC2_MASK 0xf
+
 static int ocp2scp_remove_devices(struct device *dev, void *c)
 {
        struct platform_device *pdev = to_platform_device(dev);
@@ -35,6 +39,9 @@ static int ocp2scp_remove_devices(struct device *dev, void *c)
 static int omap_ocp2scp_probe(struct platform_device *pdev)
 {
        int ret;
+       u32 reg;
+       void __iomem *regs;
+       struct resource *res;
        struct device_node *np = pdev->dev.of_node;
 
        if (np) {
@@ -47,6 +54,32 @@ static int omap_ocp2scp_probe(struct platform_device *pdev)
        }
 
        pm_runtime_enable(&pdev->dev);
+       /*
+        * As per AM572x TRM: http://www.ti.com/lit/ug/spruhz6/spruhz6.pdf
+        * under section 26.3.2.2, table 26-26 OCP2SCP TIMING Caution;
+        * As per OMAP4430 TRM: http://www.ti.com/lit/ug/swpu231ap/swpu231ap.pdf
+        * under section 23.12.6.2.2 , Table 23-1213 OCP2SCP TIMING Caution;
+        * As per OMAP4460 TRM: http://www.ti.com/lit/ug/swpu235ab/swpu235ab.pdf
+        * under section 23.12.6.2.2, Table 23-1213 OCP2SCP TIMING Caution;
+        * As per OMAP543x TRM http://www.ti.com/lit/pdf/swpu249
+        * under section 27.3.2.2, Table 27-27 OCP2SCP TIMING Caution;
+        *
+        * Read path of OCP2SCP is not working properly due to low reset value
+        * of SYNC2 parameter in OCP2SCP. Suggested reset value is 0x6 or more.
+        */
+       if (!of_device_is_compatible(np, "ti,am437x-ocp2scp")) {
+               res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
+               regs = devm_ioremap_resource(&pdev->dev, res);
+               if (IS_ERR(regs))
+                       goto err0;
+
+               pm_runtime_get_sync(&pdev->dev);
+               reg = readl_relaxed(regs + OCP2SCP_TIMING);
+               reg &= ~(SYNC2_MASK);
+               reg |= 0x6;
+               writel_relaxed(reg, regs + OCP2SCP_TIMING);
+               pm_runtime_put_sync(&pdev->dev);
+       }
 
        return 0;
 
@@ -67,6 +100,7 @@ static int omap_ocp2scp_remove(struct platform_device *pdev)
 #ifdef CONFIG_OF
 static const struct of_device_id omap_ocp2scp_id_table[] = {
        { .compatible = "ti,omap-ocp2scp" },
+       { .compatible = "ti,am437x-ocp2scp" },
        {}
 };
 MODULE_DEVICE_TABLE(of, omap_ocp2scp_id_table);
index 72d97279eae1b02f0d55341dcb4c19a28190e2be..49baf38315463d9e77cd6b34e3fdbd8cc21cc832 100644 (file)
@@ -203,7 +203,7 @@ static void __init of_dra7_apll_setup(struct device_node *node)
        ad->control_reg = ti_clk_get_reg_addr(node, 0);
        ad->idlest_reg = ti_clk_get_reg_addr(node, 1);
 
-       if (!ad->control_reg || !ad->idlest_reg)
+       if (IS_ERR(ad->control_reg) || IS_ERR(ad->idlest_reg))
                goto cleanup;
 
        ad->idlest_mask = 0x1;
@@ -384,7 +384,8 @@ static void __init of_omap2_apll_setup(struct device_node *node)
        ad->autoidle_reg = ti_clk_get_reg_addr(node, 1);
        ad->idlest_reg = ti_clk_get_reg_addr(node, 2);
 
-       if (!ad->control_reg || !ad->autoidle_reg || !ad->idlest_reg)
+       if (IS_ERR(ad->control_reg) || IS_ERR(ad->autoidle_reg) ||
+           IS_ERR(ad->idlest_reg))
                goto cleanup;
 
        clk = clk_register(NULL, &clk_hw->hw);
index 8912ff80af347c3d79a3939394fdedb25c14c7ac..e75c64c9e81c1d1c3dae2b9779e3538426a66e85 100644 (file)
@@ -119,7 +119,7 @@ int __init of_ti_clk_autoidle_setup(struct device_node *node)
        clk->name = node->name;
        clk->reg = ti_clk_get_reg_addr(node, 0);
 
-       if (!clk->reg) {
+       if (IS_ERR(clk->reg)) {
                kfree(clk);
                return -EINVAL;
        }
index e22b95646e09a8357e5adb3786f726c8e6baab10..0ebe5c51062b9ee2c2aa8e3fbe5dd84fcb14f753 100644 (file)
@@ -103,7 +103,8 @@ int __init ti_clk_retry_init(struct device_node *node, struct clk_hw *hw,
  * @index: register index from the clock node
  *
  * Builds clock register address from device tree information. This
- * is a struct of type clk_omap_reg.
+ * is a struct of type clk_omap_reg. Returns a pointer to the register
+ * address, or a pointer error value in failure.
  */
 void __iomem *ti_clk_get_reg_addr(struct device_node *node, int index)
 {
@@ -121,14 +122,14 @@ void __iomem *ti_clk_get_reg_addr(struct device_node *node, int index)
 
        if (i == CLK_MAX_MEMMAPS) {
                pr_err("clk-provider not found for %s!\n", node->name);
-               return NULL;
+               return ERR_PTR(-ENOENT);
        }
 
        reg->index = i;
 
        if (of_property_read_u32_index(node, "reg", index, &val)) {
                pr_err("%s must have reg[%d]!\n", node->name, index);
-               return NULL;
+               return ERR_PTR(-EINVAL);
        }
 
        reg->offset = val;
index 6211893c0980665749aa2c08577f9f3c17da4a78..ff5f117950a933b354c3bf5ba339e3e1a5b2dcd3 100644 (file)
@@ -530,8 +530,8 @@ static int __init ti_clk_divider_populate(struct device_node *node,
        u32 val;
 
        *reg = ti_clk_get_reg_addr(node, 0);
-       if (!*reg)
-               return -EINVAL;
+       if (IS_ERR(*reg))
+               return PTR_ERR(*reg);
 
        if (!of_property_read_u32(node, "ti,bit-shift", &val))
                *shift = val;
index 81dc4698dc41740e77e82411b00c67ae9aa148ba..11478a501c3074c53071bf9afb206b375fbda14c 100644 (file)
@@ -390,18 +390,18 @@ static void __init of_ti_dpll_setup(struct device_node *node,
 #endif
        } else {
                dd->idlest_reg = ti_clk_get_reg_addr(node, 1);
-               if (!dd->idlest_reg)
+               if (IS_ERR(dd->idlest_reg))
                        goto cleanup;
 
                dd->mult_div1_reg = ti_clk_get_reg_addr(node, 2);
        }
 
-       if (!dd->control_reg || !dd->mult_div1_reg)
+       if (IS_ERR(dd->control_reg) || IS_ERR(dd->mult_div1_reg))
                goto cleanup;
 
        if (dd->autoidle_mask) {
                dd->autoidle_reg = ti_clk_get_reg_addr(node, 3);
-               if (!dd->autoidle_reg)
+               if (IS_ERR(dd->autoidle_reg))
                        goto cleanup;
        }
 
index d493307b73f42b0bdef4c36544e5146ce00b977e..0c6fdfcd5f93a911178e334a87f371576bd18939 100644 (file)
@@ -225,7 +225,7 @@ static void __init _of_ti_gate_clk_setup(struct device_node *node,
 
        if (ops != &omap_gate_clkdm_clk_ops) {
                reg = ti_clk_get_reg_addr(node, 0);
-               if (!reg)
+               if (IS_ERR(reg))
                        return;
 
                if (!of_property_read_u32(node, "ti,bit-shift", &val))
@@ -264,7 +264,7 @@ _of_ti_composite_gate_clk_setup(struct device_node *node,
                return;
 
        gate->enable_reg = ti_clk_get_reg_addr(node, 0);
-       if (!gate->enable_reg)
+       if (IS_ERR(gate->enable_reg))
                goto cleanup;
 
        of_property_read_u32(node, "ti,bit-shift", &val);
index 265d91f071c5e34554cc71c474278997917a7a6f..c76230d8dd0464a073097cb70c4303cdf0e06056 100644 (file)
@@ -111,7 +111,7 @@ static void __init _of_ti_interface_clk_setup(struct device_node *node,
        u32 val;
 
        reg = ti_clk_get_reg_addr(node, 0);
-       if (!reg)
+       if (IS_ERR(reg))
                return;
 
        if (!of_property_read_u32(node, "ti,bit-shift", &val))
index 728e253606bce51a9435e6915ee1a445dcfff606..5cdeed538b08a2eec168de48a94399c11af33472 100644 (file)
@@ -210,7 +210,7 @@ static void of_mux_clk_setup(struct device_node *node)
 
        reg = ti_clk_get_reg_addr(node, 0);
 
-       if (!reg)
+       if (IS_ERR(reg))
                goto cleanup;
 
        of_property_read_u32(node, "ti,bit-shift", &shift);
@@ -283,7 +283,7 @@ static void __init of_ti_composite_mux_clk_setup(struct device_node *node)
 
        mux->reg = ti_clk_get_reg_addr(node, 0);
 
-       if (!mux->reg)
+       if (IS_ERR(mux->reg))
                goto cleanup;
 
        if (!of_property_read_u32(node, "ti,bit-shift", &val))
index 42965d2476bbb03cb7d7caf66980b6caa360a16c..9176c76eb164a9db636593668f5069a0324792d3 100644 (file)
@@ -37,6 +37,7 @@ obj-$(CONFIG_TB10X_IRQC)              += irq-tb10x.o
 obj-$(CONFIG_XTENSA)                   += irq-xtensa-pic.o
 obj-$(CONFIG_XTENSA_MX)                        += irq-xtensa-mx.o
 obj-$(CONFIG_IRQ_CROSSBAR)             += irq-crossbar.o
+obj-$(CONFIG_SOC_VF610)                        += irq-vf610-mscm-ir.o
 obj-$(CONFIG_BCM7120_L2_IRQ)           += irq-bcm7120-l2.o
 obj-$(CONFIG_BRCMSTB_L2_IRQ)           += irq-brcmstb-l2.o
 obj-$(CONFIG_KEYSTONE_IRQ)             += irq-keystone.o
diff --git a/drivers/irqchip/irq-vf610-mscm-ir.c b/drivers/irqchip/irq-vf610-mscm-ir.c
new file mode 100644 (file)
index 0000000..9521057
--- /dev/null
@@ -0,0 +1,212 @@
+/*
+ * Copyright (C) 2014-2015 Toradex AG
+ * Author: Stefan Agner <stefan@agner.ch>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ *
+ * IRQ chip driver for MSCM interrupt router available on Vybrid SoC's.
+ * The interrupt router is between the CPU's interrupt controller and the
+ * peripheral. The router allows to route the peripheral interrupts to
+ * one of the two available CPU's on Vybrid VF6xx SoC's (Cortex-A5 or
+ * Cortex-M4). The router will be configured transparently on a IRQ
+ * request.
+ *
+ * o All peripheral interrupts of the Vybrid SoC can be routed to
+ *   CPU 0, CPU 1 or both. The routing is useful for dual-core
+ *   variants of Vybrid SoC such as VF6xx. This driver routes the
+ *   requested interrupt to the CPU currently running on.
+ *
+ * o It is required to setup the interrupt router even on single-core
+ *   variants of Vybrid.
+ */
+
+#include <linux/cpu_pm.h>
+#include <linux/io.h>
+#include <linux/irq.h>
+#include <linux/irqdomain.h>
+#include <linux/mfd/syscon.h>
+#include <dt-bindings/interrupt-controller/arm-gic.h>
+#include <linux/of.h>
+#include <linux/of_address.h>
+#include <linux/slab.h>
+#include <linux/regmap.h>
+
+#include "irqchip.h"
+
+#define MSCM_CPxNUM            0x4
+
+#define MSCM_IRSPRC(n)         (0x80 + 2 * (n))
+#define MSCM_IRSPRC_CPEN_MASK  0x3
+
+#define MSCM_IRSPRC_NUM                112
+
+struct vf610_mscm_ir_chip_data {
+       void __iomem *mscm_ir_base;
+       u16 cpu_mask;
+       u16 saved_irsprc[MSCM_IRSPRC_NUM];
+};
+
+static struct vf610_mscm_ir_chip_data *mscm_ir_data;
+
+static inline void vf610_mscm_ir_save(struct vf610_mscm_ir_chip_data *data)
+{
+       int i;
+
+       for (i = 0; i < MSCM_IRSPRC_NUM; i++)
+               data->saved_irsprc[i] = readw_relaxed(data->mscm_ir_base + MSCM_IRSPRC(i));
+}
+
+static inline void vf610_mscm_ir_restore(struct vf610_mscm_ir_chip_data *data)
+{
+       int i;
+
+       for (i = 0; i < MSCM_IRSPRC_NUM; i++)
+               writew_relaxed(data->saved_irsprc[i], data->mscm_ir_base + MSCM_IRSPRC(i));
+}
+
+static int vf610_mscm_ir_notifier(struct notifier_block *self,
+                                 unsigned long cmd, void *v)
+{
+       switch (cmd) {
+       case CPU_CLUSTER_PM_ENTER:
+               vf610_mscm_ir_save(mscm_ir_data);
+               break;
+       case CPU_CLUSTER_PM_ENTER_FAILED:
+       case CPU_CLUSTER_PM_EXIT:
+               vf610_mscm_ir_restore(mscm_ir_data);
+               break;
+       }
+
+       return NOTIFY_OK;
+}
+
+static struct notifier_block mscm_ir_notifier_block = {
+       .notifier_call = vf610_mscm_ir_notifier,
+};
+
+static void vf610_mscm_ir_enable(struct irq_data *data)
+{
+       irq_hw_number_t hwirq = data->hwirq;
+       struct vf610_mscm_ir_chip_data *chip_data = data->chip_data;
+       u16 irsprc;
+
+       irsprc = readw_relaxed(chip_data->mscm_ir_base + MSCM_IRSPRC(hwirq));
+       irsprc &= MSCM_IRSPRC_CPEN_MASK;
+
+       WARN_ON(irsprc & ~chip_data->cpu_mask);
+
+       writew_relaxed(chip_data->cpu_mask,
+                      chip_data->mscm_ir_base + MSCM_IRSPRC(hwirq));
+
+       irq_chip_unmask_parent(data);
+}
+
+static void vf610_mscm_ir_disable(struct irq_data *data)
+{
+       irq_hw_number_t hwirq = data->hwirq;
+       struct vf610_mscm_ir_chip_data *chip_data = data->chip_data;
+
+       writew_relaxed(0x0, chip_data->mscm_ir_base + MSCM_IRSPRC(hwirq));
+
+       irq_chip_mask_parent(data);
+}
+
+static struct irq_chip vf610_mscm_ir_irq_chip = {
+       .name                   = "mscm-ir",
+       .irq_mask               = irq_chip_mask_parent,
+       .irq_unmask             = irq_chip_unmask_parent,
+       .irq_eoi                = irq_chip_eoi_parent,
+       .irq_enable             = vf610_mscm_ir_enable,
+       .irq_disable            = vf610_mscm_ir_disable,
+       .irq_retrigger          = irq_chip_retrigger_hierarchy,
+       .irq_set_affinity       = irq_chip_set_affinity_parent,
+};
+
+static int vf610_mscm_ir_domain_alloc(struct irq_domain *domain, unsigned int virq,
+                                     unsigned int nr_irqs, void *arg)
+{
+       int i;
+       irq_hw_number_t hwirq;
+       struct of_phandle_args *irq_data = arg;
+       struct of_phandle_args gic_data;
+
+       if (irq_data->args_count != 2)
+               return -EINVAL;
+
+       hwirq = irq_data->args[0];
+       for (i = 0; i < nr_irqs; i++)
+               irq_domain_set_hwirq_and_chip(domain, virq + i, hwirq + i,
+                                             &vf610_mscm_ir_irq_chip,
+                                             domain->host_data);
+
+       gic_data.np = domain->parent->of_node;
+       gic_data.args_count = 3;
+       gic_data.args[0] = GIC_SPI;
+       gic_data.args[1] = irq_data->args[0];
+       gic_data.args[2] = irq_data->args[1];
+       return irq_domain_alloc_irqs_parent(domain, virq, nr_irqs, &gic_data);
+}
+
+static const struct irq_domain_ops mscm_irq_domain_ops = {
+       .xlate = irq_domain_xlate_twocell,
+       .alloc = vf610_mscm_ir_domain_alloc,
+       .free = irq_domain_free_irqs_common,
+};
+
+static int __init vf610_mscm_ir_of_init(struct device_node *node,
+                              struct device_node *parent)
+{
+       struct irq_domain *domain, *domain_parent;
+       struct regmap *mscm_cp_regmap;
+       int ret, cpuid;
+
+       domain_parent = irq_find_host(parent);
+       if (!domain_parent) {
+               pr_err("vf610_mscm_ir: interrupt-parent not found\n");
+               return -EINVAL;
+       }
+
+       mscm_ir_data = kzalloc(sizeof(*mscm_ir_data), GFP_KERNEL);
+       if (!mscm_ir_data)
+               return -ENOMEM;
+
+       mscm_ir_data->mscm_ir_base = of_io_request_and_map(node, 0, "mscm-ir");
+
+       if (!mscm_ir_data->mscm_ir_base) {
+               pr_err("vf610_mscm_ir: unable to map mscm register\n");
+               ret = -ENOMEM;
+               goto out_free;
+       }
+
+       mscm_cp_regmap = syscon_regmap_lookup_by_phandle(node, "fsl,cpucfg");
+       if (IS_ERR(mscm_cp_regmap)) {
+               ret = PTR_ERR(mscm_cp_regmap);
+               pr_err("vf610_mscm_ir: regmap lookup for cpucfg failed\n");
+               goto out_unmap;
+       }
+
+       regmap_read(mscm_cp_regmap, MSCM_CPxNUM, &cpuid);
+       mscm_ir_data->cpu_mask = 0x1 << cpuid;
+
+       domain = irq_domain_add_hierarchy(domain_parent, 0,
+                                         MSCM_IRSPRC_NUM, node,
+                                         &mscm_irq_domain_ops, mscm_ir_data);
+       if (!domain) {
+               ret = -ENOMEM;
+               goto out_unmap;
+       }
+
+       cpu_pm_register_notifier(&mscm_ir_notifier_block);
+
+       return 0;
+
+out_unmap:
+       iounmap(mscm_ir_data->mscm_ir_base);
+out_free:
+       kfree(mscm_ir_data);
+       return ret;
+}
+IRQCHIP_DECLARE(vf610_mscm_ir, "fsl,vf610-mscm-ir", vf610_mscm_ir_of_init);
index b690cdba163b85b7c81a60cb1ac0cea8253dcc5c..8780868458a09e9b35d7fdee97f732663da0a61c 100644 (file)
 #define IMX6QDL_PLL6_BYPASS                    235
 #define IMX6QDL_PLL7_BYPASS                    236
 #define IMX6QDL_CLK_GPT_3M                     237
-#define IMX6QDL_CLK_END                                238
+#define IMX6QDL_CLK_VIDEO_27M                  238
+#define IMX6QDL_CLK_MIPI_CORE_CFG              239
+#define IMX6QDL_CLK_MIPI_IPG                   240
+#define IMX6QDL_CLK_END                                241
 
 #endif /* __DT_BINDINGS_CLOCK_IMX6QDL_H */
index 67844003493de5936809dc1acac72cd88b5bc521..79b76e13d90425db1ed1320b1bfe9f11aecfd767 100644 (file)
@@ -215,14 +215,14 @@ struct ti_dt_clk {
                .node_name = name,      \
        }
 
-/* Maximum number of clock memmaps */
-#define CLK_MAX_MEMMAPS                        4
-
 /* Static memmap indices */
 enum {
        TI_CLKM_CM = 0,
+       TI_CLKM_CM2,
        TI_CLKM_PRM,
        TI_CLKM_SCRM,
+       TI_CLKM_CTRL,
+       CLK_MAX_MEMMAPS
 };
 
 typedef void (*ti_of_clk_init_cb_t)(struct clk_hw *, struct device_node *);
index c877cad61a132586086c6c51ef327a2877d393d2..d16f4c82c568f13ad6e025d28951cb8978e4c3e2 100644 (file)
 #define IMX6Q_GPR3_LVDS0_MUX_CTL_IPU1_DI1      (0x1 << 6)
 #define IMX6Q_GPR3_LVDS0_MUX_CTL_IPU2_DI0      (0x2 << 6)
 #define IMX6Q_GPR3_LVDS0_MUX_CTL_IPU2_DI1      (0x3 << 6)
+#define IMX6Q_GPR3_MIPI_MUX_CTL_SHIFT          4
 #define IMX6Q_GPR3_MIPI_MUX_CTL_MASK           (0x3 << 4)
 #define IMX6Q_GPR3_MIPI_MUX_CTL_IPU1_DI0       (0x0 << 4)
 #define IMX6Q_GPR3_MIPI_MUX_CTL_IPU1_DI1       (0x1 << 4)