Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:mm\kmemleak.c Create Date:2022-07-28 16:21:50
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:kmemleak_update_trace - update object allocation stack trace*@ptr: pointer to beginning of the object* Override the object allocation stack trace for cases where the actual* allocation place is not always useful.

Proto:void __ref kmemleak_update_trace(const void *ptr)

Type:void

Parameter:

TypeParameterName
const void *ptr
1015  pr_debug("%s(0x%p)\n", __func__, ptr)
1017  If Not set if tracing memory operations is enabled || IS_ERR_OR_NULL(ptr) Then Return
1020  object = Look up an object in the object search tree and increase its use_count.
1021  If Not object Then
1023  Print a warning and dump the stack trace.("Updating stack trace for unknown object at %p\n", ptr)
1026  Return
1029  spin_lock_irqsave( & lock, flags)
1030  trace_len = Save stack trace to the given array of MAX_TRACE size.
1031  spin_unlock_irqrestore( & lock, flags)
1033  Decrement the object use_count. Once the count is 0, free the object using* an RCU callback. Since put_object() may be called via the kmemleak_free() ->* delete_object() path, the delayed RCU freeing ensures that there is no
Caller
NameDescribe
radix_tree_node_allocThis assumes that the caller has performed appropriate preallocation, and* that the caller has pinned this thread of control to the current CPU.