aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/include/sysdep-x86_64
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2007-10-16 04:27:08 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-16 12:43:06 -0400
commit8ca842c4b5cbc70b9180617e9f26b6ac9f40dbb9 (patch)
treefe3e4deeae82c7063a72ecb3fdcae47422d6de0e /arch/um/include/sysdep-x86_64
parent28078e8f9790be0854a54f06de822689ab571944 (diff)
uml: remove os_* usage from userspace files
This patch fixes some userspace files which were calling libc through the os_* wrappers. It turns out that there was only one user of os_new_tty_pgrp, so it can be deleted. There are also some style and whitespace fixes in here. Signed-off-by: Jeff Dike <jdike@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/include/sysdep-x86_64')
-rw-r--r--arch/um/include/sysdep-x86_64/ptrace.h152
1 files changed, 76 insertions, 76 deletions
diff --git a/arch/um/include/sysdep-x86_64/ptrace.h b/arch/um/include/sysdep-x86_64/ptrace.h
index ebc2fd5dc31c..2ae04480ac81 100644
--- a/arch/um/include/sysdep-x86_64/ptrace.h
+++ b/arch/um/include/sysdep-x86_64/ptrace.h
@@ -143,87 +143,87 @@ struct syscall_args {
143}; 143};
144 144
145#define SYSCALL_ARGS(r) ((struct syscall_args) \ 145#define SYSCALL_ARGS(r) ((struct syscall_args) \
146 { .args = { UPT_SYSCALL_ARG1(r), \ 146 { .args = { UPT_SYSCALL_ARG1(r), \
147 UPT_SYSCALL_ARG2(r), \ 147 UPT_SYSCALL_ARG2(r), \
148 UPT_SYSCALL_ARG3(r), \ 148 UPT_SYSCALL_ARG3(r), \
149 UPT_SYSCALL_ARG4(r), \ 149 UPT_SYSCALL_ARG4(r), \
150 UPT_SYSCALL_ARG5(r), \ 150 UPT_SYSCALL_ARG5(r), \
151 UPT_SYSCALL_ARG6(r) } } ) 151 UPT_SYSCALL_ARG6(r) } } )
152 152
153#define UPT_REG(regs, reg) \ 153#define UPT_REG(regs, reg) \
154 ({ unsigned long val; \ 154 ({ unsigned long val; \
155 switch(reg){ \ 155 switch(reg){ \
156 case R8: val = UPT_R8(regs); break; \ 156 case R8: val = UPT_R8(regs); break; \
157 case R9: val = UPT_R9(regs); break; \ 157 case R9: val = UPT_R9(regs); break; \
158 case R10: val = UPT_R10(regs); break; \ 158 case R10: val = UPT_R10(regs); break; \
159 case R11: val = UPT_R11(regs); break; \ 159 case R11: val = UPT_R11(regs); break; \
160 case R12: val = UPT_R12(regs); break; \ 160 case R12: val = UPT_R12(regs); break; \
161 case R13: val = UPT_R13(regs); break; \ 161 case R13: val = UPT_R13(regs); break; \
162 case R14: val = UPT_R14(regs); break; \ 162 case R14: val = UPT_R14(regs); break; \
163 case R15: val = UPT_R15(regs); break; \ 163 case R15: val = UPT_R15(regs); break; \
164 case RIP: val = UPT_IP(regs); break; \ 164 case RIP: val = UPT_IP(regs); break; \
165 case RSP: val = UPT_SP(regs); break; \ 165 case RSP: val = UPT_SP(regs); break; \
166 case RAX: val = UPT_RAX(regs); break; \ 166 case RAX: val = UPT_RAX(regs); break; \
167 case RBX: val = UPT_RBX(regs); break; \ 167 case RBX: val = UPT_RBX(regs); break; \
168 case RCX: val = UPT_RCX(regs); break; \ 168 case RCX: val = UPT_RCX(regs); break; \
169 case RDX: val = UPT_RDX(regs); break; \ 169 case RDX: val = UPT_RDX(regs); break; \
170 case RSI: val = UPT_RSI(regs); break; \ 170 case RSI: val = UPT_RSI(regs); break; \
171 case RDI: val = UPT_RDI(regs); break; \ 171 case RDI: val = UPT_RDI(regs); break; \
172 case RBP: val = UPT_RBP(regs); break; \ 172 case RBP: val = UPT_RBP(regs); break; \
173 case ORIG_RAX: val = UPT_ORIG_RAX(regs); break; \ 173 case ORIG_RAX: val = UPT_ORIG_RAX(regs); break; \
174 case CS: val = UPT_CS(regs); break; \ 174 case CS: val = UPT_CS(regs); break; \
175 case SS: val = UPT_SS(regs); break; \ 175 case SS: val = UPT_SS(regs); break; \
176 case FS_BASE: val = UPT_FS_BASE(regs); break; \ 176 case FS_BASE: val = UPT_FS_BASE(regs); break; \
177 case GS_BASE: val = UPT_GS_BASE(regs); break; \ 177 case GS_BASE: val = UPT_GS_BASE(regs); break; \
178 case DS: val = UPT_DS(regs); break; \ 178 case DS: val = UPT_DS(regs); break; \
179 case ES: val = UPT_ES(regs); break; \ 179 case ES: val = UPT_ES(regs); break; \
180 case FS : val = UPT_FS (regs); break; \ 180 case FS : val = UPT_FS (regs); break; \
181 case GS: val = UPT_GS(regs); break; \ 181 case GS: val = UPT_GS(regs); break; \
182 case EFLAGS: val = UPT_EFLAGS(regs); break; \ 182 case EFLAGS: val = UPT_EFLAGS(regs); break; \
183 default : \ 183 default : \
184 panic("Bad register in UPT_REG : %d\n", reg); \ 184 panic("Bad register in UPT_REG : %d\n", reg); \
185 val = -1; \ 185 val = -1; \
186 } \ 186 } \
187 val; \ 187 val; \
188 }) 188 })
189 189
190 190
191#define UPT_SET(regs, reg, val) \ 191#define UPT_SET(regs, reg, val) \
192 ({ unsigned long __upt_val = val; \ 192 ({ unsigned long __upt_val = val; \
193 switch(reg){ \ 193 switch(reg){ \
194 case R8: UPT_R8(regs) = __upt_val; break; \ 194 case R8: UPT_R8(regs) = __upt_val; break; \
195 case R9: UPT_R9(regs) = __upt_val; break; \ 195 case R9: UPT_R9(regs) = __upt_val; break; \
196 case R10: UPT_R10(regs) = __upt_val; break; \ 196 case R10: UPT_R10(regs) = __upt_val; break; \
197 case R11: UPT_R11(regs) = __upt_val; break; \ 197 case R11: UPT_R11(regs) = __upt_val; break; \
198 case R12: UPT_R12(regs) = __upt_val; break; \ 198 case R12: UPT_R12(regs) = __upt_val; break; \
199 case R13: UPT_R13(regs) = __upt_val; break; \ 199 case R13: UPT_R13(regs) = __upt_val; break; \
200 case R14: UPT_R14(regs) = __upt_val; break; \ 200 case R14: UPT_R14(regs) = __upt_val; break; \
201 case R15: UPT_R15(regs) = __upt_val; break; \ 201 case R15: UPT_R15(regs) = __upt_val; break; \
202 case RIP: UPT_IP(regs) = __upt_val; break; \ 202 case RIP: UPT_IP(regs) = __upt_val; break; \
203 case RSP: UPT_SP(regs) = __upt_val; break; \ 203 case RSP: UPT_SP(regs) = __upt_val; break; \
204 case RAX: UPT_RAX(regs) = __upt_val; break; \ 204 case RAX: UPT_RAX(regs) = __upt_val; break; \
205 case RBX: UPT_RBX(regs) = __upt_val; break; \ 205 case RBX: UPT_RBX(regs) = __upt_val; break; \
206 case RCX: UPT_RCX(regs) = __upt_val; break; \ 206 case RCX: UPT_RCX(regs) = __upt_val; break; \
207 case RDX: UPT_RDX(regs) = __upt_val; break; \ 207 case RDX: UPT_RDX(regs) = __upt_val; break; \
208 case RSI: UPT_RSI(regs) = __upt_val; break; \ 208 case RSI: UPT_RSI(regs) = __upt_val; break; \
209 case RDI: UPT_RDI(regs) = __upt_val; break; \ 209 case RDI: UPT_RDI(regs) = __upt_val; break; \
210 case RBP: UPT_RBP(regs) = __upt_val; break; \ 210 case RBP: UPT_RBP(regs) = __upt_val; break; \
211 case ORIG_RAX: UPT_ORIG_RAX(regs) = __upt_val; break; \ 211 case ORIG_RAX: UPT_ORIG_RAX(regs) = __upt_val; break; \
212 case CS: UPT_CS(regs) = __upt_val; break; \ 212 case CS: UPT_CS(regs) = __upt_val; break; \
213 case SS: UPT_SS(regs) = __upt_val; break; \ 213 case SS: UPT_SS(regs) = __upt_val; break; \
214 case FS_BASE: UPT_FS_BASE(regs) = __upt_val; break; \ 214 case FS_BASE: UPT_FS_BASE(regs) = __upt_val; break; \
215 case GS_BASE: UPT_GS_BASE(regs) = __upt_val; break; \ 215 case GS_BASE: UPT_GS_BASE(regs) = __upt_val; break; \
216 case DS: UPT_DS(regs) = __upt_val; break; \ 216 case DS: UPT_DS(regs) = __upt_val; break; \
217 case ES: UPT_ES(regs) = __upt_val; break; \ 217 case ES: UPT_ES(regs) = __upt_val; break; \
218 case FS: UPT_FS(regs) = __upt_val; break; \ 218 case FS: UPT_FS(regs) = __upt_val; break; \
219 case GS: UPT_GS(regs) = __upt_val; break; \ 219 case GS: UPT_GS(regs) = __upt_val; break; \
220 case EFLAGS: UPT_EFLAGS(regs) = __upt_val; break; \ 220 case EFLAGS: UPT_EFLAGS(regs) = __upt_val; break; \
221 default : \ 221 default : \
222 panic("Bad register in UPT_SET : %d\n", reg); \ 222 panic("Bad register in UPT_SET : %d\n", reg); \
223 break; \ 223 break; \
224 } \ 224 } \
225 __upt_val; \ 225 __upt_val; \
226 }) 226 })
227 227
228#define UPT_SET_SYSCALL_RETURN(r, res) \ 228#define UPT_SET_SYSCALL_RETURN(r, res) \
229 REGS_SET_SYSCALL_RETURN((r)->regs, (res)) 229 REGS_SET_SYSCALL_RETURN((r)->regs, (res))