use RR sched instead of FIFO for Linux RT

This commit is contained in:
Robin Müller 2023-03-23 15:42:14 +01:00
parent 341437df13
commit 33ac395072
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
1 changed files with 2 additions and 2 deletions

View File

@ -179,8 +179,8 @@ void PosixThread::createTask(void* (*fnc_)(void*), void* arg_) {
#error "Please define FSFW_USE_REALTIME_FOR_LINUX with either 0 or 1"
#endif
#if FSFW_USE_REALTIME_FOR_LINUX == 1
// FIFO -> This needs root privileges for the process
status = pthread_attr_setschedpolicy(&attributes, SCHED_FIFO);
// RR -> This needs root privileges for the process
status = pthread_attr_setschedpolicy(&attributes, SCHED_RR);
if (status != 0) {
utility::printUnixErrorGeneric(CLASS_NAME, "createTask", "pthread_attr_setschedpolicy");
}