函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:The lockevent_read() function can be overridden.

函数原型:ssize_t __weak lockevent_read(struct file *file, char __user *user_buf, size_t count, loff_t *ppos)

返回类型:ssize_t

参数:

类型参数名称
struct file *file
char __user *user_buf
size_tcount
loff_t *ppos
66  sum等于0
71  id等于i_private
73  如果id大于等于 # of write lock handoffs 则返回:负EBADF
76  遍历可用CPU(cpu)
77  sum加等于per_cpu(Per-cpu counts[id], cpu)
78  len等于snprintf - Format a string and place it in a buffer*@buf: The buffer to place the result into*@size: The size of the buffer, including the trailing null space*@fmt: The format string to use*@
80  返回:simple_read_from_buffer(user_buf, count, ppos, buf, len)