diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-01 23:31:25 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-11-01 23:31:25 -0400 |
commit | 16ee792e45cf0c97ce061fce03c36cab5551ec72 (patch) | |
tree | dc68af705fbac4b5d71325aa972730199bb187dd /arch/arm/mach-imx/mach-mx31moboard.c | |
parent | f906fb1d70e016726fccfb0d978c5d425503db9d (diff) | |
parent | efa62e1355f0495f37f1296754b8880947c8da72 (diff) |
Merge branch 'next/devel' of git://git.linaro.org/people/arnd/arm-soc
* 'next/devel' of git://git.linaro.org/people/arnd/arm-soc: (50 commits)
ARM: tegra: update defconfig
arm/tegra: Harmony: Configure PMC for low-level interrupts
arm/tegra: device tree support for ventana board
arm/tegra: add support for ventana pinmuxing
arm/tegra: prepare Seaboard pinmux code for derived boards
arm/tegra: pinmux: ioremap registers
gpio/tegra: Convert to a platform device
arm/tegra: Convert pinmux driver to a platform device
arm/dt: Tegra: Add pinmux node to tegra20.dtsi
arm/tegra: Prep boards for gpio/pinmux conversion to pdevs
ARM: mx5: fix clock usage for suspend
ARM i.MX entry-macro.S: remove now unused code
ARM i.MX boards: use CONFIG_MULTI_IRQ_HANDLER
ARM i.MX tzic: add handle_irq function
ARM i.MX avic: add handle_irq function
ARM: mx25: Add the missing IIM base definition
ARM i.MX avic: convert to use generic irq chip
mx31moboard: Add poweroff support
ARM: mach-qong: Add watchdog support
ARM: davinci: AM18x: Add wl1271/wlan support
...
Fix up conflicts in:
arch/arm/mach-at91/at91sam9g45.c
arch/arm/mach-mx5/devices-imx53.h
arch/arm/plat-mxc/include/mach/memory.h
Diffstat (limited to 'arch/arm/mach-imx/mach-mx31moboard.c')
-rw-r--r-- | arch/arm/mach-imx/mach-mx31moboard.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/arch/arm/mach-imx/mach-mx31moboard.c b/arch/arm/mach-imx/mach-mx31moboard.c index 1d01ef28f25d..fff7791b7e7c 100644 --- a/arch/arm/mach-imx/mach-mx31moboard.c +++ b/arch/arm/mach-imx/mach-mx31moboard.c | |||
@@ -28,6 +28,9 @@ | |||
28 | #include <linux/spi/spi.h> | 28 | #include <linux/spi/spi.h> |
29 | #include <linux/types.h> | 29 | #include <linux/types.h> |
30 | #include <linux/memblock.h> | 30 | #include <linux/memblock.h> |
31 | #include <linux/clk.h> | ||
32 | #include <linux/io.h> | ||
33 | #include <linux/err.h> | ||
31 | 34 | ||
32 | #include <linux/usb/otg.h> | 35 | #include <linux/usb/otg.h> |
33 | #include <linux/usb/ulpi.h> | 36 | #include <linux/usb/ulpi.h> |
@@ -490,6 +493,18 @@ err: | |||
490 | 493 | ||
491 | } | 494 | } |
492 | 495 | ||
496 | static void mx31moboard_poweroff(void) | ||
497 | { | ||
498 | struct clk *clk = clk_get_sys("imx2-wdt.0", NULL); | ||
499 | |||
500 | if (!IS_ERR(clk)) | ||
501 | clk_enable(clk); | ||
502 | |||
503 | mxc_iomux_mode(MX31_PIN_WATCHDOG_RST__WATCHDOG_RST); | ||
504 | |||
505 | __raw_writew(1 << 6 | 1 << 2, MX31_IO_ADDRESS(MX31_WDOG_BASE_ADDR)); | ||
506 | } | ||
507 | |||
493 | static int mx31moboard_baseboard; | 508 | static int mx31moboard_baseboard; |
494 | core_param(mx31moboard_baseboard, mx31moboard_baseboard, int, 0444); | 509 | core_param(mx31moboard_baseboard, mx31moboard_baseboard, int, 0444); |
495 | 510 | ||
@@ -528,6 +543,8 @@ static void __init mx31moboard_init(void) | |||
528 | 543 | ||
529 | moboard_usbh2_init(); | 544 | moboard_usbh2_init(); |
530 | 545 | ||
546 | pm_power_off = mx31moboard_poweroff; | ||
547 | |||
531 | switch (mx31moboard_baseboard) { | 548 | switch (mx31moboard_baseboard) { |
532 | case MX31NOBOARD: | 549 | case MX31NOBOARD: |
533 | break; | 550 | break; |
@@ -572,6 +589,7 @@ MACHINE_START(MX31MOBOARD, "EPFL Mobots mx31moboard") | |||
572 | .map_io = mx31_map_io, | 589 | .map_io = mx31_map_io, |
573 | .init_early = imx31_init_early, | 590 | .init_early = imx31_init_early, |
574 | .init_irq = mx31_init_irq, | 591 | .init_irq = mx31_init_irq, |
592 | .handle_irq = imx31_handle_irq, | ||
575 | .timer = &mx31moboard_timer, | 593 | .timer = &mx31moboard_timer, |
576 | .init_machine = mx31moboard_init, | 594 | .init_machine = mx31moboard_init, |
577 | MACHINE_END | 595 | MACHINE_END |