X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=include%2Flinux%2Fipmi_smi.h;h=c0633108d05dc3c4f5addcee52b5d44a66d86af4;hb=7616ee95f27a04fd5a6434e9ef4a82cec4b2807c;hp=53571288a9fc0187c1aaf43406a4c8ec9036a54d;hpb=0bb065f29bffc7895f0dbac1fc7d74b3a8d357a9;p=linux-2.6 diff --git a/include/linux/ipmi_smi.h b/include/linux/ipmi_smi.h index 53571288a9..c0633108d0 100644 --- a/include/linux/ipmi_smi.h +++ b/include/linux/ipmi_smi.h @@ -82,6 +82,13 @@ struct ipmi_smi_handlers { struct module *owner; + /* The low-level interface cannot start sending messages to + the upper layer until this function is called. This may + not be NULL, the lower layer must take the interface from + this call. */ + int (*start_processing)(void *send_info, + ipmi_smi_t new_intf); + /* Called to enqueue an SMI message to be sent. This operation is not allowed to fail. If an error occurs, it should report back the error in a received message. It may @@ -108,6 +115,13 @@ struct ipmi_smi_handlers poll for operations during things like crash dumps. */ void (*poll)(void *send_info); + /* Enable/disable firmware maintenance mode. Note that this + is *not* the modes defined, this is simply an on/off + setting. The message handler does the mode handling. Note + that this is called from interupt context, so it cannot + block. */ + void (*set_maintenance_mode)(void *send_info, int enable); + /* Tell the handler that we are using it/not using it. The message handler get the modules that this handler belongs to; this function lets the SMI claim any modules that it @@ -157,13 +171,17 @@ static inline void ipmi_demangle_device_id(unsigned char *data, } /* Add a low-level interface to the IPMI driver. Note that if the - interface doesn't know its slave address, it should pass in zero. */ + interface doesn't know its slave address, it should pass in zero. + The low-level interface should not deliver any messages to the + upper layer until the start_processing() function in the handlers + is called, and the lower layer must get the interface from that + call. */ int ipmi_register_smi(struct ipmi_smi_handlers *handlers, void *send_info, struct ipmi_device_id *device_id, struct device *dev, - unsigned char slave_addr, - ipmi_smi_t *intf); + const char *sysfs_name, + unsigned char slave_addr); /* * Remove a low-level interface from the IPMI driver. This will