summaryrefslogtreecommitdiff
path: root/include/linux/ipmi_smi.h
diff options
context:
space:
mode:
authorCorey Minyard <cminyard@mvista.com>2022-04-12 23:38:51 +0300
committerCorey Minyard <cminyard@mvista.com>2022-05-12 18:00:03 +0300
commit9824117dd964ecebf5d81990dbf21dfb56445049 (patch)
treef834dceb64c91da0d8a0e0ec1aa252f5e90f7035 /include/linux/ipmi_smi.h
parent7602b957e2404e5f98d9a40b68f1fd27f0028712 (diff)
downloadlinux-9824117dd964ecebf5d81990dbf21dfb56445049.tar.xz
ipmi: Add an intializer for ipmi_smi_msg struct
There was a "type" element added to this structure, but some static values were missed. The default value will be zero, which is correct, but create an initializer for the type and initialize the type properly in the initializer to avoid future issues. Reported-by: Joe Wiese <jwiese@rackspace.com> Signed-off-by: Corey Minyard <cminyard@mvista.com>
Diffstat (limited to 'include/linux/ipmi_smi.h')
-rw-r--r--include/linux/ipmi_smi.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/ipmi_smi.h b/include/linux/ipmi_smi.h
index 9277d21c2690..5d69820d8b02 100644
--- a/include/linux/ipmi_smi.h
+++ b/include/linux/ipmi_smi.h
@@ -125,6 +125,12 @@ struct ipmi_smi_msg {
void (*done)(struct ipmi_smi_msg *msg);
};
+#define INIT_IPMI_SMI_MSG(done_handler) \
+{ \
+ .done = done_handler, \
+ .type = IPMI_SMI_MSG_TYPE_NORMAL \
+}
+
struct ipmi_smi_handlers {
struct module *owner;