diff options
author | Olof Johansson | 2007-09-05 04:09:45 +0200 |
---|---|---|
committer | Paul Mackerras | 2007-09-13 17:33:22 +0200 |
commit | 3850169dbddcc9e53fd550eb093af7da5dfcefa9 (patch) | |
tree | 006b679ddb52704f1a3a945513bd9316733962af /arch/powerpc/platforms/pasemi/idle.c | |
parent | [POWERPC] pasemi: Print more information at machine check (diff) | |
download | kernel-qcow2-linux-3850169dbddcc9e53fd550eb093af7da5dfcefa9.tar.gz kernel-qcow2-linux-3850169dbddcc9e53fd550eb093af7da5dfcefa9.tar.xz kernel-qcow2-linux-3850169dbddcc9e53fd550eb093af7da5dfcefa9.zip |
[POWERPC] pasemi: Move pasemi_idle_init() to late_initcall()
Move pasemi_idle_init() to be a late_initcall instead of being called from
setup_arch(). This way the cpufreq driver has a chance to initialize and
save away the boot time astate before we go to idle for the first time.
Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/platforms/pasemi/idle.c')
-rw-r--r-- | arch/powerpc/platforms/pasemi/idle.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/pasemi/idle.c b/arch/powerpc/platforms/pasemi/idle.c index 3c962d5757be..d8e1fcc78513 100644 --- a/arch/powerpc/platforms/pasemi/idle.c +++ b/arch/powerpc/platforms/pasemi/idle.c @@ -72,8 +72,11 @@ static int pasemi_system_reset_exception(struct pt_regs *regs) return 1; } -void __init pasemi_idle_init(void) +static int __init pasemi_idle_init(void) { + if (!machine_is(pasemi)) + return -ENODEV; + #ifndef CONFIG_PPC_PASEMI_CPUFREQ printk(KERN_WARNING "No cpufreq driver, powersavings modes disabled\n"); current_mode = 0; @@ -82,7 +85,10 @@ void __init pasemi_idle_init(void) ppc_md.system_reset_exception = pasemi_system_reset_exception; ppc_md.power_save = modes[current_mode].entry; printk(KERN_INFO "Using PA6T idle loop (%s)\n", modes[current_mode].name); + + return 0; } +late_initcall(pasemi_idle_init); static int __init idle_param(char *p) { |