Function report |
Source Code:kernel\futex.c |
Create Date:2022-07-28 10:54:44 |
Last Modify:2020-03-17 15:28:32 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Userspace attempted a TID -> 0 atomic transition, and failed.* This is the in-kernel slowpath: we look up the PI state (if any),* and do the rt-mutex unlock.
Proto:static int futex_unlock_pi(unsigned int __user *uaddr, unsigned int flags)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
unsigned int __user * | uaddr | |
unsigned int | flags |
3070 | curval = curval , vpid = task_pid_vnr(current process) |
3071 | key = FUTEX_KEY_INIT |
3076 | If Not IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_FUTEX_PI) Then Return -ENOSYS |
3079 | retry : |
3080 | If Get a simple variable from user space(uval, uaddr) Then Return -EFAULT |
3085 | If (uval & The rest of the robust-futex field is for the TID:) != vpid Then Return -EPERM |
3101 | If top_waiter Then |
3105 | If Not pi_state Then Go to out_unlock |
3112 | If owner != current process Then Go to out_unlock |
3115 | get_pi_state(pi_state) |
3126 | raw_spin_lock_irq( & wait_lock) |
3127 | spin_unlock( & lock) |
3132 | Drops a reference to the pi_state object and frees or caches it* when the last reference is gone. |
3137 | If Not ret Then Go to out_putkey |
3143 | If ret == -EFAULT Then Go to pi_faulted |
3155 | Go to out_putkey |
3165 | If ret = cmpxchg_futex_value_locked( & curval, uaddr, uval, 0) Then |
3166 | spin_unlock( & lock) |
3169 | Go to pi_faulted |
3172 | Go to pi_retry |
3174 | Default |
3175 | WARN_ON_ONCE(1) |
3176 | Go to out_putkey |
3185 | out_unlock : |
3186 | spin_unlock( & lock) |
3187 | out_putkey : |
3188 | put_futex_key( & key) |
3189 | Return ret |
3191 | pi_retry : |
3192 | put_futex_key( & key) |
3193 | cond_resched() |
3194 | Go to retry |
3196 | pi_faulted : |
3197 | put_futex_key( & key) |
3203 | Return ret |
Name | Describe |
---|---|
do_futex |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |