diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-12-08 11:15:29 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-12-08 11:15:29 -0500 |
| commit | 1c496784a0d317535f846ddb2c93a08ba936266b (patch) | |
| tree | 6d0225860032f263b6d95a3e55c364a1a5f55ec1 /arch/arm/mach-omap2/pm-debug.c | |
| parent | adf9904dc774f23f04a5425f0198483ea61f878b (diff) | |
| parent | 9a01609e1885b827b979d6d9dd86f43208a9e5fc (diff) | |
Merge branch 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (149 commits)
arm: omap: Add omap3_defconfig
AM35xx: Defconfig for AM3517 EVM board
AM35xx: Add support for AM3517 EVM board
omap: 3630sdp: defconfig creation
omap: 3630sdp: introduce 3630 sdp board support
omap3: Add defconfig for IGEP v2 board
omap3: Add minimal IGEP v2 support
omap3: Add CompuLab CM-T35 defconfig
omap3: Add CompuLab CM-T35 board support
omap3: rx51: Add wl1251 wlan driver support
omap3: rx51: Add SDRAM init
omap1: Add default kernel configuration for Herald
omap1: Add board support and LCD for HTC Herald
omap: zoom2: update defconfig for LL_DEBUG_NONE
omap: zoom3: defconfig creation
omap3: zoom: Introduce zoom3 board support
omap3: zoom: Drop i2c-1 speed to 2400
omap3: zoom: rename zoom2 name to generic zoom
omap3: zoom: split board file for software reuse
omap3evm: MIgrate to smsc911x ethernet driver
...
Fix trivial conflict (two unrelated config options added next to each
other) in arch/arm/mach-omap2/Makefile
Diffstat (limited to 'arch/arm/mach-omap2/pm-debug.c')
| -rw-r--r-- | arch/arm/mach-omap2/pm-debug.c | 40 |
1 files changed, 35 insertions, 5 deletions
diff --git a/arch/arm/mach-omap2/pm-debug.c b/arch/arm/mach-omap2/pm-debug.c index 2fc4d6abbd0a..8baa30d2acfb 100644 --- a/arch/arm/mach-omap2/pm-debug.c +++ b/arch/arm/mach-omap2/pm-debug.c | |||
| @@ -26,10 +26,10 @@ | |||
| 26 | #include <linux/io.h> | 26 | #include <linux/io.h> |
| 27 | #include <linux/module.h> | 27 | #include <linux/module.h> |
| 28 | 28 | ||
| 29 | #include <mach/clock.h> | 29 | #include <plat/clock.h> |
| 30 | #include <mach/board.h> | 30 | #include <plat/board.h> |
| 31 | #include <mach/powerdomain.h> | 31 | #include <plat/powerdomain.h> |
| 32 | #include <mach/clockdomain.h> | 32 | #include <plat/clockdomain.h> |
| 33 | 33 | ||
| 34 | #include "prm.h" | 34 | #include "prm.h" |
| 35 | #include "cm.h" | 35 | #include "cm.h" |
| @@ -51,7 +51,8 @@ int omap2_pm_debug; | |||
| 51 | regs[reg_count++].val = __raw_readl(reg) | 51 | regs[reg_count++].val = __raw_readl(reg) |
| 52 | #define DUMP_INTC_REG(reg, off) \ | 52 | #define DUMP_INTC_REG(reg, off) \ |
| 53 | regs[reg_count].name = #reg; \ | 53 | regs[reg_count].name = #reg; \ |
| 54 | regs[reg_count++].val = __raw_readl(OMAP2_IO_ADDRESS(0x480fe000 + (off))) | 54 | regs[reg_count++].val = \ |
| 55 | __raw_readl(OMAP2_L4_IO_ADDRESS(0x480fe000 + (off))) | ||
| 55 | 56 | ||
| 56 | static int __init pm_dbg_init(void); | 57 | static int __init pm_dbg_init(void); |
| 57 | 58 | ||
| @@ -526,6 +527,29 @@ static int __init pwrdms_setup(struct powerdomain *pwrdm, void *dir) | |||
| 526 | return 0; | 527 | return 0; |
| 527 | } | 528 | } |
| 528 | 529 | ||
| 530 | static int option_get(void *data, u64 *val) | ||
| 531 | { | ||
| 532 | u32 *option = data; | ||
| 533 | |||
| 534 | *val = *option; | ||
| 535 | |||
| 536 | return 0; | ||
| 537 | } | ||
| 538 | |||
| 539 | static int option_set(void *data, u64 val) | ||
| 540 | { | ||
| 541 | u32 *option = data; | ||
| 542 | |||
| 543 | *option = val; | ||
| 544 | |||
| 545 | if (option == &enable_off_mode) | ||
| 546 | omap3_pm_off_mode_enable(val); | ||
| 547 | |||
| 548 | return 0; | ||
| 549 | } | ||
| 550 | |||
| 551 | DEFINE_SIMPLE_ATTRIBUTE(pm_dbg_option_fops, option_get, option_set, "%llu\n"); | ||
| 552 | |||
| 529 | static int __init pm_dbg_init(void) | 553 | static int __init pm_dbg_init(void) |
| 530 | { | 554 | { |
| 531 | int i; | 555 | int i; |
| @@ -568,6 +592,12 @@ static int __init pm_dbg_init(void) | |||
| 568 | 592 | ||
| 569 | } | 593 | } |
| 570 | 594 | ||
| 595 | (void) debugfs_create_file("enable_off_mode", S_IRUGO | S_IWUGO, d, | ||
| 596 | &enable_off_mode, &pm_dbg_option_fops); | ||
| 597 | (void) debugfs_create_file("sleep_while_idle", S_IRUGO | S_IWUGO, d, | ||
| 598 | &sleep_while_idle, &pm_dbg_option_fops); | ||
| 599 | (void) debugfs_create_file("wakeup_timer_seconds", S_IRUGO | S_IWUGO, d, | ||
| 600 | &wakeup_timer_seconds, &pm_dbg_option_fops); | ||
| 571 | pm_dbg_init_done = 1; | 601 | pm_dbg_init_done = 1; |
| 572 | 602 | ||
| 573 | return 0; | 603 | return 0; |
