函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:klp_init_object

函数原型:static int klp_init_object(struct klp_patch *patch, struct klp_object *obj)

返回类型:int

参数:

类型参数名称
struct klp_patch *patch
struct klp_object *obj
791  如果klp_is_module(obj)且strlen - Find the length of a string*@s: The string to be sized大于等于MODULE_NAME_LEN则返回:负EINVAL
794  patched = false
795  mod = NULL
797  sets obj->mod if object is not vmlinux and module is found
799  name等于如果klp_is_module(obj)则 external 否则"vmlinux"
800  ret等于kobject_add() - The main kobject add function.*@kobj: the kobject to add*@parent: pointer to the parent of the kobject.*@fmt: format to name the kobject with.* The kobject name is set and added to the kobject hierarchy in this* function.
801  如果ret则返回:ret
804  klp_for_each_func(obj, func)
805  ret等于klp_init_func(obj, func)
806  如果ret则返回:ret
810  如果klp_is_object_loaded(obj)则ret等于parts of the initialization that is done only when the object is loaded
813  返回:ret
调用者
名称描述
klp_init_patch