Pull up following revision(s) (requested by riastradh in ticket #1711):
external/cddl/osnet/sys/kern/misc.c: revision 1.10 external/cddl/osnet/sys/sys/proc.h: revision 1.10 solaris: Give threads less bad names.
This commit is contained in:
parent
3db6beb8a5
commit
a51c9ac1d9
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: misc.c,v 1.5.4.1 2020/02/25 20:03:12 martin Exp $ */
|
||||
/* $NetBSD: misc.c,v 1.5.4.2 2023/08/09 17:25:00 martin Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2009 The NetBSD Foundation, Inc.
|
||||
|
@ -94,8 +94,8 @@ vn_is_readonly(vnode_t *vp)
|
|||
}
|
||||
|
||||
kthread_t *
|
||||
thread_create(void * stk, size_t stksize, void (*proc)(), void *arg,
|
||||
size_t len, proc_t *pp, int state, pri_t pri)
|
||||
solaris__thread_create(void * stk, size_t stksize, void (*proc)(), void *arg,
|
||||
size_t len, proc_t *pp, int state, pri_t pri, const char *name)
|
||||
{
|
||||
int error;
|
||||
lwp_t *thr;
|
||||
|
@ -105,7 +105,7 @@ thread_create(void * stk, size_t stksize, void (*proc)(), void *arg,
|
|||
ASSERT(state == TS_RUN);
|
||||
|
||||
error = kthread_create(pri, KTHREAD_MPSAFE, NULL,
|
||||
proc, arg, &thr, "zfs");
|
||||
proc, arg, &thr, "%s", name);
|
||||
KASSERT(error == 0);
|
||||
return thr;
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: proc.h,v 1.9 2018/11/15 04:55:26 riastradh Exp $ */
|
||||
/* $NetBSD: proc.h,v 1.9.2.1 2023/08/09 17:25:00 martin Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2009 The NetBSD Foundation, Inc.
|
||||
|
@ -89,8 +89,11 @@ typedef struct lwp *kthread_id_t;
|
|||
struct contract {
|
||||
};
|
||||
|
||||
kthread_t *thread_create(void *, size_t, void (*)(void *), void *, size_t,
|
||||
proc_t *, int, pri_t);
|
||||
#define thread_create(stk, stksz, proc, arg, len, pp, state, pri) \
|
||||
solaris__thread_create(stk, stksz, proc, arg, len, pp, state, pri, \
|
||||
#proc)
|
||||
kthread_t *solaris__thread_create(void *, size_t, void (*)(void *), void *,
|
||||
size_t, proc_t *, int, pri_t, const char *);
|
||||
void thread_exit(void);
|
||||
void thread_join(uint64_t);
|
||||
|
||||
|
|
Loading…
Reference in New Issue