1 /* arch/arm/mach-msm/pm.c 2 * 3 * Goldfish Power Management Routines 4 * 5 * Copyright (C) 2007 Google, Inc. 6 * 7 * This software is licensed under the terms of the GNU General Public 8 * License version 2, as published by the Free Software Foundation, and 9 * may be copied, distributed, and modified under those terms. 10 * 11 * This program is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 * GNU General Public License for more details. 15 * 16 */ 17 18 #include <linux/module.h> 19 #include <linux/kernel.h> 20 #include <linux/init.h> 21 #include <linux/pm.h> 22 #include <linux/suspend.h> 23 #include <mach/system.h> 24 goldfish_pm_enter(suspend_state_t state)25static int goldfish_pm_enter(suspend_state_t state) 26 { 27 arch_idle(); 28 return 0; 29 } 30 31 static struct platform_suspend_ops goldfish_pm_ops = { 32 .enter = goldfish_pm_enter, 33 .valid = suspend_valid_only_mem, 34 }; 35 goldfish_pm_init(void)36static int __init goldfish_pm_init(void) 37 { 38 suspend_set_ops(&goldfish_pm_ops); 39 return 0; 40 } 41 42 __initcall(goldfish_pm_init); 43 44