diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -256,7 +256,7 @@ * module. Finally, it allows for optional "kernel threads". */ void -mi_startup(void) +mi_startup(void) __nosanitizekcfi { struct sysinit *sip; int last; diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c --- a/sys/kern/kern_fork.c +++ b/sys/kern/kern_fork.c @@ -1163,8 +1163,8 @@ * is called from the MD fork_trampoline() entry point. */ void -fork_exit(void (*callout)(void *, struct trapframe *), void *arg, - struct trapframe *frame) +fork_exit(void (*callout)(struct thread *, struct trapframe *), void *arg, + struct trapframe *frame) __nosanitizekcfi { struct proc *p; struct thread *td; diff --git a/sys/kern/kern_intr.c b/sys/kern/kern_intr.c --- a/sys/kern/kern_intr.c +++ b/sys/kern/kern_intr.c @@ -1195,7 +1195,7 @@ } static void -ithread_execute_handlers(struct proc *p, struct intr_event *ie) +ithread_execute_handlers(struct proc *p, struct intr_event *ie) __nosanitizekcfi { /* Only specifically marked sleepable interrupt handlers can sleep. */ @@ -1342,7 +1342,7 @@ * o EINVAL: stray interrupt. */ int -intr_event_handle(struct intr_event *ie, struct trapframe *frame) +intr_event_handle(struct intr_event *ie, struct trapframe *frame) __nosanitizekcfi { struct intr_handler *ih; struct trapframe *oldframe; diff --git a/sys/kern/subr_epoch.c b/sys/kern/subr_epoch.c --- a/sys/kern/subr_epoch.c +++ b/sys/kern/subr_epoch.c @@ -801,7 +801,7 @@ } static void -epoch_call_task(void *arg __unused) +epoch_call_task(void *arg __unused) __nosanitizekcfi { ck_stack_entry_t *cursor, *head, *next; ck_epoch_record_t *record; diff --git a/sys/kern/subr_pctrie.c b/sys/kern/subr_pctrie.c --- a/sys/kern/subr_pctrie.c +++ b/sys/kern/subr_pctrie.c @@ -971,7 +971,7 @@ */ static __always_inline struct pctrie_node * pctrie_reclaim_prune(struct pctrie_node **pnode, struct pctrie_node *parent, - pctrie_cb_t callback, int keyoff, void *arg) + pctrie_cb_t callback, int keyoff, void *arg) __nosanitizekcfi { struct pctrie_node *child, *node; int slot; @@ -1001,8 +1001,8 @@ * Recover the node parent from its first child and continue pruning. */ static __always_inline struct pctrie_node * -pctrie_reclaim_resume_compound(struct pctrie_node **pnode, - pctrie_cb_t callback, int keyoff, void *arg) +pctrie_reclaim_resume_compound(struct pctrie_node **pnode, pctrie_cb_t callback, + int keyoff, void *arg) __nosanitizekcfi { if (*pnode == NULL) return (NULL); @@ -1015,9 +1015,8 @@ * Find the trie root, and start pruning with a NULL parent. */ static __always_inline struct pctrie_node * -pctrie_reclaim_begin_compound(struct pctrie_node **pnode, - struct pctrie *ptree, - pctrie_cb_t callback, int keyoff, void *arg) +pctrie_reclaim_begin_compound(struct pctrie_node **pnode, struct pctrie *ptree, + pctrie_cb_t callback, int keyoff, void *arg) __nosanitizekcfi { struct pctrie_node *node; diff --git a/sys/kern/subr_scanf.c b/sys/kern/subr_scanf.c --- a/sys/kern/subr_scanf.c +++ b/sys/kern/subr_scanf.c @@ -95,7 +95,7 @@ } int -vsscanf(const char *inp, char const *fmt0, va_list ap) +vsscanf(const char *inp, char const *fmt0, va_list ap) __nosanitizekcfi { int inr; const u_char *fmt = (const u_char *)fmt0; diff --git a/sys/kern/subr_syscall.c b/sys/kern/subr_syscall.c --- a/sys/kern/subr_syscall.c +++ b/sys/kern/subr_syscall.c @@ -50,7 +50,7 @@ #include static inline void -syscallenter(struct thread *td) +syscallenter(struct thread *td) __nosanitizekcfi { struct proc *p; struct syscall_args *sa; diff --git a/sys/net/radix.c b/sys/net/radix.c --- a/sys/net/radix.c +++ b/sys/net/radix.c @@ -1055,7 +1055,7 @@ } int -rn_walktree(struct radix_head *h, walktree_f_t *f, void *w) +rn_walktree(struct radix_head *h, walktree_f_t *f, void *w) __nosanitizekcfi { int error; struct radix_node *base, *next; diff --git a/sys/net/vnet.c b/sys/net/vnet.c --- a/sys/net/vnet.c +++ b/sys/net/vnet.c @@ -517,7 +517,7 @@ * and VNET_SYSUNINIT(). */ void -vnet_register_sysinit(void *arg) +vnet_register_sysinit(void *arg) __nosanitizekcfi { struct vnet_sysinit *vs, *vs2; struct vnet *vnet; diff --git a/sys/sys/proc.h b/sys/sys/proc.h --- a/sys/sys/proc.h +++ b/sys/sys/proc.h @@ -1163,7 +1163,7 @@ struct session *sess); int enterthispgrp(struct proc *p, struct pgrp *pgrp); int fork1(struct thread *, struct fork_req *); -void fork_exit(void (*)(void *, struct trapframe *), void *, +void fork_exit(void (*)(struct thread *, struct trapframe *), void *, struct trapframe *); void fork_return(struct thread *, struct trapframe *); int inferior(struct proc *p); diff --git a/sys/sys/systm.h b/sys/sys/systm.h --- a/sys/sys/systm.h +++ b/sys/sys/systm.h @@ -142,7 +142,6 @@ int setjmp(struct _jmp_buf *) __returns_twice; void longjmp(struct _jmp_buf *, int) __dead2; int dumpstatus(vm_offset_t addr, off_t count); -int nullop(void); int eopnotsupp(void); int ureadc(int, struct uio *); void hashdestroy(void *, struct malloc_type *, u_long); diff --git a/sys/tools/vnode_if.awk b/sys/tools/vnode_if.awk --- a/sys/tools/vnode_if.awk +++ b/sys/tools/vnode_if.awk @@ -395,7 +395,7 @@ printc(""); printc("\treturn(" uname "_APV(a->a_" args[0] "->v_op, a));"); printc("}"); - printc("\nint\n" uname "_APV(const struct vop_vector *vop, struct " name "_args *a)"); + printc("\nint\n" uname "_APV(const struct vop_vector *vop, struct " name "_args *a) __nosanitizekcfi"); printc("{"); printc("\tint rc;"); printc("");