函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\locking\qrwlock.c Create Date:2022-07-27 10:53:39
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:queued_write_lock_slowpath - acquire write lock of a queue rwlock*@lock : Pointer to queue rwlock structure

函数原型:void queued_write_lock_slowpath(struct qrwlock *lock)

返回类型:void

参数:

类型参数名称
struct qrwlock *lock
65  r sched/core.c and kernel_lock.c: ( & wait_lock)
68  如果非atomic_read( & cnts)且atomic_cmpxchg_acquire( & cnts, 0, A writer holds the lock )恒等于0则转到:unlock
73  atomic_add(A writer is waiting , & cnts)
76  循环
77  atomic_cond_read_acquire( & cnts, VAL == A writer is waiting )
78 atomic_cmpxchg_relaxed( & cnts, A writer is waiting , A writer holds the lock )不等于A writer is waiting 循环
80  unlock :
81  arch_spin_unlock( & wait_lock)