Changeset 66374df in rtems


Ignore:
Timestamp:
Apr 29, 2016, 7:27:11 AM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
981eed2
Parents:
259d885
git-author:
Sebastian Huber <sebastian.huber@…> (04/29/16 07:27:11)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/02/16 05:46:17)
Message:

posix: Avoid Giant lock in _POSIX_signals_Send()

Update #2555.
Update #2690.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/posix/src/killinfo.c

    r259d885 r66374df  
    7777  Thread_queue_Heads          *heads;
    7878  ISR_lock_Context             lock_context;
     79  Per_CPU_Control             *cpu_self;
    7980
    8081  /*
     
    121122  }
    122123
    123   _Thread_Disable_dispatch();
     124  /* FIXME: https://devel.rtems.org/ticket/2690 */
     125  cpu_self = _Thread_Dispatch_disable();
    124126
    125127  /*
     
    127129   *  get it an execute it as soon as the dispatcher executes.
    128130   */
    129   the_thread = _Thread_Executing;
     131  the_thread = _Per_CPU_Get_executing( cpu_self );
    130132
    131133  api = the_thread->API_Extensions[ THREAD_API_POSIX ];
     
    321323   */
    322324  if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
    323     _Thread_Enable_dispatch();
     325    _Thread_Dispatch_enable( cpu_self );
    324326    return 0;
    325327  }
     
    341343    if ( !psiginfo ) {
    342344      _POSIX_signals_Release( &lock_context );
    343       _Thread_Enable_dispatch();
     345      _Thread_Dispatch_enable( cpu_self );
    344346      rtems_set_errno_and_return_minus_one( EAGAIN );
    345347    }
     
    355357  _POSIX_signals_Release( &lock_context );
    356358  DEBUG_STEP("\n");
    357   _Thread_Enable_dispatch();
     359  _Thread_Dispatch_enable( cpu_self );
    358360  return 0;
    359361}
Note: See TracChangeset for help on using the changeset viewer.