函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

函数名称:get_callchain_buffers

函数原型:int get_callchain_buffers(int event_max_stack)

返回类型:int

参数:

类型参数名称
intevent_max_stack
110  err等于0
113  mutex_lock( & callchain_mutex)
115  count等于atomic_inc_return( & nr_callchain_events)
116  如果WARN_ON_ONCE(count < 1)则
117  err等于负EINVAL
118  转到:exit
128  如果event_max_stack大于sysctl_perf_event_max_stack
129  err等于负EOVERFLOW
130  转到:exit
133  如果count恒等于1则err等于alloc_callchain_buffers()
135  exit :
136  如果erratomic_dec( & nr_callchain_events)
139  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.
141  返回:err
调用者
名称描述
stack_map_allocCalled from syscall
perf_event_allocAllocate and initialize an event structure