#2725 closed defect

Classic binary semaphores without a locking protocol can be released by everyone — at Version 2

Reported by: Sebastian Huber Owned by: Sebastian Huber
Priority: high Milestone: 5.1
Component: score Version: 4.10
Severity: normal Keywords:
Cc: Blocked By:
Blocking:

Description (last modified by Chris Johns)

The Classic binary semaphores without a locking protocol can be released by everyone, e.g. in contrast to the POSIX mutexes (all variants) or the Classic binary semphores with priority inheritance or ceiling, there is no owner check in the release path.

This behaviour is a bit unexpected and not documented.

The following test case fails in case an owner check is added:

*** BEGIN OF TEST SP 42 ***
Exercising blocking discipline w/extract in FIFO order 
Exercising blocking discipline w/unblock in FIFO order
TA00 - unblocked - OK

rtems_semaphore_delete FAILED -- expected (RTEMS_SUCCESSFUL) got (RTEMS_RESOURCE_IN_USE)

This is actually a bug in the test, since an available mutex is released again.

Change History (2)

comment:1 Changed on 06/03/16 at 06:24:47 by Sebastian Huber

Component: Generalcpukit
Summary: Classic binary semaphores without a locking protocol can be release by everyoneClassic binary semaphores without a locking protocol can be released by everyone

comment:2 Changed on 06/03/16 at 06:25:16 by Chris Johns

Description: modified (diff)
Note: See TracTickets for help on using tickets.