From: Wu Zhangjin Date: Tue, 24 Nov 2009 13:48:36 +0000 (+0800) Subject: MIPS: Lemote 2F: Suspend CS5536 MFGPT Timer X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c47a48d83a7a82c86ff3e74bdcabeee8f6e6b730;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git 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 Cc: linux-mips@linux-mips.org Patchwork: http://patchwork.linux-mips.org/patch/706/ Signed-off-by: Ralf Baechle --- 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 @@ #include +#include #include "ec_kb3310b.h" #define I8042_KBD_IRQ 1 @@ -136,3 +137,13 @@ int wakeup_loongson(void) return 0; } + +void __weak mach_suspend(void) +{ + disable_mfgpt0_counter(); +} + +void __weak mach_resume(void) +{ + enable_mfgpt0_counter(); +}