__synth_event_gen_cmd_start(9)
πΈ __synth_event_gen_cmd_start πΈ
okay so bestie, welcome to the Kernel API Manual β this little cutie is __synth_event_gen_cmd_start, and it's literally the "start a synthetic event command from an arg list" girlie. π
β¨ NAME β¨
__synth_event_gen_cmd_start β start a synthetic event command from an arg list π
π¦ SYNOPSIS π¦
int __synth_event_gen_cmd_start (struct dynevent_cmd *cmd , const char *name , struct module *mod , ... );
π ARGUMENTS π
cmdβ a pointer to thedynevent_cmdstruct representing the new event. like, the whole vibe container for it π«Άnameβ the name of the synthetic event. name her, bestie β¨modβ the module creating the event, orNULLif it's not created from a module...β a variable number of args in pairs, one pair for each field π
π§ NOTE π§
okay real talk β users normally won't want to call this function directly π instead use the synth_event_gen_cmd_start wrapper, which automatically adds a NULL to the end of the arg list for you. so convenient, honestly iconic. but if you do use this function directly, make sure the last arg in the variable arg list is NULL. no cap, that part matters. π
This generates a synthetic event command to be executed by synth_event_gen_cmd_end. and here's the serve: this function can be used to generate the complete command or only the first part of it. in that latter case, synth_event_add_field, synth_event_add_field_str, or synth_event_add_fields can be used to add more fields following this. expansion pack energy π
There should be an even number of variable args, each pair consisting of a type followed by a field name. type + name, type + name, it's giving matching set πΈ
See synth_field_size for available types. and if field_name contains [n], the field is considered to be an array. noted! β¨
π₯ RETURN π₯
0 if successful, error otherwise. that's it, that's the whole mood π
π SEE ALSO π
Kernel file ./kernel/trace/trace_events_synth.c β plus the whole friend group:
synth_event_add_field(9)synth_event_add_field_str(9)synth_event_add_fields(9)synth_event_gen_cmd_array_start(9)synth_event_create(9)synth_event_delete(9)synth_event_cmd_init(9)synth_event_trace(9)synth_event_trace_array(9)synth_event_trace_start(9)synth_event_add_next_val(9)synth_event_add_val(9)synth_event_trace_end(9)
okay that's the whole page, bestie, go forth and synthesize β¨π
sign-off szn: this one lives in ./kernel/trace, dated October 2026, and the version tag is literally __synth_event_gen_cmd_start(9) β that's the whole footer, mwah ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms