函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:__down_write_killable

函数原型:static inline int __down_write_killable(struct rw_semaphore *sem)

返回类型:int

参数:

类型参数名称
struct rw_semaphore *sem
1399  tmp等于RWSEM_UNLOCKED_VALUE
1401  如果此条件成立可能性小(为编译器优化)(!atomic_long_try_cmpxchg_acquire( & count, & tmp, On 64-bit architectures, the bit definitions of the count are:* Bit 0 - writer locked bit* Bit 1 - waiters present bit* Bit 2 - lock handoff bit* Bits 3-7 - reserved* Bits 8-62 - 55-bit reader count* Bit 63 - read fail bit* On 32-bit architectures, the ))则
1403  如果是错误则返回:负EINTR
1405  否则
1406  All writes to owner are protected by WRITE_ONCE() to make sure that* store tearing can't happen as optimistic spinners may read and use* the owner value concurrently without lock
1408  返回:0