Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\locking\lockdep.c Create Date:2022-07-28 09:50:39
Last Modify:2020-03-17 14:16:01 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:print_freed_lock_bug

Proto:static void print_freed_lock_bug(struct task_struct *curr, const void *mem_from, const void *mem_to, struct held_lock *hlock)

Type:void

Parameter:

TypeParameterName
struct task_struct *curr
const void *mem_from
const void *mem_to
struct held_lock *hlock
5245  If Not Generic 'turn off all lock debugging' function: Then Return
5247  If The locking-testsuite uses to get a 'silent failure': nothing is printed to the console when a locking bug is detected Then Return
5250  pr_warn("\n")
5251  pr_warn("=========================\n")
5252  pr_warn("WARNING: held lock freed!\n")
5253  print_kernel_ident()
5254  pr_warn("-------------------------\n")
5255  pr_warn("%s/%d is freeing memory %px-%px, with a lock still held there!\n", * executable name, excluding path. * - normally initialized setup_new_exec() * - access it with [gs]et_task_comm() * - lock it with task_lock(), task_pid_nr(curr), mem_from, mem_to - 1)
5257  print_lock(hlock)
5258  lockdep_print_held_locks(curr)
5260  pr_warn("\nstack backtrace:\n")
5261  dump_stack()
Caller
NameDescribe
debug_check_no_locks_freedCalled when kernel memory is freed (or unmapped), or if a lock* is destroyed or reinitialized - this code checks whether there is* any held lock in the memory range of to :