函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:Check whether a TASK_UNINTERRUPTIBLE does not get woken up for* a really long time (120 seconds). If that happens, print out* a warning.

函数原型:static void check_hung_uninterruptible_tasks(unsigned long timeout)

返回类型:void

参数:

类型参数名称
unsigned longtimeout
175  max_count等于The number of tasks checked:
176  last_break等于jiffies
183  如果test_taint(TAINT_DIE)或did_panic则返回
186  hung_task_show_lock = false
187  _read_lock() - mark the beginning of an RCU read-side critical section* When synchronize_rcu() is invoked on one CPU while other CPUs* are within RCU read-side critical sections, then the* synchronize_rcu() is guaranteed to block until after all the other
188  Careful: this is a double loop, 'break' won't work as expected. (g, t)
189  如果非max_count自减则转到:unlock
194  last_break等于jiffies
197  如果任务状态恒等于深度睡眠态check_hung_task(t, timeout)
200  unlock :
201  _read_unlock() - marks the end of an RCU read-side critical section.* In most situations, rcu_read_unlock() is immune from deadlock.* However, in kernels built with CONFIG_RCU_BOOST, rcu_read_unlock()
202  如果hung_task_show_lockdebug_show_all_locks()
204  如果hung_task_call_panic
205  trigger_all_cpu_backtrace()
206  panic - halt the system*@fmt: The text string to print* Display a message, then perform cleanups.* This function never returns.
调用者
名称描述
watchdogkthread which checks for tasks stuck in D state