linux/arch/powerpc/kernel
Johannes Berg be9c94dd77 [POWERPC] Fix suspend states again
In commit 0fba3a1f39 (a very long time ago,
May 2006), I fixed a bug that caused powermacs to crash when you tried
entering standby/mem suspend states.

As I'm now getting more familiar with the suspend code I notice a few
more things:
 1. we previously misunderstood what pm_ops is for, it isn't supposed to be
    for doing platform dependent suspend/resume stuff that needs to be done
    for suspend to disk (as we currently try to use it!), it is instead for
    entering platform dependent suspend states ("standby", "mem").
 2. due to the first point, we never properly save FPU and altivec states
    when suspending to disk. It probably hasn't hurt yet because the process
    that writes the "disk" to /sys/power/state uses neither and its context
    is used.

This patch addresses these points as follows:
 1. remove all pm_ops from powermac, powermac suspend to ram isn't currently
    usable via /sys/power/state but is done via the PMU instead.
 2. move the code responsible for storing FPU/altivec state into
    save_processor_state and the set_context() call to restore_processor_state.
 3. add a call to kernel_enable_spe()

It may look like there is some code removal missing but that is
actually because the new suspend.h file overrides the ppc/suspend.h
one which was previously used.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-05-02 20:04:30 +10:00
..
vdso32 [POWERPC] Support feature fixups in vdso's 2006-10-25 11:54:07 +10:00
vdso64 [POWERPC] Cell timebase bug workaround 2006-10-25 11:54:18 +10:00
align.c [POWERPC] Alignment exception uses __get/put_user_inatomic 2007-04-13 04:09:38 +10:00
asm-offsets.c [POWERPC] Save trap number in bad_stack 2007-04-24 22:06:59 +10:00
audit.c [PATCH] audit: AUDIT_PERM support 2006-09-11 13:32:30 -04:00
binfmt_elf32.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
btext.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
compat_audit.c [PATCH] audit: AUDIT_PERM support 2006-09-11 13:32:30 -04:00
cpu_setup_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
cpu_setup_pa6t.S [POWERPC] pasemi: Enable one more hid bit 2007-04-24 21:31:49 +10:00
cpu_setup_ppc970.S [POWERPC] powerpc: Enable DEEPNAP power savings mode on 970MP 2006-10-16 16:32:25 +10:00
cputable.c [POWERPC] pasemi: PA6T oprofile support 2007-04-24 21:31:51 +10:00
crash.c [PATCH] Kexec / Kdump: Unify elf note code 2006-12-07 08:39:46 -08:00
crash_dump.c [POWERPC] Make doc comments extractable 2006-08-08 17:07:04 +10:00
dma_64.c [POWERPC] Make direct DMA use node local allocations 2006-12-04 20:38:59 +11:00
entry_32.S [POWERPC] Remove last_syscall 2007-03-22 22:52:58 +11:00
entry_64.S [POWERPC] Clear RI bit in MSR before restoring r13 when returning to userspace 2007-02-07 14:03:23 +11:00
firmware.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
fpu.S [POWERPC] Restore copyright notice in arch/powerpc/kernel/fpu.S 2006-08-30 14:45:35 +10:00
head_4xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_8xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
head_32.S [POWERPC] Remove the broken Gemini support 2007-01-24 21:13:58 +11:00
head_44x.S [POWERPC] Revise PPC44x MMU code for arch/powerpc 2007-05-02 20:04:29 +10:00
head_64.S [POWERPC] Save trap number in bad_stack 2007-04-24 22:06:59 +10:00
head_booke.h [PATCH] powerpc: Fix Kernel FP unavail exception for BookE 2006-02-10 16:51:50 +11:00
head_fsl_booke.S [POWERPC] 85xx: Drop use of SYNC macro in head_fsl_booke.S 2007-02-13 16:13:27 -06:00
ibmebus.c [POWERPC] ibmebus: change probe/remove interface from using loc-code to DT path 2007-04-13 06:12:42 +10:00
idle.c [PATCH] sysctl: remove insert_at_head from register_sysctl 2007-02-14 08:09:59 -08:00
idle_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
idle_power4.S [POWERPC] Lazy interrupt disabling for 64-bit machines 2006-10-16 16:31:36 +10:00
init_task.c [PATCH] nsproxy: move init_nsproxy into kernel/nsproxy.c 2006-10-02 07:57:20 -07:00
io.c [POWERPC] Merge 32 and 64 bits asm-powerpc/io.h 2006-12-04 20:39:05 +11:00
iomap.c [POWERPC] Remove fastcall function attribute 2007-01-26 01:52:27 -06:00
iommu.c Revert "[POWERPC] DMA 4GB boundary protection" 2007-04-26 19:48:15 +10:00
irq.c [POWERPC] Spinlock initializer cleanup 2007-04-30 11:02:06 +10:00
kprobes.c [POWERPC] kprobes: Eliminate sstep exception if instruction can be emulated 2007-04-24 21:31:58 +10:00
l2cr_6xx.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
legacy_serial.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
lparcfg.c [POWERPC] Replace if-then-else with a switch statement 2007-04-27 21:13:21 +10:00
lparmap.c [PATCH] powerpc: Fix iSeries bug in VMALLOCBASE/VMALLOC_START consolidation 2006-01-09 15:06:06 +11:00
machine_kexec.c [POWERPC] Move some kexec logic into machine_kexec.c 2006-08-17 16:41:10 +10:00
machine_kexec_32.c Storage class should be first 2006-06-26 18:57:34 +02:00
machine_kexec_64.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
Makefile [POWERPC] Fix suspend states again 2007-05-02 20:04:30 +10:00
misc.S [POWERPC] convert string i/o operations to C 2006-09-20 14:06:18 +10:00
misc_32.S [POWERPC] Remove _get_SP 2007-03-22 22:52:58 +11:00
misc_64.S [POWERPC] pasemi: UART udbg support 2007-02-07 14:03:22 +11:00
module_32.c [POWERPC] Add support for R_PPC_ADDR16_HI relocations 2007-01-24 21:13:58 +11:00
module_64.c [POWERPC] Generic BUG for powerpc 2006-12-11 16:35:07 +11:00
nvram_64.c [PATCH] mark struct file_operations const 2 2007-02-12 09:48:44 -08:00
of_device.c [POWERPC] Rename last get_property calls 2007-04-24 21:31:40 +10:00
of_platform.c Merge branch 'linux-2.6' into for-2.6.22 2007-04-30 12:38:01 +10:00
paca.c [POWERPC] Implement SLB shadow buffer 2006-08-08 17:08:56 +10:00
pci_32.c [POWERPC] Fix STRICT_MM_TYPECHECKS 2007-05-02 20:04:30 +10:00
pci_64.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
pci_dn.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
pmc.c [POWERPC] PA6T PMC support 2007-02-07 14:03:19 +11:00
ppc32.h
ppc_ksyms.c Merge branch 'linux-2.6' into for-2.6.22 2007-04-30 12:38:01 +10:00
proc_ppc64.c [PATCH] mark struct file_operations const 2 2007-02-12 09:48:44 -08:00
process.c [POWERPC] Make tlb flush batch use lazy MMU mode 2007-04-13 04:09:38 +10:00
prom.c [POWERPC] Remove old interface find_devices 2007-04-24 22:09:02 +10:00
prom_init.c [POWERPC] Add correct interrupt property for pegasos ide 2007-04-13 04:00:25 +10:00
prom_parse.c [POWERPC] Uninline of_iomap function 2007-05-02 20:04:29 +10:00
ptrace-common.h Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
ptrace.c [POWERPC] Mask 32-bit system call arguments to 32 bits on PPC64 in audit code 2007-01-24 21:13:58 +11:00
ptrace32.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
rtas-proc.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
rtas-rtc.c [PATCH] powerpc: reorg RTAS delay code 2006-06-09 21:21:06 +10:00
rtas.c [POWERPC] Remove old interface find_path_device 2007-04-24 22:08:59 +10:00
rtas_flash.c [PATCH] mark struct file_operations const 2 2007-02-12 09:48:44 -08:00
rtas_pci.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
semaphore.c
setup-common.c [POWERPC] Generic check_legacy_ioport 2007-04-27 21:14:30 +10:00
setup.h [PATCH] powerpc: Make early xmon logic immune to location of early parsing 2006-05-19 15:02:12 +10:00
setup_32.c [POWERPC] Fix breakage caused by 72486f1f8f 2007-04-13 03:55:16 +10:00
setup_64.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
signal_32.c [POWERPC] Fix register save area alignment for swapcontext syscall 2006-12-20 16:37:49 +11:00
signal_64.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
smp-tbsync.c [POWERPC] Replace kmalloc+memset with kzalloc 2006-12-04 20:42:09 +11:00
smp.c [POWERPC] Make tlb flush batch use lazy MMU mode 2007-04-13 04:09:38 +10:00
swsusp.c [POWERPC] Fix suspend states again 2007-05-02 20:04:30 +10:00
swsusp_32.S [PATCH] Change the name of pagedir_nosave 2006-09-26 08:49:01 -07:00
sys_ppc32.c [POWERPC] Clean up unused ROUND_UP, NAME_OFFSET macros in arch/powerpc 2007-04-13 04:00:41 +10:00
syscalls.c [PATCH] namespaces: utsname: switch to using uts namespaces 2006-10-02 07:57:21 -07:00
sysfs.c [POWERPC] Remove old interface find_path_device 2007-04-24 22:08:59 +10:00
systbl.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
tau_6xx.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
time.c [POWERPC] Rename get_property to of_get_property: arch/powerpc 2007-04-13 03:55:19 +10:00
traps.c [POWERPC] Fix backwards ? : when printing machine type 2007-03-26 12:34:31 +10:00
udbg.c [POWERPC] Use udbg_early_init() on ppc32 2007-02-14 11:55:16 +11:00
udbg_16550.c [PATCH] constant should be long 2007-03-14 15:27:50 -07:00
vdso.c [POWERPC] Fix vDSO page count calculation 2007-02-13 15:35:52 +11:00
vecemu.c
vector.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
vio.c [POWERPC] Remove old interface find_devices 2007-04-24 22:09:02 +10:00
vmlinux.lds.S [PATCH] disable init/initramfs.c: architectures 2007-02-11 10:51:25 -08:00