Commit 32cce80f authored by Jan Kiszka's avatar Jan Kiszka

testsuite/smokey: Add pthread_setschedprio to setsched test case

Now that this path goes via an own syscall, better test it.
Signed-off-by: Jan Kiszka's avatarJan Kiszka <jan.kiszka@siemens.com>
parent 23ff1e3f
......@@ -102,6 +102,27 @@ static void *thread_body(void *arg)
check_linux_schedparams(SCHED_FIFO, 2);
cobalt_thread_harden();
#ifdef CONFIG_XENO_LAZY_SETSCHED
if (smokey_check_status(cobalt_thread_stat(thread_pid, &stats)))
pthread_exit((void *)(long)-EINVAL);
msw = stats.msw;
#endif
if (smokey_check_status(pthread_setschedprio(pthread_self(), 3)))
pthread_exit((void *)(long)-EINVAL);
check_rt_schedparams(SCHED_FIFO, 3);
#ifdef CONFIG_XENO_LAZY_SETSCHED
if (smokey_check_status(cobalt_thread_stat(thread_pid, &stats)) ||
!smokey_assert(stats.msw == msw))
pthread_exit((void *)(long)-EINVAL);
#endif
check_linux_schedparams(SCHED_FIFO, 3);
return (void *)0L;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment