函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:kasan_krealloc

函数原型:void *__must_check kasan_krealloc(const void *object, size_t size, gfp_t flags)

返回类型:void

参数:

类型参数名称
const void *object
size_tsize
gfp_tflags
560  如果此条件成立可能性小(为编译器优化)(object == ZERO_SIZE_PTR will be returned for zero sized kmalloc requests.* Dereferencing ZERO_SIZE_PTR will lead to a distinct access fault.* ZERO_SIZE_PTR can be passed to kfree though in the same way that NULL can.* Both make kfree a no-op.)则返回:object
563  page等于virt_to_head_page(object)
565  如果此条件成立可能性小(为编译器优化)(!PageSlab(page))则返回:kasan_kmalloc_large(object, size, flags)
567  否则返回:__kasan_kmalloc(用于SLUB分配器,指向slab的指针, object, size, flags, true)
调用者
名称描述
__do_krealloc