Changeset 2965d18 in mainline for uspace/lib/c/generic/fibril.c
- Timestamp:
- 2018-07-30T20:15:38Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- d4b7b29
- Parents:
- 8080262
- git-author:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-07-30 19:53:13)
- git-committer:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-07-30 20:15:38)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/fibril.c
r8080262 r2965d18 476 476 static void _fibril_switch_to(_switch_type_t type, fibril_t *dstf, bool locked) 477 477 { 478 assert(fibril_self()->rmutex_locks == 0); 479 478 480 if (!locked) 479 481 futex_lock(&fibril_futex); … … 633 635 errno_t fibril_wait_timeout(fibril_event_t *event, const struct timeval *expires) 634 636 { 637 assert(fibril_self()->rmutex_locks == 0); 638 635 639 DPRINTF("### Fibril %p sleeping on event %p.\n", fibril_self(), event); 636 640 … … 713 717 void fibril_wait_for(fibril_event_t *event) 714 718 { 719 assert(fibril_self()->rmutex_locks == 0); 720 715 721 (void) fibril_wait_timeout(event, NULL); 716 722 } … … 769 775 void fibril_yield(void) 770 776 { 777 if (fibril_self()->rmutex_locks > 0) 778 return; 779 771 780 fibril_t *f = _ready_list_pop_nonblocking(false); 772 781 if (f) … … 789 798 int fibril_test_spawn_runners(int n) 790 799 { 800 assert(fibril_self()->rmutex_locks == 0); 801 791 802 if (!multithreaded) { 792 803 _ready_debug_check();
Note:
See TracChangeset
for help on using the changeset viewer.