]> err.no Git - linux-2.6/blobdiff - drivers/hwmon/lm83.c
[PATCH] Clean up struct flock definitions
[linux-2.6] / drivers / hwmon / lm83.c
index 0223b4d2ce1dae9858b21d2ae8e6d9168c3a1575..d74b2c20c719376eea2c8231938f66be28a5f9d8 100644 (file)
@@ -32,7 +32,6 @@
 #include <linux/slab.h>
 #include <linux/jiffies.h>
 #include <linux/i2c.h>
-#include <linux/i2c-sensor.h>
 #include <linux/hwmon-sysfs.h>
 #include <linux/hwmon.h>
 #include <linux/err.h>
@@ -52,7 +51,7 @@ static unsigned short normal_i2c[] = { 0x18, 0x19, 0x1a,
  * Insmod parameters
  */
 
-SENSORS_INSMOD_1(lm83);
+I2C_CLIENT_INSMOD_1(lm83);
 
 /*
  * The LM83 registers
@@ -214,7 +213,7 @@ static int lm83_attach_adapter(struct i2c_adapter *adapter)
 {
        if (!(adapter->class & I2C_CLASS_HWMON))
                return 0;
-       return i2c_detect(adapter, &addr_data, lm83_detect);
+       return i2c_probe(adapter, &addr_data, lm83_detect);
 }
 
 /*
@@ -363,11 +362,8 @@ static int lm83_detach_client(struct i2c_client *client)
 
        hwmon_device_unregister(data->class_dev);
 
-       if ((err = i2c_detach_client(client))) {
-               dev_err(&client->dev,
-                   "Client deregistration failed, client not detached.\n");
+       if ((err = i2c_detach_client(client)))
                return err;
-       }
 
        kfree(data);
        return 0;