函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:kmemleak_alloc_percpu - register a newly allocated __percpu object*@ptr: __percpu pointer to beginning of the object*@size: size of the object*@gfp: flags used for kmemleak internal memory allocations* This function is called from the kernel percpu

函数原型:void __ref kmemleak_alloc_percpu(const void __percpu *ptr, size_t size, gfp_t gfp)

返回类型:void

参数:

类型参数名称
const void __percpu *ptr
size_tsize
gfp_tgfp
911  pr_debug("%s(0x%p, %zu)\n", __func__, ptr, size)
917  如果set if tracing memory operations is enabled ptr且非是错误遍历可用CPU(cpu)
919  Create the metadata (struct kmemleak_object) corresponding to an allocated* memory block and add it to the object_list and object_tree_root.
调用者
名称描述
pcpu_allocpcpu_alloc - the percpu allocator*@size: size of area to allocate in bytes*@align: alignment of area (max PAGE_SIZE)*@reserved: allocate from the reserved chunk if available*@gfp: allocation flags* Allocate percpu area of @size bytes aligned at @align