diff options
author | Olof Johansson <olof@lixom.net> | 2012-04-15 18:09:29 (GMT) |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2012-04-15 18:09:29 (GMT) |
commit | 244cf2533ca91d7f6a4ed0a7e81df4bf93246c91 (patch) | |
tree | 4be320cfd8cabafe10d2177d8e2d70178300f16e /arch/arm/mach-omap2 | |
parent | 0034102808e0dbbf3a2394b82b1bb40b5778de9e (diff) | |
parent | b3431f5ba402a98a89b78a9408b4972d8870df4d (diff) | |
download | linux-fsl-qoriq-244cf2533ca91d7f6a4ed0a7e81df4bf93246c91.tar.xz |
Merge branch 'omap/dt-missed-3.4' into next/dt
* omap/dt-missed-3.4:
arm/dts: OMAP3: Add mmc controller nodes and board data
arm/dts: OMAP4: Add mmc controller nodes and board data
arm/dts: twl: Pass regulator data from dt
arm/dts: omap4-sdp: Add ks8851 ethernet SPI device
arm/dts: OMAP3: Add SPI controller nodes
arm/dts: OMAP4: Add SPI controller nodes
arm/dts: OMAP3: Add gpio nodes
arm/dts: OMAP4: Add gpio nodes
ARM: OMAP2+: board-generic: Remove i2c static init
arm/dts: omap3-beagle: Add twl4030 and i2c EEPROM
arm/dts: omap4-sdp: Add twl6030, i2c3 and i2c4 devices
arm/dts: omap4-panda: Add twl6030 and i2c EEPROM
arm/dts: twl4030: Add DTS file for twl4030 PM + Audio IC
arm/dts: twl6030: Add DTS file for twl6030 PMIC
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r-- | arch/arm/mach-omap2/board-generic.c | 37 | ||||
-rw-r--r-- | arch/arm/mach-omap2/devices.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-omap2/gpio.c | 8 |
3 files changed, 11 insertions, 38 deletions
diff --git a/arch/arm/mach-omap2/board-generic.c b/arch/arm/mach-omap2/board-generic.c index 74e1687..7302ba7 100644 --- a/arch/arm/mach-omap2/board-generic.c +++ b/arch/arm/mach-omap2/board-generic.c @@ -15,7 +15,6 @@ #include <linux/of_irq.h> #include <linux/of_platform.h> #include <linux/irqdomain.h> -#include <linux/i2c/twl.h> #include <mach/hardware.h> #include <asm/hardware/gic.h> @@ -95,22 +94,6 @@ MACHINE_END #endif #ifdef CONFIG_ARCH_OMAP3 -static struct twl4030_platform_data beagle_twldata = { - .irq_base = TWL4030_IRQ_BASE, - .irq_end = TWL4030_IRQ_END, -}; - -static void __init omap3_i2c_init(void) -{ - omap3_pmic_init("twl4030", &beagle_twldata); -} - -static void __init omap3_init(void) -{ - omap3_i2c_init(); - omap_generic_init(); -} - static const char *omap3_boards_compat[] __initdata = { "ti,omap3", NULL, @@ -122,7 +105,7 @@ DT_MACHINE_START(OMAP3_DT, "Generic OMAP3 (Flattened Device Tree)") .init_early = omap3430_init_early, .init_irq = omap_init_irq, .handle_irq = omap3_intc_handle_irq, - .init_machine = omap3_init, + .init_machine = omap_generic_init, .timer = &omap3_timer, .dt_compat = omap3_boards_compat, .restart = omap_prcm_restart, @@ -130,22 +113,6 @@ MACHINE_END #endif #ifdef CONFIG_ARCH_OMAP4 -static struct twl4030_platform_data sdp4430_twldata = { - .irq_base = TWL6030_IRQ_BASE, - .irq_end = TWL6030_IRQ_END, -}; - -static void __init omap4_i2c_init(void) -{ - omap4_pmic_init("twl6030", &sdp4430_twldata); -} - -static void __init omap4_init(void) -{ - omap4_i2c_init(); - omap_generic_init(); -} - static const char *omap4_boards_compat[] __initdata = { "ti,omap4", NULL, @@ -157,7 +124,7 @@ DT_MACHINE_START(OMAP4_DT, "Generic OMAP4 (Flattened Device Tree)") .init_early = omap4430_init_early, .init_irq = omap_init_irq, .handle_irq = gic_handle_irq, - .init_machine = omap4_init, + .init_machine = omap_generic_init, .timer = &omap4_timer, .dt_compat = omap4_boards_compat, .restart = omap_prcm_restart, diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c index e433603..98cab3a 100644 --- a/arch/arm/mach-omap2/devices.c +++ b/arch/arm/mach-omap2/devices.c @@ -705,7 +705,9 @@ static int __init omap2_init_devices(void) omap_init_dmic(); omap_init_camera(); omap_init_mbox(); - omap_init_mcspi(); + /* If dtb is there, the devices will be created dynamically */ + if (!of_have_populated_dt()) + omap_init_mcspi(); omap_init_pmu(); omap_hdq_init(); omap_init_sti(); diff --git a/arch/arm/mach-omap2/gpio.c b/arch/arm/mach-omap2/gpio.c index 2f994e5..18f9c7b 100644 --- a/arch/arm/mach-omap2/gpio.c +++ b/arch/arm/mach-omap2/gpio.c @@ -20,6 +20,7 @@ #include <linux/err.h> #include <linux/slab.h> #include <linux/interrupt.h> +#include <linux/of.h> #include <plat/omap_hwmod.h> #include <plat/omap_device.h> @@ -146,7 +147,10 @@ static int __init omap2_gpio_dev_init(struct omap_hwmod *oh, void *unused) */ static int __init omap2_gpio_init(void) { - return omap_hwmod_for_each_by_class("gpio", omap2_gpio_dev_init, - NULL); + /* If dtb is there, the devices will be created dynamically */ + if (of_have_populated_dt()) + return -ENODEV; + + return omap_hwmod_for_each_by_class("gpio", omap2_gpio_dev_init, NULL); } postcore_initcall(omap2_gpio_init); |