Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:event_trace_init

Proto:__init int event_trace_init(void)

Type:int

Parameter:Nothing

3179  tr = The global tracer (top) should be the first trace array added,* but we check the flag anyway.
3180  If Not tr Then Return -ENODEV
3183  d_tracer = racing_init_dentry - initialize top level trace array* This is called when creating files or directories in the tracing* directory. It is called via fs_initcall() by any of the boot up code
3184  If IS_ERR(d_tracer) Then Return 0
3187  entry = tracefs_create_file("available_events", 0444, d_tracer, tr, & ftrace_avail_fops)
3189  If Not entry Then pr_warn("Could not create tracefs 'available_events' entry\n")
3192  If trace_define_generic_fields() Then pr_warn("tracing: Failed to allocated generic fields")
3195  If trace_define_common_fields() Then pr_warn("tracing: Failed to allocate common fields")
3198  ret = The top trace array already had its file descriptors created.* Now the files themselves need to be created.
3199  If ret Then Return ret
3203  ret = register_module_notifier( & trace_module_nb)
3204  If ret Then pr_warn("Failed to register trace events module notifier\n")
3207  Return 0
Caller
NameDescribe
tracer_init_tracefs