18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ 28c2ecf20Sopenharmony_ci#ifndef _UAPI_M68K_PTRACE_H 38c2ecf20Sopenharmony_ci#define _UAPI_M68K_PTRACE_H 48c2ecf20Sopenharmony_ci 58c2ecf20Sopenharmony_ci#define PT_D1 0 68c2ecf20Sopenharmony_ci#define PT_D2 1 78c2ecf20Sopenharmony_ci#define PT_D3 2 88c2ecf20Sopenharmony_ci#define PT_D4 3 98c2ecf20Sopenharmony_ci#define PT_D5 4 108c2ecf20Sopenharmony_ci#define PT_D6 5 118c2ecf20Sopenharmony_ci#define PT_D7 6 128c2ecf20Sopenharmony_ci#define PT_A0 7 138c2ecf20Sopenharmony_ci#define PT_A1 8 148c2ecf20Sopenharmony_ci#define PT_A2 9 158c2ecf20Sopenharmony_ci#define PT_A3 10 168c2ecf20Sopenharmony_ci#define PT_A4 11 178c2ecf20Sopenharmony_ci#define PT_A5 12 188c2ecf20Sopenharmony_ci#define PT_A6 13 198c2ecf20Sopenharmony_ci#define PT_D0 14 208c2ecf20Sopenharmony_ci#define PT_USP 15 218c2ecf20Sopenharmony_ci#define PT_ORIG_D0 16 228c2ecf20Sopenharmony_ci#define PT_SR 17 238c2ecf20Sopenharmony_ci#define PT_PC 18 248c2ecf20Sopenharmony_ci 258c2ecf20Sopenharmony_ci#ifndef __ASSEMBLY__ 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_ci/* this struct defines the way the registers are stored on the 288c2ecf20Sopenharmony_ci stack during a system call. */ 298c2ecf20Sopenharmony_ci 308c2ecf20Sopenharmony_cistruct pt_regs { 318c2ecf20Sopenharmony_ci long d1; 328c2ecf20Sopenharmony_ci long d2; 338c2ecf20Sopenharmony_ci long d3; 348c2ecf20Sopenharmony_ci long d4; 358c2ecf20Sopenharmony_ci long d5; 368c2ecf20Sopenharmony_ci long a0; 378c2ecf20Sopenharmony_ci long a1; 388c2ecf20Sopenharmony_ci long a2; 398c2ecf20Sopenharmony_ci long d0; 408c2ecf20Sopenharmony_ci long orig_d0; 418c2ecf20Sopenharmony_ci long stkadj; 428c2ecf20Sopenharmony_ci#ifdef CONFIG_COLDFIRE 438c2ecf20Sopenharmony_ci unsigned format : 4; /* frame format specifier */ 448c2ecf20Sopenharmony_ci unsigned vector : 12; /* vector offset */ 458c2ecf20Sopenharmony_ci unsigned short sr; 468c2ecf20Sopenharmony_ci unsigned long pc; 478c2ecf20Sopenharmony_ci#else 488c2ecf20Sopenharmony_ci unsigned short sr; 498c2ecf20Sopenharmony_ci unsigned long pc; 508c2ecf20Sopenharmony_ci unsigned format : 4; /* frame format specifier */ 518c2ecf20Sopenharmony_ci unsigned vector : 12; /* vector offset */ 528c2ecf20Sopenharmony_ci#endif 538c2ecf20Sopenharmony_ci}; 548c2ecf20Sopenharmony_ci 558c2ecf20Sopenharmony_ci/* 568c2ecf20Sopenharmony_ci * This is the extended stack used by signal handlers and the context 578c2ecf20Sopenharmony_ci * switcher: it's pushed after the normal "struct pt_regs". 588c2ecf20Sopenharmony_ci */ 598c2ecf20Sopenharmony_cistruct switch_stack { 608c2ecf20Sopenharmony_ci unsigned long d6; 618c2ecf20Sopenharmony_ci unsigned long d7; 628c2ecf20Sopenharmony_ci unsigned long a3; 638c2ecf20Sopenharmony_ci unsigned long a4; 648c2ecf20Sopenharmony_ci unsigned long a5; 658c2ecf20Sopenharmony_ci unsigned long a6; 668c2ecf20Sopenharmony_ci unsigned long retpc; 678c2ecf20Sopenharmony_ci}; 688c2ecf20Sopenharmony_ci 698c2ecf20Sopenharmony_ci/* Arbitrarily choose the same ptrace numbers as used by the Sparc code. */ 708c2ecf20Sopenharmony_ci#define PTRACE_GETREGS 12 718c2ecf20Sopenharmony_ci#define PTRACE_SETREGS 13 728c2ecf20Sopenharmony_ci#define PTRACE_GETFPREGS 14 738c2ecf20Sopenharmony_ci#define PTRACE_SETFPREGS 15 748c2ecf20Sopenharmony_ci 758c2ecf20Sopenharmony_ci#define PTRACE_GET_THREAD_AREA 25 768c2ecf20Sopenharmony_ci 778c2ecf20Sopenharmony_ci#define PTRACE_SINGLEBLOCK 33 /* resume execution until next branch */ 788c2ecf20Sopenharmony_ci 798c2ecf20Sopenharmony_ci#endif /* __ASSEMBLY__ */ 808c2ecf20Sopenharmony_ci#endif /* _UAPI_M68K_PTRACE_H */ 81