Linux Perf
trace-event-info.c File Reference
#include "util.h"
#include <dirent.h>
#include <mntent.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/wait.h>
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
#include <stdbool.h>
#include <linux/list.h>
#include <linux/kernel.h>
#include "../perf.h"
#include "trace-event.h"
#include <api/fs/tracing_path.h>
#include "evsel.h"
#include "debug.h"
Include dependency graph for trace-event-info.c:

Go to the source code of this file.

Macros

#define VERSION   "0.6"
 
#define for_each_event(dir, dent, tps)
 

Functions

int bigendian (void)
 
static int record_file (const char *file, ssize_t hdr_sz)
 
static int record_header_files (void)
 
static bool name_in_tp_list (char *sys, struct tracepoint_path *tps)
 
static int copy_event_system (const char *sys, struct tracepoint_path *tps)
 
static int record_ftrace_files (struct tracepoint_path *tps)
 
static bool system_in_tp_list (char *sys, struct tracepoint_path *tps)
 
static int record_event_files (struct tracepoint_path *tps)
 
static int record_proc_kallsyms (void)
 
static int record_ftrace_printk (void)
 
static int record_saved_cmdline (void)
 
static void put_tracepoints_path (struct tracepoint_path *tps)
 
static struct tracepoint_pathget_tracepoints_path (struct list_head *pattrs)
 
bool have_tracepoints (struct list_head *pattrs)
 
static int tracing_data_header (void)
 
struct tracing_datatracing_data_get (struct list_head *pattrs, int fd, bool temp)
 
int tracing_data_put (struct tracing_data *tdata)
 
int read_tracing_data (int fd, struct list_head *pattrs)
 

Variables

static int output_fd
 

Macro Definition Documentation

◆ for_each_event

#define for_each_event (   dir,
  dent,
  tps 
)
Value:
while ((dent = readdir(dir))) \
if (dent->d_type == DT_DIR && \
(strcmp(dent->d_name, ".")) && \
(strcmp(dent->d_name, ".."))) \
static char * dir
Definition: attr.c:39

Definition at line 171 of file trace-event-info.c.

◆ VERSION

#define VERSION   "0.6"

Definition at line 44 of file trace-event-info.c.

Function Documentation

◆ bigendian()

int bigendian ( void  )

Definition at line 49 of file trace-event-info.c.

Here is the call graph for this function:

◆ copy_event_system()

static int copy_event_system ( const char *  sys,
struct tracepoint_path tps 
)
static

Definition at line 177 of file trace-event-info.c.

Here is the call graph for this function:

◆ get_tracepoints_path()

static struct tracepoint_path* get_tracepoints_path ( struct list_head *  pattrs)
static

Definition at line 420 of file trace-event-info.c.

Here is the call graph for this function:

◆ have_tracepoints()

bool have_tracepoints ( struct list_head *  pattrs)

Definition at line 457 of file trace-event-info.c.

◆ name_in_tp_list()

static bool name_in_tp_list ( char *  sys,
struct tracepoint_path tps 
)
static

Definition at line 160 of file trace-event-info.c.

◆ put_tracepoints_path()

static void put_tracepoints_path ( struct tracepoint_path tps)
static

Definition at line 407 of file trace-event-info.c.

Here is the call graph for this function:

◆ read_tracing_data()

int read_tracing_data ( int  fd,
struct list_head *  pattrs 
)

Definition at line 601 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_event_files()

static int record_event_files ( struct tracepoint_path tps)
static

Definition at line 269 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_file()

static int record_file ( const char *  file,
ssize_t  hdr_sz 
)
static

Definition at line 59 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_ftrace_files()

static int record_ftrace_files ( struct tracepoint_path tps)
static

Definition at line 240 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_ftrace_printk()

static int record_ftrace_printk ( void  )
static

Definition at line 350 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_header_files()

static int record_header_files ( void  )
static

Definition at line 104 of file trace-event-info.c.

Here is the call graph for this function:

◆ record_proc_kallsyms()

static int record_proc_kallsyms ( void  )
static

Definition at line 338 of file trace-event-info.c.

◆ record_saved_cmdline()

static int record_saved_cmdline ( void  )
static

Definition at line 378 of file trace-event-info.c.

Here is the call graph for this function:

◆ system_in_tp_list()

static bool system_in_tp_list ( char *  sys,
struct tracepoint_path tps 
)
static

Definition at line 258 of file trace-event-info.c.

◆ tracing_data_get()

struct tracing_data* tracing_data_get ( struct list_head *  pattrs,
int  fd,
bool  temp 
)

Definition at line 507 of file trace-event-info.c.

Here is the call graph for this function:

◆ tracing_data_header()

static int tracing_data_header ( void  )
static

Definition at line 468 of file trace-event-info.c.

Here is the call graph for this function:

◆ tracing_data_put()

int tracing_data_put ( struct tracing_data tdata)

Definition at line 588 of file trace-event-info.c.

Here is the call graph for this function:

Variable Documentation

◆ output_fd

int output_fd
static

Definition at line 46 of file trace-event-info.c.