Skip to content

Commit dc3a7a7

Browse files
davem330gregkh
authored andcommitted
sparc64: Convert NG4copy_{from,to}_user to accurate exception reporting.
[ Upstream commit 95707704800988093a9b9a27e0f2f67f5b4bf2fa ] Report the exact number of bytes which have not been successfully copied when an exception occurs, using the running remaining length. Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 1731d90 commit dc3a7a7

3 files changed

Lines changed: 231 additions & 79 deletions

File tree

arch/sparc/lib/NG4copy_from_user.S

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
* Copyright (C) 2012 David S. Miller (davem@davemloft.net)
44
*/
55

6-
#define EX_LD(x) \
6+
#define EX_LD(x, y) \
77
98: x; \
88
.section __ex_table,"a";\
99
.align 4; \
10-
.word 98b, __retl_mone_asi;\
10+
.word 98b, y; \
1111
.text; \
1212
.align 4;
1313

14-
#define EX_LD_FP(x) \
14+
#define EX_LD_FP(x,y) \
1515
98: x; \
1616
.section __ex_table,"a";\
1717
.align 4; \
18-
.word 98b, __retl_mone_asi_fp;\
18+
.word 98b, y##_fp; \
1919
.text; \
2020
.align 4;
2121

arch/sparc/lib/NG4copy_to_user.S

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@
33
* Copyright (C) 2012 David S. Miller (davem@davemloft.net)
44
*/
55

6-
#define EX_ST(x) \
6+
#define EX_ST(x,y) \
77
98: x; \
88
.section __ex_table,"a";\
99
.align 4; \
10-
.word 98b, __retl_mone_asi;\
10+
.word 98b, y; \
1111
.text; \
1212
.align 4;
1313

14-
#define EX_ST_FP(x) \
14+
#define EX_ST_FP(x,y) \
1515
98: x; \
1616
.section __ex_table,"a";\
1717
.align 4; \
18-
.word 98b, __retl_mone_asi_fp;\
18+
.word 98b, y##_fp; \
1919
.text; \
2020
.align 4;
2121

0 commit comments

Comments
 (0)