Changeset b7fd2a0 in mainline for uspace/lib/c/include/futex.h
- Timestamp:
- 2018-01-13T03:10:29Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- a53ed3a
- Parents:
- 36f0738
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/include/futex.h
r36f0738 rb7fd2a0 126 126 * 127 127 */ 128 static inline int futex_down(futex_t *futex)128 static inline errno_t futex_down(futex_t *futex) 129 129 { 130 130 if ((atomic_signed_t) atomic_predec(&futex->val) < 0) 131 return ( int) __SYSCALL1(SYS_FUTEX_SLEEP, (sysarg_t) &futex->val.count);131 return (errno_t) __SYSCALL1(SYS_FUTEX_SLEEP, (sysarg_t) &futex->val.count); 132 132 133 133 return EOK; … … 143 143 * 144 144 */ 145 static inline int futex_up(futex_t *futex)145 static inline errno_t futex_up(futex_t *futex) 146 146 { 147 147 if ((atomic_signed_t) atomic_postinc(&futex->val) < 0) 148 return ( int) __SYSCALL1(SYS_FUTEX_WAKEUP, (sysarg_t) &futex->val.count);148 return (errno_t) __SYSCALL1(SYS_FUTEX_WAKEUP, (sysarg_t) &futex->val.count); 149 149 150 150 return EOK;
Note:
See TracChangeset
for help on using the changeset viewer.