Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\trace\trace.c Create Date:2022-07-28 11:59:27
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:__trace_array_vprintk

Proto:static int __trace_array_vprintk(struct ring_buffer *buffer, unsigned long ip, const char *fmt, va_list args)

Type:int

Parameter:

TypeParameterName
struct ring_buffer *buffer
unsigned longip
const char *fmt
va_listargs
3253  call = event_print
3255  len = 0
3260  If Kill all tracing for good (never come back).* It is initialized to 1 but will turn to zero if the initialization* of the tracer is successful. But that is the only place that sets* this back to zero. || We need to change this state when a selftest is running.* A selftest will lurk into the ring-buffer to count the* entries inserted during the selftest although some concurrent* insertions into the ring-buffer such as trace_printk could occurred Then Return 0
3264  pause_graph_tracing()
3266  pc = We mask the PREEMPT_NEED_RESCHED bit so as not to confuse all current users* that think a non-zero value indicates we cannot preempt.
3267  preempt_disable_notrace()
3270  tbuffer = Thise allows for lockless recording. If we're nested too deeply, then* this returns NULL.
3271  If Not tbuffer Then
3272  len = 0
3273  Go to out_nobuffer
3276  len = vscnprintf - 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*@args: Arguments for the format string* The return value is the
3278  local_save_flags(flags)
3279  size = size of entry + len + 1
3280  event = __trace_buffer_lock_reserve(buffer, TRACE_PRINT, size, flags, pc)
3282  If Not event Then Go to out
3284  entry = g_buffer_event_data - return the data of the event*@event: the event to get the data from
3285  ip = ip
3287  No 3D Now!( & buf, tbuffer, len + 1)
3288  If Not call_filter_check_discard(call, entry, buffer, event) Then
3289  __buffer_unlock_commit(buffer, event)
3290  ftrace_trace_stack( & The global_trace is the descriptor that holds the top-level tracing* buffers for the live tracing., buffer, flags, 6, pc, NULL)
3293  out :
3294  put_trace_buf()
3296  out_nobuffer :
3297  preempt_enable_notrace()
3298  unpause_graph_tracing()
3300  Return len
Caller
NameDescribe
trace_array_vprintk
trace_array_printk_buf