aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/kernel/ptrace.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/kernel/ptrace.c')
-rw-r--r--arch/arm/kernel/ptrace.c28
1 files changed, 15 insertions, 13 deletions
diff --git a/arch/arm/kernel/ptrace.c b/arch/arm/kernel/ptrace.c
index e0cb6370ed14..3e97483abcf0 100644
--- a/arch/arm/kernel/ptrace.c
+++ b/arch/arm/kernel/ptrace.c
@@ -1075,13 +1075,15 @@ out:
1075} 1075}
1076#endif 1076#endif
1077 1077
1078long arch_ptrace(struct task_struct *child, long request, long addr, long data) 1078long arch_ptrace(struct task_struct *child, long request,
1079 unsigned long addr, unsigned long data)
1079{ 1080{
1080 int ret; 1081 int ret;
1082 unsigned long __user *datap = (unsigned long __user *) data;
1081 1083
1082 switch (request) { 1084 switch (request) {
1083 case PTRACE_PEEKUSR: 1085 case PTRACE_PEEKUSR:
1084 ret = ptrace_read_user(child, addr, (unsigned long __user *)data); 1086 ret = ptrace_read_user(child, addr, datap);
1085 break; 1087 break;
1086 1088
1087 case PTRACE_POKEUSR: 1089 case PTRACE_POKEUSR:
@@ -1089,34 +1091,34 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data)
1089 break; 1091 break;
1090 1092
1091 case PTRACE_GETREGS: 1093 case PTRACE_GETREGS:
1092 ret = ptrace_getregs(child, (void __user *)data); 1094 ret = ptrace_getregs(child, datap);
1093 break; 1095 break;
1094 1096
1095 case PTRACE_SETREGS: 1097 case PTRACE_SETREGS:
1096 ret = ptrace_setregs(child, (void __user *)data); 1098 ret = ptrace_setregs(child, datap);
1097 break; 1099 break;
1098 1100
1099 case PTRACE_GETFPREGS: 1101 case PTRACE_GETFPREGS:
1100 ret = ptrace_getfpregs(child, (void __user *)data); 1102 ret = ptrace_getfpregs(child, datap);
1101 break; 1103 break;
1102 1104
1103 case PTRACE_SETFPREGS: 1105 case PTRACE_SETFPREGS:
1104 ret = ptrace_setfpregs(child, (void __user *)data); 1106 ret = ptrace_setfpregs(child, datap);
1105 break; 1107 break;
1106 1108
1107#ifdef CONFIG_IWMMXT 1109#ifdef CONFIG_IWMMXT
1108 case PTRACE_GETWMMXREGS: 1110 case PTRACE_GETWMMXREGS:
1109 ret = ptrace_getwmmxregs(child, (void __user *)data); 1111 ret = ptrace_getwmmxregs(child, datap);
1110 break; 1112 break;
1111 1113
1112 case PTRACE_SETWMMXREGS: 1114 case PTRACE_SETWMMXREGS:
1113 ret = ptrace_setwmmxregs(child, (void __user *)data); 1115 ret = ptrace_setwmmxregs(child, datap);
1114 break; 1116 break;
1115#endif 1117#endif
1116 1118
1117 case PTRACE_GET_THREAD_AREA: 1119 case PTRACE_GET_THREAD_AREA:
1118 ret = put_user(task_thread_info(child)->tp_value, 1120 ret = put_user(task_thread_info(child)->tp_value,
1119 (unsigned long __user *) data); 1121 datap);
1120 break; 1122 break;
1121 1123
1122 case PTRACE_SET_SYSCALL: 1124 case PTRACE_SET_SYSCALL:
@@ -1126,21 +1128,21 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data)
1126 1128
1127#ifdef CONFIG_CRUNCH 1129#ifdef CONFIG_CRUNCH
1128 case PTRACE_GETCRUNCHREGS: 1130 case PTRACE_GETCRUNCHREGS:
1129 ret = ptrace_getcrunchregs(child, (void __user *)data); 1131 ret = ptrace_getcrunchregs(child, datap);
1130 break; 1132 break;
1131 1133
1132 case PTRACE_SETCRUNCHREGS: 1134 case PTRACE_SETCRUNCHREGS:
1133 ret = ptrace_setcrunchregs(child, (void __user *)data); 1135 ret = ptrace_setcrunchregs(child, datap);
1134 break; 1136 break;
1135#endif 1137#endif
1136 1138
1137#ifdef CONFIG_VFP 1139#ifdef CONFIG_VFP
1138 case PTRACE_GETVFPREGS: 1140 case PTRACE_GETVFPREGS:
1139 ret = ptrace_getvfpregs(child, (void __user *)data); 1141 ret = ptrace_getvfpregs(child, datap);
1140 break; 1142 break;
1141 1143
1142 case PTRACE_SETVFPREGS: 1144 case PTRACE_SETVFPREGS:
1143 ret = ptrace_setvfpregs(child, (void __user *)data); 1145 ret = ptrace_setvfpregs(child, datap);
1144 break; 1146 break;
1145#endif 1147#endif
1146 1148