aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/loongson
diff options
context:
space:
mode:
authorWu Zhangjin <wuzhangjin@gmail.com>2009-11-24 08:48:36 -0500
committerRalf Baechle <ralf@linux-mips.org>2009-12-16 20:57:33 -0500
commitc47a48d83a7a82c86ff3e74bdcabeee8f6e6b730 (patch)
treefeae9101c62c105a1afe9b5826b1921bb50d581b /arch/mips/loongson
parent59d4a91416957c12ccc4185d90a62eb1b44b2fc8 (diff)
MIPS: Lemote 2F: Suspend CS5536 MFGPT Timer
Before putting the Loongson 2F into wait mode, suspend the MFGPT Timer and after wake-up resume it. This may save some power. Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com> Cc: linux-mips@linux-mips.org Patchwork: http://patchwork.linux-mips.org/patch/706/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/loongson')
-rw-r--r--arch/mips/loongson/lemote-2f/pm.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/mips/loongson/lemote-2f/pm.c b/arch/mips/loongson/lemote-2f/pm.c
index 81c06410aa76..d7af2e616592 100644
--- a/arch/mips/loongson/lemote-2f/pm.c
+++ b/arch/mips/loongson/lemote-2f/pm.c
@@ -22,6 +22,7 @@
22 22
23#include <loongson.h> 23#include <loongson.h>
24 24
25#include <cs5536/cs5536_mfgpt.h>
25#include "ec_kb3310b.h" 26#include "ec_kb3310b.h"
26 27
27#define I8042_KBD_IRQ 1 28#define I8042_KBD_IRQ 1
@@ -136,3 +137,13 @@ int wakeup_loongson(void)
136 137
137 return 0; 138 return 0;
138} 139}
140
141void __weak mach_suspend(void)
142{
143 disable_mfgpt0_counter();
144}
145
146void __weak mach_resume(void)
147{
148 enable_mfgpt0_counter();
149}