diff options
author | Andriy Skulysh <askulysh@gmail.com> | 2006-09-27 03:20:22 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2006-09-27 03:20:22 -0400 |
commit | 3aa770e7972723f479122cf66b529017d2175289 (patch) | |
tree | f70d870381cec8034693704e346c53b311db688f /arch/sh/boards/hp6xx/setup.c | |
parent | ef48e8e3498605351f91f195cc9af0ef981b0dde (diff) |
sh: APM/PM support.
This adds some simple PM stubs and the basic APM interfaces,
primarily for use by hp6xx, where the existing userland
expects it.
Signed-off-by: Andriy Skulysh <askulysh@gmail.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/boards/hp6xx/setup.c')
-rw-r--r-- | arch/sh/boards/hp6xx/setup.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/sh/boards/hp6xx/setup.c b/arch/sh/boards/hp6xx/setup.c index 71f315663cc9..5fc00f0727c4 100644 --- a/arch/sh/boards/hp6xx/setup.c +++ b/arch/sh/boards/hp6xx/setup.c | |||
@@ -15,6 +15,9 @@ | |||
15 | #include <asm/hp6xx/hp6xx.h> | 15 | #include <asm/hp6xx/hp6xx.h> |
16 | #include <asm/cpu/dac.h> | 16 | #include <asm/cpu/dac.h> |
17 | 17 | ||
18 | #define SCPCR 0xa4000116 | ||
19 | #define SCPDR 0xa4000136 | ||
20 | |||
18 | const char *get_system_type(void) | 21 | const char *get_system_type(void) |
19 | { | 22 | { |
20 | return "HP6xx"; | 23 | return "HP6xx"; |
@@ -24,6 +27,7 @@ int __init platform_setup(void) | |||
24 | { | 27 | { |
25 | u8 v8; | 28 | u8 v8; |
26 | u16 v; | 29 | u16 v; |
30 | |||
27 | v = inw(HD64461_STBCR); | 31 | v = inw(HD64461_STBCR); |
28 | v |= HD64461_STBCR_SURTST | HD64461_STBCR_SIRST | | 32 | v |= HD64461_STBCR_SURTST | HD64461_STBCR_SIRST | |
29 | HD64461_STBCR_STM1ST | HD64461_STBCR_STM0ST | | 33 | HD64461_STBCR_STM1ST | HD64461_STBCR_STM0ST | |
@@ -50,5 +54,15 @@ int __init platform_setup(void) | |||
50 | v8 &= ~DACR_DAE; | 54 | v8 &= ~DACR_DAE; |
51 | ctrl_outb(v8,DACR); | 55 | ctrl_outb(v8,DACR); |
52 | 56 | ||
57 | v8 = ctrl_inb(SCPDR); | ||
58 | v8 |= SCPDR_TS_SCAN_X | SCPDR_TS_SCAN_Y; | ||
59 | v8 &= ~SCPDR_TS_SCAN_ENABLE; | ||
60 | ctrl_outb(v8, SCPDR); | ||
61 | |||
62 | v = ctrl_inw(SCPCR); | ||
63 | v &= ~SCPCR_TS_MASK; | ||
64 | v |= SCPCR_TS_ENABLE; | ||
65 | ctrl_outw(v, SCPCR); | ||
66 | |||
53 | return 0; | 67 | return 0; |
54 | } | 68 | } |