linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git] / drivers / char / ipmi / ipmi_poweroff.c
index 8d941db..49c09ae 100644 (file)
  *  with this program; if not, write to the Free Software Foundation, Inc.,
  *  675 Mass Ave, Cambridge, MA 02139, USA.
  */
+#include <linux/config.h>
 #include <linux/module.h>
 #include <linux/moduleparam.h>
 #include <linux/proc_fs.h>
 #include <linux/string.h>
 #include <linux/completion.h>
-#include <linux/pm.h>
 #include <linux/kdev_t.h>
 #include <linux/ipmi.h>
 #include <linux/ipmi_smi.h>
 
 #define PFX "IPMI poweroff: "
 
+/* Where to we insert our poweroff function? */
+extern void (*pm_power_off)(void);
+
 /* Definitions for controlling power off (if the system supports it).  It
  * conveniently matches the IPMI chassis control values. */
 #define IPMI_CHASSIS_POWER_DOWN                0       /* power down, the default. */
@@ -345,7 +348,7 @@ static int ipmi_dell_chassis_detect (ipmi_user_t user)
 {
        const char ipmi_version_major = ipmi_version & 0xF;
        const char ipmi_version_minor = (ipmi_version >> 4) & 0xF;
-       const char mfr[3] = DELL_IANA_MFR_ID;
+       const char mfr[3]=DELL_IANA_MFR_ID;
        if (!memcmp(mfr, &mfg_id, sizeof(mfr)) &&
            ipmi_version_major <= 1 &&
            ipmi_version_minor < 5)
@@ -463,7 +466,7 @@ static void ipmi_poweroff_function (void)
 
 /* Wait for an IPMI interface to be installed, the first one installed
    will be grabbed by this code and used to perform the powerdown. */
-static void ipmi_po_new_smi(int if_num, struct device *device)
+static void ipmi_po_new_smi(int if_num)
 {
        struct ipmi_system_interface_addr smi_addr;
        struct kernel_ipmi_msg            send_msg;