函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\notifier-error-inject.c Create Date:2022-07-27 08:09:43
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:notifier_err_inject_callback

函数原型:static int notifier_err_inject_callback(struct notifier_block *nb, unsigned long val, void *p)

返回类型:int

参数:

类型参数名称
struct notifier_block *nb
unsigned longval
void *p
30  err等于0
31  err_inject等于container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.(nb, structnotifier_err_inject, nb)
35 name循环
36  如果val恒等于val
37  err等于error
38  退出
41  如果err打印信息("Injecting error (%d) to %s\n", err, name)
44  返回:Encapsulate (negative) errno value (in particular, NOTIFY_BAD <=> EPERM).