Lines Matching +full:foo +full:- +full:bar
1 /* SPDX-License-Identifier: GPL-2.0 */
8 * In this case, it would look for sample-trace.h
14 * This file is called trace-events-sample.h but we want the system
15 * to be called "sample-trace". Therefore we must define the name of this
18 * #define TRACE_INCLUDE_FILE trace-events-sample
26 #define TRACE_SYSTEM sample-trace
29 * TRACE_SYSTEM is expected to be a C valid variable (alpha-numeric
36 * But the above is only needed if TRACE_SYSTEM is not alpha-numeric
38 * TRACE_SYSTEM. As TRACE_SYSTEM_VAR must be alpha-numeric, if
40 * only alpha-numeric and underscores.
70 * Here it is trace_foo_bar(char *foo, int bar).
73 * Here it is simply "foo, bar".
85 * __field(int, foo)
87 * __entry->foo = 5;
94 * __field_struct(struct bar, foo)
96 * __entry->bar.x = y;
102 * __array( char, foo, 10) is the same as saying: char foo[10];
106 * __entry->foo[0] = 'a';
108 * memcpy(__entry->foo, bar, 10);
119 * __dynamic_array( int, foo, bar) is similar to: int foo[bar];
124 * memcpy(__get_dynamic_array(foo), bar, 10);
135 * __string(foo, bar) is similar to: strcpy(foo, bar)
139 * __assign_str(foo, bar);
154 * __vstring(foo, fmt, va) is similar to: vsnprintf(foo, fmt, va)
158 * __assign_vstr(foo, fmt, va);
175 * __string_len(foo, bar, len)
179 * __assign_str_len(foo, bar, len);
184 * memcpy(__get_str(foo), bar, len);
185 * __get_str(foo)[len] = 0;
189 * for the '\0' terminating byte, and __get_str(foo) can be used
201 * __assign_bitmask(target_cpus, cpumask_bits(bar), nr_cpumask_bits);
212 * __assign_cpumask(target_cpus, cpumask_bits(bar));
228 * For __dynamic_array(int, foo, bar) use __get_dynamic_array(foo)
229 * Use __get_dynamic_array_len(foo) to get the length of the array
235 * For __string(foo, bar) use __get_str(foo)
291 TP_PROTO(const char *foo, int bar, const int *lst,
295 TP_ARGS(foo, bar, lst, string, mask, fmt, va),
298 __array( char, foo, 10 )
299 __field( int, bar )
308 strlcpy(__entry->foo, foo, 10);
309 __entry->bar = bar;
318 TP_printk("foo %s %d %s %s %s %s (%s) (%s) %s", __entry->foo, __entry->bar,
328 * version of the number (if __entry->bar == 7 then "7" is returned).
330 __print_symbolic(__entry->bar,
348 __print_flags(__entry->bar, "|",
405 TP_PROTO(const char *foo, int bar),
407 TP_ARGS(foo, bar),
409 TP_CONDITION(!(bar % 10)),
412 __string( foo, foo )
413 __field( int, bar )
417 __assign_str(foo, foo);
418 __entry->bar = bar;
421 TP_printk("foo %s %d", __get_str(foo), __entry->bar)
448 TP_PROTO(const char *foo, int bar),
450 TP_ARGS(foo, bar),
453 __string( foo, foo )
454 __field( int, bar )
458 __assign_str(foo, foo);
459 __entry->bar = bar;
462 TP_printk("foo %s %d", __get_str(foo), __entry->bar),
495 TP_PROTO(const char *foo, int bar),
497 TP_ARGS(foo, bar),
500 __string( foo, foo )
501 __field( int, bar )
505 __assign_str(foo, foo);
506 __entry->bar = bar;
509 TP_printk("foo %s %d", __get_str(foo), __entry->bar)
517 TP_PROTO(const char *foo, int bar),
518 TP_ARGS(foo, bar));
521 TP_PROTO(const char *foo, int bar),
522 TP_ARGS(foo, bar),
523 TP_CONDITION(!(bar % 8)));
527 TP_PROTO(const char *foo, int bar),
528 TP_ARGS(foo, bar),
544 TP_PROTO(const char *foo, int bar),
545 TP_ARGS(foo, bar),
546 TP_printk("bar %s %d", __get_str(foo), __entry->bar));
553 * different. This is expected to be used with user-space event,
560 TP_PROTO(const char *foo, int bar, unsigned long *mask, const cpumask_t *cpus),
562 TP_ARGS(foo, bar, mask, cpus),
565 __rel_string( foo, foo )
566 __field( int, bar )
573 __assign_rel_str(foo, foo);
574 __entry->bar = bar;
580 TP_printk("foo_rel_loc %s, %d, %s, %s", __get_rel_str(foo), __entry->bar,
602 * CFLAGS_trace-events-sample.o := -I$(src)
609 * CFLAGS_trace-events-sample.o := -I$(PWD)
625 #define TRACE_INCLUDE_FILE trace-events-sample