Implementation of a new Resource Sharing Protocol

Sebastian Huber sebastian.huber at embedded-brains.de
Mon Nov 12 10:43:04 UTC 2018


Hello Malte,

On 12/11/2018 11:28, Malte Münch wrote:
> Hi,
>
> i am implementing a new resource sharing protocol for RTEMS as part of
> my bachelor thesis. The thesis is about resource sharing protocols in
> realtime environments on multicore systems. Right now i have to use a
> spinlock for a protocol and found a helpful implementation/function in
> cpukit/include/rtems/score/smplockmcs.h. My protocol requires the
> calling task to be non-preemptable and the comment for the
> acquire-function requires me to disable the interrupts.

the lock API for the operating system implementation is defined in 
<rtems/score/isrlock.h>. Please do not use <rtems/score/smplock*.h> 
directly.

>
> The comment in cpukit/rtems/src/taskmode.c says that it is not possible
> to change either interrupt levels or the preemptability of a task in a
> SMP configuration. Do you have a pointer for me on how to overcome this
> issue?

You look at the wrong layer. This rtems_task_mode() is a part of the 
user API. It should not be used for the operating system implementation 
which deals with locking protocols.

-- 
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.




More information about the devel mailing list