mirror of
				git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
				synced 2025-09-04 20:19:47 +08:00 
			
		
		
		
	 457677c70c
			
		
	
	
		457677c70c
		
			
		
	
	
	
	
		
			
			This is required for clone3 which passes the TLS value through a struct rather than a register. Signed-off-by: Amanieu d'Antras <amanieu@gmail.com> Cc: linux-um@lists.infradead.org Cc: <stable@vger.kernel.org> # 5.3.x Link: https://lore.kernel.org/r/20200104123928.1048822-1-amanieu@gmail.com Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
		
			
				
	
	
		
			47 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			47 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
| /* SPDX-License-Identifier: GPL-2.0 */
 | |
| /* 
 | |
|  * Copyright (C) 2000 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
 | |
|  */
 | |
| 
 | |
| #ifndef __UM_PTRACE_GENERIC_H
 | |
| #define __UM_PTRACE_GENERIC_H
 | |
| 
 | |
| #ifndef __ASSEMBLY__
 | |
| 
 | |
| #include <sysdep/ptrace.h>
 | |
| 
 | |
| struct pt_regs {
 | |
| 	struct uml_pt_regs regs;
 | |
| };
 | |
| 
 | |
| #define arch_has_single_step()	(1)
 | |
| 
 | |
| #define EMPTY_REGS { .regs = EMPTY_UML_PT_REGS }
 | |
| 
 | |
| #define PT_REGS_IP(r) UPT_IP(&(r)->regs)
 | |
| #define PT_REGS_SP(r) UPT_SP(&(r)->regs)
 | |
| 
 | |
| #define PT_REGS_RESTART_SYSCALL(r) UPT_RESTART_SYSCALL(&(r)->regs)
 | |
| 
 | |
| #define PT_REGS_SYSCALL_NR(r) UPT_SYSCALL_NR(&(r)->regs)
 | |
| 
 | |
| #define instruction_pointer(regs) PT_REGS_IP(regs)
 | |
| 
 | |
| #define PTRACE_OLDSETOPTIONS 21
 | |
| 
 | |
| struct task_struct;
 | |
| 
 | |
| extern long subarch_ptrace(struct task_struct *child, long request,
 | |
| 	unsigned long addr, unsigned long data);
 | |
| extern unsigned long getreg(struct task_struct *child, int regno);
 | |
| extern int putreg(struct task_struct *child, int regno, unsigned long value);
 | |
| 
 | |
| extern int arch_set_tls(struct task_struct *new, unsigned long tls);
 | |
| extern void clear_flushed_tls(struct task_struct *task);
 | |
| extern int syscall_trace_enter(struct pt_regs *regs);
 | |
| extern void syscall_trace_leave(struct pt_regs *regs);
 | |
| 
 | |
| #endif
 | |
| 
 | |
| #endif
 |