1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 3 * Automatically generated C representation of opid automaton 4 * For further information about this format, see kernel documentation: 5 * Documentation/trace/rv/deterministic_automata.rst 6 */ 7 8 #define MONITOR_NAME opid 9 10 enum states_opid { 11 any_opid, 12 state_max_opid, 13 }; 14 15 #define INVALID_STATE state_max_opid 16 17 enum events_opid { 18 sched_need_resched_opid, 19 sched_waking_opid, 20 event_max_opid, 21 }; 22 23 enum envs_opid { 24 irq_off_opid, 25 preempt_off_opid, 26 env_max_opid, 27 env_max_stored_opid = irq_off_opid, 28 }; 29 30 _Static_assert(env_max_stored_opid <= MAX_HA_ENV_LEN, "Not enough slots"); 31 32 struct automaton_opid { 33 char *state_names[state_max_opid]; 34 char *event_names[event_max_opid]; 35 char *env_names[env_max_opid]; 36 unsigned char function[state_max_opid][event_max_opid]; 37 unsigned char initial_state; 38 bool final_states[state_max_opid]; 39 }; 40 41 static const struct automaton_opid automaton_opid = { 42 .state_names = { 43 "any", 44 }, 45 .event_names = { 46 "sched_need_resched", 47 "sched_waking", 48 }, 49 .env_names = { 50 "irq_off", 51 "preempt_off", 52 }, 53 .function = { 54 { any_opid, any_opid }, 55 }, 56 .initial_state = any_opid, 57 .final_states = { 1 }, 58 }; 59