path: root/sys/sys/proc.h
diff options
authorKonstantin Belousov <kib@FreeBSD.org>2019-03-16 11:31:01 +0000
committerKonstantin Belousov <kib@FreeBSD.org>2019-03-16 11:31:01 +0000
commit6f1fe3305a2be0a1395569b2ea5f56a93e491ae0 (patch)
treea4dc6f513504def0942459570f83fe798336d04e /sys/sys/proc.h
parentc1c120b2cb8ece606766642dc20bff611fa89d22 (diff)
amd64: Add md process flags and first P_MD_PTI flag.
PTI mode for the process pmap on exec is activated iff P_MD_PTI is set. On exec, the existing vmspace can be reused only if pti mode of the pmap matches the P_MD_PTI flag of the process. Add MD cpu_exec_vmspace_reuse() callback for exec_new_vmspace() which can vetoed reuse of the existing vmspace. MFC note: md_flags change struct proc KBI. Reviewed by: jhb, markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D19514
Notes: svn path=/head/; revision=345227
Diffstat (limited to 'sys/sys/proc.h')
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/sys/proc.h b/sys/sys/proc.h
index b2f75f921ec5..2d71a72e4d2c 100644
--- a/sys/sys/proc.h
+++ b/sys/sys/proc.h
@@ -1093,6 +1093,7 @@ void userret(struct thread *, struct trapframe *);
void cpu_exit(struct thread *);
void exit1(struct thread *, int, int) __dead2;
void cpu_copy_thread(struct thread *td, struct thread *td0);
+bool cpu_exec_vmspace_reuse(struct proc *p, struct vm_map *map);
int cpu_fetch_syscall_args(struct thread *td);
void cpu_fork(struct thread *, struct proc *, struct thread *, int);
void cpu_fork_kthread_handler(struct thread *, void (*)(void *), void *);