Changeset 8f96581 in rtems for cpukit/rtems/src/msgqbroadcast.c


Ignore:
Timestamp:
Apr 1, 2016, 9:38:47 AM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
7d21700
Parents:
818ad5eb
git-author:
Sebastian Huber <sebastian.huber@…> (04/01/16 09:38:47)
git-committer:
Sebastian Huber <sebastian.huber@…> (04/06/16 07:08:21)
Message:

score: Rework MP thread queue callout support

The thread queue implementation was heavily reworked to support SMP.
This broke the multiprocessing support of the thread queues. This is
fixed by this patch.

A thread proxy is unblocked due to three reasons

1) timeout,
2) request satisfaction, and
3) extraction.

In case 1) no MPCI message must be sent. This is ensured via the
_Thread_queue_MP_callout_do_nothing() callout set during
_Thread_MP_Allocate_proxy().

In case 2) and 3) an MPCI message must be sent. In case we interrupt
the blocking operation during _Thread_queue_Enqueue_critical(), then
this message must be sent by the blocking thread. For this the new
fields Thread_Proxy_control::thread_queue_callout and
Thread_Proxy_control::thread_queue_id are used.

Delete the individual API MP callout types and use
Thread_queue_MP_callout throughout. This type is only defined in
multiprocessing configurations. Prefix the multiprocessing parameters
with mp_ to ease code review. Multiprocessing specific parameters are
optional due to use of a similar macro pattern. There is no overhead
for non-multiprocessing configurations.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/rtems/src/msgqbroadcast.c

    r818ad5eb r8f96581  
    6161                      buffer,
    6262                      size,
     63                      _Message_queue_Core_message_queue_mp_support,
    6364                      id,
    64                       #if defined(RTEMS_MULTIPROCESSING)
    65                         _Message_queue_Core_message_queue_mp_support,
    66                       #else
    67                         NULL,
    68                       #endif
    6965                      count,
    7066                      &lock_context
Note: See TracChangeset for help on using the changeset viewer.