aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2012-05-29 15:31:24 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2012-07-03 00:14:43 -0400
commit6f7839e542ee18770288be75114bd2e6771e1421 (patch)
treedef074cab8abe5058533d90e88f82a61e91ce803
parentac1dc36558da25934f83a2871b9e70239a987351 (diff)
powerpc: Rename copyuser_power7_vmx.c to vmx-helper.c
Subsequent patches will add more VMX library functions and it makes sense to keep all the c-code helper functions in the one file. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
-rw-r--r--arch/powerpc/lib/Makefile2
-rw-r--r--arch/powerpc/lib/copyuser_power7.S8
-rw-r--r--arch/powerpc/lib/vmx-helper.c (renamed from arch/powerpc/lib/copyuser_power7_vmx.c)4
3 files changed, 7 insertions, 7 deletions
diff --git a/arch/powerpc/lib/Makefile b/arch/powerpc/lib/Makefile
index f049e339e456..1eb94c7af6c7 100644
--- a/arch/powerpc/lib/Makefile
+++ b/arch/powerpc/lib/Makefile
@@ -24,7 +24,7 @@ obj-$(CONFIG_HAVE_HW_BREAKPOINT) += sstep.o ldstfp.o
24 24
25ifeq ($(CONFIG_PPC64),y) 25ifeq ($(CONFIG_PPC64),y)
26obj-$(CONFIG_SMP) += locks.o 26obj-$(CONFIG_SMP) += locks.o
27obj-$(CONFIG_ALTIVEC) += copyuser_power7_vmx.o 27obj-$(CONFIG_ALTIVEC) += vmx-helper.o
28endif 28endif
29 29
30obj-$(CONFIG_PPC_LIB_RHEAP) += rheap.o 30obj-$(CONFIG_PPC_LIB_RHEAP) += rheap.o
diff --git a/arch/powerpc/lib/copyuser_power7.S b/arch/powerpc/lib/copyuser_power7.S
index 9c982cdec3cf..f560f83a3ab0 100644
--- a/arch/powerpc/lib/copyuser_power7.S
+++ b/arch/powerpc/lib/copyuser_power7.S
@@ -61,7 +61,7 @@
61 ld r15,STK_REG(r15)(r1) 61 ld r15,STK_REG(r15)(r1)
62 ld r14,STK_REG(r14)(r1) 62 ld r14,STK_REG(r14)(r1)
63.Ldo_err3: 63.Ldo_err3:
64 bl .exit_vmx_copy 64 bl .exit_vmx_usercopy
65 ld r0,STACKFRAMESIZE+16(r1) 65 ld r0,STACKFRAMESIZE+16(r1)
66 mtlr r0 66 mtlr r0
67 b .Lexit 67 b .Lexit
@@ -290,7 +290,7 @@ err1; stb r0,0(r3)
290 mflr r0 290 mflr r0
291 std r0,16(r1) 291 std r0,16(r1)
292 stdu r1,-STACKFRAMESIZE(r1) 292 stdu r1,-STACKFRAMESIZE(r1)
293 bl .enter_vmx_copy 293 bl .enter_vmx_usercopy
294 cmpwi r3,0 294 cmpwi r3,0
295 ld r0,STACKFRAMESIZE+16(r1) 295 ld r0,STACKFRAMESIZE+16(r1)
296 ld r3,STACKFRAMESIZE+48(r1) 296 ld r3,STACKFRAMESIZE+48(r1)
@@ -507,7 +507,7 @@ err3; lbz r0,0(r4)
507err3; stb r0,0(r3) 507err3; stb r0,0(r3)
508 508
50915: addi r1,r1,STACKFRAMESIZE 50915: addi r1,r1,STACKFRAMESIZE
510 b .exit_vmx_copy /* tail call optimise */ 510 b .exit_vmx_usercopy /* tail call optimise */
511 511
512.Lvmx_unaligned_copy: 512.Lvmx_unaligned_copy:
513 /* Get the destination 16B aligned */ 513 /* Get the destination 16B aligned */
@@ -710,5 +710,5 @@ err3; lbz r0,0(r4)
710err3; stb r0,0(r3) 710err3; stb r0,0(r3)
711 711
71215: addi r1,r1,STACKFRAMESIZE 71215: addi r1,r1,STACKFRAMESIZE
713 b .exit_vmx_copy /* tail call optimise */ 713 b .exit_vmx_usercopy /* tail call optimise */
714#endif /* CONFiG_ALTIVEC */ 714#endif /* CONFiG_ALTIVEC */
diff --git a/arch/powerpc/lib/copyuser_power7_vmx.c b/arch/powerpc/lib/vmx-helper.c
index bf2654f2b68e..753a839f4a14 100644
--- a/arch/powerpc/lib/copyuser_power7_vmx.c
+++ b/arch/powerpc/lib/vmx-helper.c
@@ -22,7 +22,7 @@
22#include <linux/hardirq.h> 22#include <linux/hardirq.h>
23#include <asm/switch_to.h> 23#include <asm/switch_to.h>
24 24
25int enter_vmx_copy(void) 25int enter_vmx_usercopy(void)
26{ 26{
27 if (in_interrupt()) 27 if (in_interrupt())
28 return 0; 28 return 0;
@@ -44,7 +44,7 @@ int enter_vmx_copy(void)
44 * This function must return 0 because we tail call optimise when calling 44 * This function must return 0 because we tail call optimise when calling
45 * from __copy_tofrom_user_power7 which returns 0 on success. 45 * from __copy_tofrom_user_power7 which returns 0 on success.
46 */ 46 */
47int exit_vmx_copy(void) 47int exit_vmx_usercopy(void)
48{ 48{
49 pagefault_enable(); 49 pagefault_enable();
50 return 0; 50 return 0;