Nishanth Aravamudan
c8adfeccee
powerpc: Fix VMX fix for memcpy case
In 2fae7cdb60 ("powerpc: Fix VMX in
interrupt check in POWER7 copy loops"), Anton inadvertently
introduced a regression for memcpy on POWER7 machines. copyuser and
memcpy diverge slightly in their use of cr1 (copyuser doesn't use it,
but memcpy does) and you end up clobbering that register with your fix.
That results in (taken from an FC18 kernel):
[ 18.824604] Unrecoverable VMX/Altivec Unavailable Exception f20 at c000000000052f40
[ 18.824618] Oops: Unrecoverable VMX/Altivec Unavailable Exception, sig: 6 [#1]
[ 18.824623] SMP NR_CPUS=1024 NUMA pSeries
[ 18.824633] Modules linked in: tg3(+) be2net(+) cxgb4(+) ipr(+) sunrpc xts lrw gf128mul dm_crypt dm_round_robin dm_multipath linear raid10 raid456 async_raid6_recov async_memcpy async_pq raid6_pq async_xor xor async_tx raid1 raid0 scsi_dh_rdac scsi_dh_hp_sw scsi_dh_emc scsi_dh_alua squashfs cramfs
[ 18.824705] NIP: c000000000052f40 LR: c00000000020b874 CTR: 0000000000000512
[ 18.824709] REGS: c000001f1fef7790 TRAP: 0f20 Not tainted (3.6.0-0.rc6.git0.2.fc18.ppc64)
[ 18.824713] MSR: 8000000000009032 <SF,EE,ME,IR,DR,RI> CR: 4802802e XER: 20000010
[ 18.824726] SOFTE: 0
[ 18.824728] CFAR: 0000000000000f20
[ 18.824731] TASK = c000000fa7128400[0] 'swapper/24' THREAD: c000000fa7480000 CPU: 24
GPR00: 00000000ffffffc0 c000001f1fef7a10 c00000000164edc0 c000000f9b9a8120
GPR04: c000000f9b9a8124 0000000000001438 0000000000000060 03ffffff064657ee
GPR08: 0000000080000000 0000000000000010 0000000000000020 0000000000000030
GPR12: 0000000028028022 c00000000ff25400 0000000000000001 0000000000000000
GPR16: 0000000000000000 7fffffffffffffff c0000000016b2180 c00000000156a500
GPR20: c000000f968c7a90 c0000000131c31d8 c000001f1fef4000 c000000001561d00
GPR24: 000000000000000a 0000000000000000 0000000000000001 0000000000000012
GPR28: c000000fa5c04f80 00000000000008bc c0000000015c0a28 000000000000022e
[ 18.824792] NIP [c000000000052f40] .memcpy_power7+0x5a0/0x7c4
[ 18.824797] LR [c00000000020b874] .pcpu_free_area+0x174/0x2d0
[ 18.824800] Call Trace:
[ 18.824803] [c000001f1fef7a10] [c000000000052c14] .memcpy_power7+0x274/0x7c4 (unreliable)
[ 18.824809] [c000001f1fef7b10] [c00000000020b874] .pcpu_free_area+0x174/0x2d0
[ 18.824813] [c000001f1fef7bb0] [c00000000020ba88] .free_percpu+0xb8/0x1b0
[ 18.824819] [c000001f1fef7c50] [c00000000043d144] .throtl_pd_exit+0x94/0xd0
[ 18.824824] [c000001f1fef7cf0] [c00000000043acf8] .blkg_free+0x88/0xe0
[ 18.824829] [c000001f1fef7d90] [c00000000018c048] .rcu_process_callbacks+0x2e8/0x8a0
[ 18.824835] [c000001f1fef7e90] [c0000000000a8ce8] .__do_softirq+0x158/0x4d0
[ 18.824840] [c000001f1fef7f90] [c000000000025ecc] .call_do_softirq+0x14/0x24
[ 18.824845] [c000000fa7483650] [c000000000010e80] .do_softirq+0x160/0x1a0
[ 18.824850] [c000000fa74836f0] [c0000000000a94a4] .irq_exit+0xf4/0x120
[ 18.824854] [c000000fa7483780] [c000000000020c44] .timer_interrupt+0x154/0x4d0
[ 18.824859] [c000000fa7483830] [c000000000003be0] decrementer_common+0x160/0x180
[ 18.824866] --- Exception: 901 at .plpar_hcall_norets+0x84/0xd4
[ 18.824866] LR = .check_and_cede_processor+0x48/0x80
[ 18.824871] [c000000fa7483b20] [c00000000007f018] .check_and_cede_processor+0x18/0x80 (unreliable)
[ 18.824877] [c000000fa7483b90] [c00000000007f104] .dedicated_cede_loop+0x84/0x150
[ 18.824883] [c000000fa7483c50] [c0000000006bc030] .cpuidle_enter+0x30/0x50
[ 18.824887] [c000000fa7483cc0] [c0000000006bc9f4] .cpuidle_idle_call+0x104/0x720
[ 18.824892] [c000000fa7483d80] [c000000000070af8] .pSeries_idle+0x18/0x40
[ 18.824897] [c000000fa7483df0] [c000000000019084] .cpu_idle+0x1a4/0x380
[ 18.824902] [c000000fa7483ec0] [c0000000008a4c18] .start_secondary+0x520/0x528
[ 18.824907] [c000000fa7483f90] [c0000000000093f0] .start_secondary_prolog+0x10/0x14
[ 18.824911] Instruction dump:
[ 18.824914] 38840008 90030000 90e30004 38630008 7ca62850 7cc300d0 78c7e102 7cf01120
[ 18.824923] 78c60660 39200010 39400020 39600030 <7e00200c> 7c0020ce 38840010 409f001c
[ 18.824935] ---[ end trace 0bb95124affaaa45 ]---
[ 18.825046] Unrecoverable VMX/Altivec Unavailable Exception f20 at c000000000052d08
I believe the right fix is to make memcpy match usercopy and not use
cr1.
Signed-off-by: Nishanth Aravamudan <[email protected]>
Signed-off-by: Benjamin Herrenschmidt <[email protected]>
CC: <[email protected]> [v3.6]
|
2012-10-04 18:02:43 +10:00 |
| .. |
|
alpha
|
alpha: Fix fall-out from disintegrating asm/system.h
|
2012-08-19 08:41:19 -07:00 |
|
arm
|
Merge commit 'v3.6-rc5' into pci/gavin-window-alignment
|
2012-09-13 15:54:57 -06:00 |
|
avr32
|
ipc: use Kconfig options for __ARCH_WANT_[COMPAT_]IPC_PARSE_VERSION
|
2012-07-30 17:25:21 -07:00 |
|
blackfin
|
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k
|
2012-08-03 10:52:41 -07:00 |
|
c6x
|
Enable atomic64 ops in C6X
|
2012-08-17 08:10:12 -07:00 |
|
cris
|
ipc: use Kconfig options for __ARCH_WANT_[COMPAT_]IPC_PARSE_VERSION
|
2012-07-30 17:25:21 -07:00 |
|
frv
|
Merge branch 'akpm' (Andrew's patch-bomb)
|
2012-07-30 17:25:34 -07:00 |
|
h8300
|
ipc: use Kconfig options for __ARCH_WANT_[COMPAT_]IPC_PARSE_VERSION
|
2012-07-30 17:25:21 -07:00 |
|
hexagon
|
Merge branch 'trivial' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
|
2012-07-30 11:24:53 -07:00 |
|
ia64
|
[IA64] defconfig: Remove CONFIG_MISC_DEVICES
|
2012-08-20 13:04:29 -07:00 |
|
m32r
|
ipc: use Kconfig options for __ARCH_WANT_[COMPAT_]IPC_PARSE_VERSION
|
2012-07-30 17:25:21 -07:00 |
|
m68k
|
m68k: select CONFIG_GENERIC_ATOMIC64 for all m68k CPU types
|
2012-08-17 10:04:24 +10:00 |
|
microblaze
|
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k
|
2012-08-03 10:52:41 -07:00 |
|
mips
|
Merge commit 'v3.6-rc5' into pci/gavin-window-alignment
|
2012-09-13 15:54:57 -06:00 |
|
mn10300
|
Merge branch 'akpm' (Andrew's patch-bomb)
|
2012-07-30 17:25:34 -07:00 |
|
openrisc
|
|
|
|
parisc
|
[PARISC] fix personality flag check in copy_thread()
|
2012-08-03 11:25:12 +01:00 |
|
powerpc
|
powerpc: Fix VMX fix for memcpy case
|
2012-10-04 18:02:43 +10:00 |
|
s390
|
s390/32: Don't clobber personality flags on exec
|
2012-08-30 16:28:07 +02:00 |
|
score
|
|
|
|
sh
|
Merge branches 'sh/urgent' and 'sh/gpiolib' into sh-latest
|
2012-08-09 13:21:13 +09:00 |
|
sparc
|
sparc64: Be less verbose during vmemmap population.
|
2012-08-15 00:37:29 -07:00 |
|
tile
|
tile: PCI: Use PCI Express Capability accessors
|
2012-08-23 10:11:12 -06:00 |
|
um
|
uml: fix compile error in deliver_alarm()
|
2012-09-05 19:40:59 -07:00 |
|
unicore32
|
PCI changes for the 3.6 merge window:
|
2012-07-24 16:17:07 -07:00 |
|
x86
|
Bug-fixes:
|
2012-09-06 17:16:42 -07:00 |
|
xtensa
|
xtensa: select generic atomic64_t support
|
2012-07-31 18:42:39 -07:00 |
|
.gitignore
|
|
|
|
Kconfig
|
ipc: use Kconfig options for __ARCH_WANT_[COMPAT_]IPC_PARSE_VERSION
|
2012-07-30 17:25:21 -07:00 |