From 5c5252bd527a9d0c64fb6e73bbb579077c1b3e39 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sat, 2 Aug 2003 22:31:52 +0000 Subject: Update. 2003-08-02 Ulrich Drepper * sysdeps/pthread/createthread.c (do_clone): Only use sched_setschduler and pass correct parameters. --- nptl/sysdeps/pthread/createthread.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'nptl/sysdeps/pthread') diff --git a/nptl/sysdeps/pthread/createthread.c b/nptl/sysdeps/pthread/createthread.c index 5aa0d89f90..dd5bb5a25b 100644 --- a/nptl/sysdeps/pthread/createthread.c +++ b/nptl/sysdeps/pthread/createthread.c @@ -79,17 +79,11 @@ do_clone (struct pthread *pd, const struct pthread_attr *attr, /* Set the scheduling parameters. */ if ((attr->flags & ATTR_FLAG_NOTINHERITSCHED) != 0) { - res = INTERNAL_SYSCALL (sched_setparam, err, 2, pd->tid, - &pd->schedparam); + res = INTERNAL_SYSCALL (sched_setscheduler, err, 3, pd->tid, + pd->schedpolicy, &pd->schedparam); - if (__builtin_expect (! INTERNAL_SYSCALL_ERROR_P (res, err), 1)) - { - res = INTERNAL_SYSCALL (sched_setscheduler, err, 2, pd->tid, - &pd->schedpolicy); - - if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (res, err), 0)) - goto err_out; - } + if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (res, err), 0)) + goto err_out; } /* Now start the thread for real. */ -- cgit 1.4.1