diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-02-17 21:19:25 -0500 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2009-02-17 21:19:25 -0500 |
commit | 82a0a1cc8f94bc59e5919715bc03fc8353fa770d (patch) | |
tree | c25f19a0ae1f7cb75319b585c1d473cfed463f22 /arch/powerpc/kernel | |
parent | 8d30c14cab30d405a05f2aaceda1e9ad57800f36 (diff) | |
parent | 5955c7a2cfb6a35429adea5dc480002b15ca8cfc (diff) |
Merge commit 'origin/master' into next
Manual merge of:
arch/powerpc/include/asm/pgtable-ppc32.h
Diffstat (limited to 'arch/powerpc/kernel')
-rw-r--r-- | arch/powerpc/kernel/align.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/align.c b/arch/powerpc/kernel/align.c index 5af4e9b2dbe2..ada06924a423 100644 --- a/arch/powerpc/kernel/align.c +++ b/arch/powerpc/kernel/align.c | |||
@@ -646,11 +646,16 @@ static int emulate_vsx(unsigned char __user *addr, unsigned int reg, | |||
646 | unsigned int areg, struct pt_regs *regs, | 646 | unsigned int areg, struct pt_regs *regs, |
647 | unsigned int flags, unsigned int length) | 647 | unsigned int flags, unsigned int length) |
648 | { | 648 | { |
649 | char *ptr = (char *) ¤t->thread.TS_FPR(reg); | 649 | char *ptr; |
650 | int ret = 0; | 650 | int ret = 0; |
651 | 651 | ||
652 | flush_vsx_to_thread(current); | 652 | flush_vsx_to_thread(current); |
653 | 653 | ||
654 | if (reg < 32) | ||
655 | ptr = (char *) ¤t->thread.TS_FPR(reg); | ||
656 | else | ||
657 | ptr = (char *) ¤t->thread.vr[reg - 32]; | ||
658 | |||
654 | if (flags & ST) | 659 | if (flags & ST) |
655 | ret = __copy_to_user(addr, ptr, length); | 660 | ret = __copy_to_user(addr, ptr, length); |
656 | else { | 661 | else { |