函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:event_trigger_regex_write

函数原型:static ssize_t event_trigger_regex_write(struct file *file, const char __user *ubuf, size_t cnt, loff_t *ppos)

返回类型:ssize_t

参数:

类型参数名称
struct file *file
const char __user *ubuf
size_tcnt
loff_t *ppos
247  如果非cnt则返回:0
250  如果cnt大于等于PAGE_SIZE则返回:负EINVAL
253  buf等于memdup_user_nul(ubuf, cnt)
254  如果是错误则返回:错误
257  删除前导和尾随空格
259  mutex_lock( & event_mutex)
260  event_file等于event_file_data(file)
261  如果此条件成立可能性小(为编译器优化)(!event_file)则
262  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
263  kfree(buf)
264  返回:负ENODEV
266  ret等于trigger_process_regex(event_file, buf)
267  mutex_unlock - release the mutex*@lock: the mutex to be released* Unlock a mutex that has been locked by this task previously.* This function must not be used in interrupt context. Unlocking* of a not locked mutex is not allowed.
269  kfree(buf)
270  如果ret小于0则转到:out
273  ppos加等于cnt
274  ret等于cnt
275  out :
276  返回:ret
调用者
名称描述
event_trigger_write