pthread_setschedparam (SCHED_FIFO) fails

In ubuntu (Linux version 4.4.38 - tegra (buildbrain @ mobile - u64 - 773)) provided by jetpack 3.2.1, setting of SCHED_FIFO by pthread_setschedparam () now causes an error (errorno==1). In previous ubuntu provided by jetpack (Linux version 4.4.38 - tegra (buildbrain @ mobile - u64 - 753)), we did not make an error.
Has it been possible to limit the use of SCHED_FIFO?

1 Like

It’s kernel native function shouldn’t have any different.
Could you share how you get the fails. Attached the test source and binary should be good.

OK.

Source files, makefiles, binaries and logs on success, binaries and logs on failure were prepared in github.

[url]https://github.com/MiharuCommunications/tst_schedset[/url]

Correspondence, thank you.
How is the survey situation?

Please try this command before run the APP.

sysctl -w kernel.sched_rt_runtime_us=-1

Advice, thank you.
After executing the presented command, i was able to success that setting of FIFO_SCHED was done.

How can I set SCHED_FIFO with kernel.sched_rt_runtime_us=950000? I want to use SCHED_FIFO and set a realtime limit.

Like @nathan_at_overwatch, I would also like to use SCHED_FIFO without setting kernel.sched_rt_runtime_us=-1, could anyone shed some like on why it seems required now?