函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\locking\lockdep.c Create Date:2022-07-27 10:50:23
Last Modify:2020-03-17 14:16:01 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:__lock_downgrade

函数原型:static int __lock_downgrade(struct lockdep_map *lock, unsigned long ip)

返回类型:int

参数:

类型参数名称
struct lockdep_map *lock
unsigned longip
4163  curr等于当前进程
4164  merged等于0
4168  如果此条件成立可能性小(为编译器优化)(!We want to turn all lock-debugging facilities on/off at once,* via a global flag. The reason is that once a single bug has been* detected and reported, there might be cascade of followup bugs* that would just muddy the log. So we report the first one and)则返回:0
4171  depth等于lockdep_depth
4176  如果DEBUG_LOCKS_WARN_ON(!depth)则返回:0
4179  hlock等于@depth must not be zero
4180  如果非hlock
4181  print_unlock_imbalance_bug(curr, lock, ip)
4182  返回:0
4185  lockdep_depth等于i
4186  curr_chain_key等于prev_chain_key
4188  WARN(read, "downgrading a read lock")
4189  read等于1
4190  acquire_ip等于ip
4192  如果reacquire_held_locks(curr, depth, i, & merged)则返回:0
4196  如果DEBUG_LOCKS_WARN_ON(merged)则返回:0
4203  如果DEBUG_LOCKS_WARN_ON(lockdep_depth != depth)则返回:0
4206  返回:1
调用者
名称描述
lock_downgrade