diff options
| author | Gabriele Monaco <gmonaco@redhat.com> | 2025-11-26 11:42:38 +0100 |
|---|---|---|
| committer | Gabriele Monaco <gmonaco@redhat.com> | 2026-01-12 07:43:50 +0100 |
| commit | 3d2bfeeef340c8494eba80e7a005159cac69c2f7 (patch) | |
| tree | 6210348959bfae362603bbc977be93243407f757 /kernel/trace/rv/monitors/wwnr | |
| parent | 0d2405a086a035cce1e0ba1aa0849bd2104a4d6b (diff) | |
verification/dot2c: Remove superfluous enum assignment and add last comma
The header files generated by dot2c currently create enums for states
and events assigning the first element to 0. This is superfluous as it
happens automatically if no value is specified.
Also it doesn't add a comma to the last enum elements, which slightly
complicates the diff if states or events are added.
Remove the assignment to 0 and add a comma to last elements, this
simplifies the logic for the code generator.
Reviewed-by: Nam Cao <namcao@linutronix.de>
Link: https://lore.kernel.org/r/20251126104241.291258-8-gmonaco@redhat.com
Signed-off-by: Gabriele Monaco <gmonaco@redhat.com>
Diffstat (limited to 'kernel/trace/rv/monitors/wwnr')
| -rw-r--r-- | kernel/trace/rv/monitors/wwnr/wwnr.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/kernel/trace/rv/monitors/wwnr/wwnr.h b/kernel/trace/rv/monitors/wwnr/wwnr.h index 85d12e42a955..a28006512c9b 100644 --- a/kernel/trace/rv/monitors/wwnr/wwnr.h +++ b/kernel/trace/rv/monitors/wwnr/wwnr.h @@ -8,18 +8,18 @@ #define MONITOR_NAME wwnr enum states_wwnr { - not_running_wwnr = 0, + not_running_wwnr, running_wwnr, - state_max_wwnr + state_max_wwnr, }; #define INVALID_STATE state_max_wwnr enum events_wwnr { - switch_in_wwnr = 0, + switch_in_wwnr, switch_out_wwnr, wakeup_wwnr, - event_max_wwnr + event_max_wwnr, }; struct automaton_wwnr { @@ -33,12 +33,12 @@ struct automaton_wwnr { static const struct automaton_wwnr automaton_wwnr = { .state_names = { "not_running", - "running" + "running", }, .event_names = { "switch_in", "switch_out", - "wakeup" + "wakeup", }, .function = { { running_wwnr, INVALID_STATE, not_running_wwnr }, |
