Posix priority vs. RTEMS priority

Heinz Junkes junkes at fhi-berlin.mpg.de
Thu Mar 30 13:16:48 UTC 2017


Dear list,

I’m a bit confused about the priorities used with POSIX in  RTEMS 4.12.

In the system config I am using the POSIX initialization:

extern void *EPICS_WITH_POSIX_Init(void *argument);

#define CONFIGURE_POSIX_INIT_THREAD_TABLE
#define CONFIGURE_POSIX_INIT_THREAD_ENTRY_POINT EPICS_WITH_POSIX_Init

Requesting the task priority in EPICS_WITH_POSIX_Init() I get Prio “2” whitch looks like “RTEMS_HIGH_PRIO” ?

void *
EPICS_WITH_POSIX_Init (void *argument)
{
 int policy;
    struct sched_param param;

    if (pthread_getschedparam(pthread_self(), &policy, &param) != 0)
      delayedPanic("pthread_getschedparam failed”);

    printf(" main priority = %d\n", param.sched_priority);

leads to the output:

...
 main priority = 2

***** RTEMS Version: rtems-4.11.99.0 (PowerPC/Generic (classic FPU)/beatnik) *****
…

I expected Prio 254 or 253 because at Posix higher priorities -> higher value.


What do I think wrong here?

Heinz

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/users/attachments/20170330/377614c0/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2209 bytes
Desc: not available
URL: <http://lists.rtems.org/pipermail/users/attachments/20170330/377614c0/attachment.bin>


More information about the users mailing list