[PATCH] hwmon: Static function fixes, 2 of 4
[powerpc.git] / drivers / hwmon / adm1025.c
index 5b21284..3ec1242 100644 (file)
@@ -50,9 +50,8 @@
 #include <linux/slab.h>
 #include <linux/jiffies.h>
 #include <linux/i2c.h>
-#include <linux/i2c-sensor.h>
-#include <linux/i2c-vid.h>
 #include <linux/hwmon.h>
+#include <linux/hwmon-vid.h>
 #include <linux/err.h>
 
 /*
@@ -67,7 +66,7 @@ static unsigned short normal_i2c[] = { 0x2c, 0x2d, 0x2e, I2C_CLIENT_END };
  * Insmod parameters
  */
 
-SENSORS_INSMOD_2(adm1025, ne1619);
+I2C_CLIENT_INSMOD_2(adm1025, ne1619);
 
 /*
  * The ADM1025 registers
@@ -332,11 +331,10 @@ static int adm1025_detect(struct i2c_adapter *adapter, int address, int kind)
        if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_BYTE_DATA))
                goto exit;
 
-       if (!(data = kmalloc(sizeof(struct adm1025_data), GFP_KERNEL))) {
+       if (!(data = kzalloc(sizeof(struct adm1025_data), GFP_KERNEL))) {
                err = -ENOMEM;
                goto exit;
        }
-       memset(data, 0, sizeof(struct adm1025_data));
 
        /* The common I2C client data is placed right before the
           ADM1025-specific data. */
@@ -474,7 +472,7 @@ static void adm1025_init_client(struct i2c_client *client)
        struct adm1025_data *data = i2c_get_clientdata(client);
        int i;
 
-       data->vrm = i2c_which_vrm();
+       data->vrm = vid_which_vrm();
 
        /*
         * Set high limits