~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/arch/x86/um/shared/sysdep/ptrace_64.h

Version: ~ [ linux-6.11-rc3 ] ~ [ linux-6.10.4 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.45 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.104 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.164 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.223 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.281 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.319 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.9 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /*
  2  * Copyright 2003 PathScale, Inc.
  3  * Copyright (C) 2003 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
  4  *
  5  * Licensed under the GPL
  6  */
  7 
  8 #ifndef __SYSDEP_X86_64_PTRACE_H
  9 #define __SYSDEP_X86_64_PTRACE_H
 10 
 11 #define MAX_FP_NR HOST_FP_SIZE
 12 
 13 #define REGS_R8(r) ((r)[HOST_R8])
 14 #define REGS_R9(r) ((r)[HOST_R9])
 15 #define REGS_R10(r) ((r)[HOST_R10])
 16 #define REGS_R11(r) ((r)[HOST_R11])
 17 #define REGS_R12(r) ((r)[HOST_R12])
 18 #define REGS_R13(r) ((r)[HOST_R13])
 19 #define REGS_R14(r) ((r)[HOST_R14])
 20 #define REGS_R15(r) ((r)[HOST_R15])
 21 
 22 #define HOST_FS_BASE 21
 23 #define HOST_GS_BASE 22
 24 #define HOST_DS 23
 25 #define HOST_ES 24
 26 #define HOST_FS 25
 27 #define HOST_GS 26
 28 
 29 /* Also defined in asm/ptrace-x86_64.h, but not in libc headers.  So, these
 30  * are already defined for kernel code, but not for userspace code.
 31  */
 32 #ifndef FS_BASE
 33 /* These aren't defined in ptrace.h, but exist in struct user_regs_struct,
 34  * which is what x86_64 ptrace actually uses.
 35  */
 36 #define FS_BASE (HOST_FS_BASE * sizeof(long))
 37 #define GS_BASE (HOST_GS_BASE * sizeof(long))
 38 #define DS (HOST_DS * sizeof(long))
 39 #define ES (HOST_ES * sizeof(long))
 40 #define FS (HOST_FS * sizeof(long))
 41 #define GS (HOST_GS * sizeof(long))
 42 #endif
 43 
 44 #define UPT_R8(r) REGS_R8((r)->gp)
 45 #define UPT_R9(r) REGS_R9((r)->gp)
 46 #define UPT_R10(r) REGS_R10((r)->gp)
 47 #define UPT_R11(r) REGS_R11((r)->gp)
 48 #define UPT_R12(r) REGS_R12((r)->gp)
 49 #define UPT_R13(r) REGS_R13((r)->gp)
 50 #define UPT_R14(r) REGS_R14((r)->gp)
 51 #define UPT_R15(r) REGS_R15((r)->gp)
 52 
 53 #define UPT_SYSCALL_ARG1(r) UPT_DI(r)
 54 #define UPT_SYSCALL_ARG2(r) UPT_SI(r)
 55 #define UPT_SYSCALL_ARG3(r) UPT_DX(r)
 56 #define UPT_SYSCALL_ARG4(r) UPT_R10(r)
 57 #define UPT_SYSCALL_ARG5(r) UPT_R8(r)
 58 #define UPT_SYSCALL_ARG6(r) UPT_R9(r)
 59 
 60 extern void arch_init_registers(int pid);
 61 
 62 #endif
 63 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php