aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/lib/csumpartialcopyuser.S
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@arm.com>2009-07-24 07:32:57 -0400
committerCatalin Marinas <catalin.marinas@arm.com>2009-07-24 07:32:57 -0400
commit8b592783a2e8b7721a99730bd549aab5208f36af (patch)
tree468636a17d31f6a29287240c63234e739eabf666 /arch/arm/lib/csumpartialcopyuser.S
parent347c8b70b1d5256e445e54e736f88d21877616cf (diff)
Thumb-2: Implement the unified arch/arm/lib functions
This patch adds the ARM/Thumb-2 unified support for the arch/arm/lib/* files. Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'arch/arm/lib/csumpartialcopyuser.S')
-rw-r--r--arch/arm/lib/csumpartialcopyuser.S48
1 files changed, 13 insertions, 35 deletions
diff --git a/arch/arm/lib/csumpartialcopyuser.S b/arch/arm/lib/csumpartialcopyuser.S
index 14677fb4b0c4..fd0e9dcd9fdc 100644
--- a/arch/arm/lib/csumpartialcopyuser.S
+++ b/arch/arm/lib/csumpartialcopyuser.S
@@ -26,50 +26,28 @@
26 .endm 26 .endm
27 27
28 .macro load1b, reg1 28 .macro load1b, reg1
299999: ldrbt \reg1, [r0], $1 29 ldrusr \reg1, r0, 1
30 .section __ex_table, "a"
31 .align 3
32 .long 9999b, 6001f
33 .previous
34 .endm 30 .endm
35 31
36 .macro load2b, reg1, reg2 32 .macro load2b, reg1, reg2
379999: ldrbt \reg1, [r0], $1 33 ldrusr \reg1, r0, 1
389998: ldrbt \reg2, [r0], $1 34 ldrusr \reg2, r0, 1
39 .section __ex_table, "a"
40 .long 9999b, 6001f
41 .long 9998b, 6001f
42 .previous
43 .endm 35 .endm
44 36
45 .macro load1l, reg1 37 .macro load1l, reg1
469999: ldrt \reg1, [r0], $4 38 ldrusr \reg1, r0, 4
47 .section __ex_table, "a"
48 .align 3
49 .long 9999b, 6001f
50 .previous
51 .endm 39 .endm
52 40
53 .macro load2l, reg1, reg2 41 .macro load2l, reg1, reg2
549999: ldrt \reg1, [r0], $4 42 ldrusr \reg1, r0, 4
559998: ldrt \reg2, [r0], $4 43 ldrusr \reg2, r0, 4
56 .section __ex_table, "a"
57 .long 9999b, 6001f
58 .long 9998b, 6001f
59 .previous
60 .endm 44 .endm
61 45
62 .macro load4l, reg1, reg2, reg3, reg4 46 .macro load4l, reg1, reg2, reg3, reg4
639999: ldrt \reg1, [r0], $4 47 ldrusr \reg1, r0, 4
649998: ldrt \reg2, [r0], $4 48 ldrusr \reg2, r0, 4
659997: ldrt \reg3, [r0], $4 49 ldrusr \reg3, r0, 4
669996: ldrt \reg4, [r0], $4 50 ldrusr \reg4, r0, 4
67 .section __ex_table, "a"
68 .long 9999b, 6001f
69 .long 9998b, 6001f
70 .long 9997b, 6001f
71 .long 9996b, 6001f
72 .previous
73 .endm 51 .endm
74 52
75/* 53/*
@@ -92,14 +70,14 @@
92 */ 70 */
93 .section .fixup,"ax" 71 .section .fixup,"ax"
94 .align 4 72 .align 4
956001: mov r4, #-EFAULT 739001: mov r4, #-EFAULT
96 ldr r5, [fp, #4] @ *err_ptr 74 ldr r5, [fp, #4] @ *err_ptr
97 str r4, [r5] 75 str r4, [r5]
98 ldmia sp, {r1, r2} @ retrieve dst, len 76 ldmia sp, {r1, r2} @ retrieve dst, len
99 add r2, r2, r1 77 add r2, r2, r1
100 mov r0, #0 @ zero the buffer 78 mov r0, #0 @ zero the buffer
1016002: teq r2, r1 799002: teq r2, r1
102 strneb r0, [r1], #1 80 strneb r0, [r1], #1
103 bne 6002b 81 bne 9002b
104 load_regs 82 load_regs
105 .previous 83 .previous