diff options
author | Mateusz Grzonka <mateusz.grzonka@intel.com> | 2023-02-02 12:27:01 +0100 |
---|---|---|
committer | Jes Sorensen <jes@trained-monkey.org> | 2023-03-02 16:51:02 +0100 |
commit | cc3df167c599d2ee0c132149c86fc0ad70d9f14e (patch) | |
tree | 77bea3d9a950958172d4bef531e192af190cc2bf /util.c | |
parent | Mdmonitor: Pass events to alert() using enums instead of strings (diff) | |
download | mdadm-cc3df167c599d2ee0c132149c86fc0ad70d9f14e.tar.xz mdadm-cc3df167c599d2ee0c132149c86fc0ad70d9f14e.zip |
Mdmonitor: Add helper functions
Add functions:
- is_email_event(),
- get_syslog_event_priority(),
- sprint_event_message(),
with kernel style comments containing more detailed descriptions.
Also update event syslog priorities to be consistent with man. MoveSpare event was described in man as priority info, while implemented as warning. Move event data into a struct, so that it is passed between different functions if needed.
Sort function declarations alphabetically and remove redundant alert() declaration.
Signed-off-by: Mateusz Grzonka <mateusz.grzonka@intel.com>
Acked-by: Coly Li <colyli@suse.de>
Signed-off-by: Jes Sorensen <jes@trained-monkey.org>
Diffstat (limited to 'util.c')
0 files changed, 0 insertions, 0 deletions