diff --git a/sys/kern/init_sysent.c b/sys/kern/init_sysent.c index cb2e37ba7708..70b7de13cc84 100644 --- a/sys/kern/init_sysent.c +++ b/sys/kern/init_sysent.c @@ -495,9 +495,9 @@ struct sysent sysent[] = { { AS(abort2_args), (sy_call_t *)abort2, AUE_NULL, NULL, 0, 0 }, /* 463 = abort2 */ { AS(thr_set_name_args), (sy_call_t *)thr_set_name, AUE_NULL, NULL, 0, 0 }, /* 464 = thr_set_name */ { AS(aio_fsync_args), (sy_call_t *)lkmressys, AUE_NULL, NULL, 0, 0 }, /* 465 = aio_fsync */ - { AS(thr_setscheduler_args), (sy_call_t *)thr_setscheduler, AUE_NULL, NULL, 0, 0 }, /* 466 = thr_setscheduler */ - { AS(thr_getscheduler_args), (sy_call_t *)thr_getscheduler, AUE_NULL, NULL, 0, 0 }, /* 467 = thr_getscheduler */ - { AS(thr_setschedparam_args), (sy_call_t *)thr_setschedparam, AUE_NULL, NULL, 0, 0 }, /* 468 = thr_setschedparam */ + { AS(rtprio_thread_args), (sy_call_t *)rtprio_thread, AUE_RTPRIO, NULL, 0, 0 }, /* 466 = rtprio_thread */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 467 = nosys */ + { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 468 = nosys */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 469 = __getpath_fromfd */ { 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 470 = __getpath_fromaddr */ }; diff --git a/sys/kern/syscalls.c b/sys/kern/syscalls.c index bcb5f7d018cd..c5e0c1b4f066 100644 --- a/sys/kern/syscalls.c +++ b/sys/kern/syscalls.c @@ -473,9 +473,9 @@ const char *syscallnames[] = { "abort2", /* 463 = abort2 */ "thr_set_name", /* 464 = thr_set_name */ "aio_fsync", /* 465 = aio_fsync */ - "thr_setscheduler", /* 466 = thr_setscheduler */ - "thr_getscheduler", /* 467 = thr_getscheduler */ - "thr_setschedparam", /* 468 = thr_setschedparam */ + "rtprio_thread", /* 466 = rtprio_thread */ + "#467", /* 467 = nosys */ + "#468", /* 468 = nosys */ "#469", /* 469 = __getpath_fromfd */ "#470", /* 470 = __getpath_fromaddr */ }; diff --git a/sys/kern/systrace_args.c b/sys/kern/systrace_args.c index 1b40edf41665..8ccd0971d483 100644 --- a/sys/kern/systrace_args.c +++ b/sys/kern/systrace_args.c @@ -2749,32 +2749,12 @@ systrace_args(int sysnum, void *params, u_int64_t *uarg, int *n_args) *n_args = 2; break; } - /* thr_setscheduler */ + /* rtprio_thread */ case 466: { - struct thr_setscheduler_args *p = params; - iarg[0] = p->id; /* long */ - iarg[1] = p->policy; /* int */ - uarg[2] = (intptr_t) p->param; /* const struct sched_param * */ - iarg[3] = p->param_size; /* int */ - *n_args = 4; - break; - } - /* thr_getscheduler */ - case 467: { - struct thr_getscheduler_args *p = params; - iarg[0] = p->id; /* long */ - uarg[1] = (intptr_t) p->policy; /* int * */ - uarg[2] = (intptr_t) p->param; /* struct sched_param * */ - iarg[3] = p->param_size; /* int */ - *n_args = 4; - break; - } - /* thr_setschedparam */ - case 468: { - struct thr_setschedparam_args *p = params; - iarg[0] = p->id; /* long */ - uarg[1] = (intptr_t) p->param; /* const struct sched_param * */ - iarg[2] = p->param_size; /* int */ + struct rtprio_thread_args *p = params; + iarg[0] = p->function; /* int */ + iarg[1] = p->lwpid; /* lwpid_t */ + uarg[2] = (intptr_t) p->rtp; /* struct rtprio * */ *n_args = 3; break; } diff --git a/sys/sys/syscall.h b/sys/sys/syscall.h index 537ee98be8e4..769ba040b895 100644 --- a/sys/sys/syscall.h +++ b/sys/sys/syscall.h @@ -389,7 +389,5 @@ #define SYS_abort2 463 #define SYS_thr_set_name 464 #define SYS_aio_fsync 465 -#define SYS_thr_setscheduler 466 -#define SYS_thr_getscheduler 467 -#define SYS_thr_setschedparam 468 +#define SYS_rtprio_thread 466 #define SYS_MAXSYSCALL 471 diff --git a/sys/sys/syscall.mk b/sys/sys/syscall.mk index a09df716137a..1c83e4c26382 100644 --- a/sys/sys/syscall.mk +++ b/sys/sys/syscall.mk @@ -331,6 +331,4 @@ MIASM = \ abort2.o \ thr_set_name.o \ aio_fsync.o \ - thr_setscheduler.o \ - thr_getscheduler.o \ - thr_setschedparam.o + rtprio_thread.o diff --git a/sys/sys/sysproto.h b/sys/sys/sysproto.h index b5cee56083b4..7fae35aab906 100644 --- a/sys/sys/sysproto.h +++ b/sys/sys/sysproto.h @@ -1446,22 +1446,10 @@ struct aio_fsync_args { char op_l_[PADL_(int)]; int op; char op_r_[PADR_(int)]; char aiocbp_l_[PADL_(struct aiocb *)]; struct aiocb * aiocbp; char aiocbp_r_[PADR_(struct aiocb *)]; }; -struct thr_setscheduler_args { - char id_l_[PADL_(long)]; long id; char id_r_[PADR_(long)]; - char policy_l_[PADL_(int)]; int policy; char policy_r_[PADR_(int)]; - char param_l_[PADL_(const struct sched_param *)]; const struct sched_param * param; char param_r_[PADR_(const struct sched_param *)]; - char param_size_l_[PADL_(int)]; int param_size; char param_size_r_[PADR_(int)]; -}; -struct thr_getscheduler_args { - char id_l_[PADL_(long)]; long id; char id_r_[PADR_(long)]; - char policy_l_[PADL_(int *)]; int * policy; char policy_r_[PADR_(int *)]; - char param_l_[PADL_(struct sched_param *)]; struct sched_param * param; char param_r_[PADR_(struct sched_param *)]; - char param_size_l_[PADL_(int)]; int param_size; char param_size_r_[PADR_(int)]; -}; -struct thr_setschedparam_args { - char id_l_[PADL_(long)]; long id; char id_r_[PADR_(long)]; - char param_l_[PADL_(const struct sched_param *)]; const struct sched_param * param; char param_r_[PADR_(const struct sched_param *)]; - char param_size_l_[PADL_(int)]; int param_size; char param_size_r_[PADR_(int)]; +struct rtprio_thread_args { + char function_l_[PADL_(int)]; int function; char function_r_[PADR_(int)]; + char lwpid_l_[PADL_(lwpid_t)]; lwpid_t lwpid; char lwpid_r_[PADR_(lwpid_t)]; + char rtp_l_[PADL_(struct rtprio *)]; struct rtprio * rtp; char rtp_r_[PADR_(struct rtprio *)]; }; int nosys(struct thread *, struct nosys_args *); void sys_exit(struct thread *, struct sys_exit_args *); @@ -1790,9 +1778,7 @@ int kmq_unlink(struct thread *, struct kmq_unlink_args *); int abort2(struct thread *, struct abort2_args *); int thr_set_name(struct thread *, struct thr_set_name_args *); int aio_fsync(struct thread *, struct aio_fsync_args *); -int thr_setscheduler(struct thread *, struct thr_setscheduler_args *); -int thr_getscheduler(struct thread *, struct thr_getscheduler_args *); -int thr_setschedparam(struct thread *, struct thr_setschedparam_args *); +int rtprio_thread(struct thread *, struct rtprio_thread_args *); #ifdef COMPAT_43 @@ -2339,9 +2325,7 @@ int freebsd4_sigreturn(struct thread *, struct freebsd4_sigreturn_args *); #define SYS_AUE_abort2 AUE_NULL #define SYS_AUE_thr_set_name AUE_NULL #define SYS_AUE_aio_fsync AUE_NULL -#define SYS_AUE_thr_setscheduler AUE_NULL -#define SYS_AUE_thr_getscheduler AUE_NULL -#define SYS_AUE_thr_setschedparam AUE_NULL +#define SYS_AUE_rtprio_thread AUE_RTPRIO #undef PAD_ #undef PADL_