Changeset c2f2392 in rtems-libbsd


Ignore:
Timestamp:
Apr 23, 2015, 1:42:58 PM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, b96abfd647154f10ea8f7fac68e25676636eded5, debc0aed8b9bef9996b8ec0ae7a70b0b41912e27, 9ebb4e202572ed2229107d06c59d8cf76e991c4c, freebsd-9.3, 3ad2cea0c5112997274932ce973094a47259ef5e
Children:
1ee85a5
Parents:
b3ff71e
git-author:
Sebastian Huber <sebastian.huber@…> (04/23/15 13:42:58)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/20/15 07:58:22)
Message:

SLEEPQUEUE(9): Avoid Giant lock

File:
1 edited

Legend:

Unmodified
Added
Removed
  • freebsd/sys/kern/subr_sleepqueue.c

    rb3ff71e rc2f2392  
    639639                _Thread_Lock_release_default(executing, &lock_context);
    640640
    641                 _Giant_Acquire(cpu_self);
    642641                _Thread_Set_state(executing, STATES_WAITING_FOR_BSD_WAKEUP);
    643                 _Giant_Release(cpu_self);
    644642
    645643                _Thread_Lock_acquire_default(executing, &lock_context);
     
    667665
    668666                if (unblock) {
    669                         _Giant_Acquire(cpu_self);
    670667                        _Watchdog_Remove(&executing->Timer);
    671668                        _Thread_Clear_state(executing, STATES_WAITING_FOR_BSD_WAKEUP);
    672                         _Giant_Release(cpu_self);
    673669                }
    674670
     
    972968                cpu_self = _Thread_Dispatch_disable_critical();
    973969                _Thread_Lock_release_default(thread, &lock_context);
    974                 _Giant_Acquire(cpu_self);
    975970
    976971                _Watchdog_Remove(&thread->Timer);
    977972                _Thread_Clear_state(thread, STATES_WAITING_FOR_BSD_WAKEUP);
    978973
    979                 _Giant_Release(cpu_self);
    980974                _Thread_Dispatch_enable(cpu_self);
    981975        } else {
     
    12021196                cpu_self = _Thread_Dispatch_disable_critical();
    12031197                _Thread_Lock_release_default(thread, &lock_context);
    1204                 _Giant_Acquire(cpu_self);
    12051198
    12061199                _Thread_Clear_state(thread, STATES_WAITING_FOR_BSD_WAKEUP);
    12071200
    1208                 _Giant_Release(cpu_self);
    12091201                _Thread_Dispatch_enable(cpu_self);
    12101202        } else {
Note: See TracChangeset for help on using the changeset viewer.