]> err.no Git - linux-2.6/commitdiff
hwmon: (dme1737) Fix some merge conflicts
authorMark M. Hoffman <mhoffman@lightlink.com>
Thu, 11 Oct 2007 02:32:50 +0000 (22:32 -0400)
committerMark M. Hoffman <mhoffman@lightlink.com>
Thu, 11 Oct 2007 02:45:54 +0000 (22:45 -0400)
class_dev -> hwmon_dev

Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
1  2 
drivers/hwmon/dme1737.c

index 14ebbfb3b14b55edfffa584571a7650b35f8888c,63cee3b6f9bf017154098721a5632046ba55ee96..ec8edd2a8cbda29565db35d03a17d90f75660d7c
@@@ -1983,9 -2041,10 +2041,10 @@@ static int dme1737_i2c_detect(struct i2
        }
  
        /* Register device */
-       data->hwmon_dev = hwmon_device_register(&client->dev);
 -      data->class_dev = hwmon_device_register(dev);
 -      if (IS_ERR(data->class_dev)) {
++      data->hwmon_dev = hwmon_device_register(dev);
 +      if (IS_ERR(data->hwmon_dev)) {
+               dev_err(dev, "Failed to register device.\n");
 -              err = PTR_ERR(data->class_dev);
 +              err = PTR_ERR(data->hwmon_dev);
                goto exit_remove;
        }
  
@@@ -2022,29 -2066,16 +2066,16 @@@ static int dme1737_i2c_attach_adapter(s
                return 0;
        }
  
-       return i2c_probe(adapter, &addr_data, dme1737_detect);
+       return i2c_probe(adapter, &addr_data, dme1737_i2c_detect);
  }
  
- static int dme1737_detach_client(struct i2c_client *client)
+ static int dme1737_i2c_detach_client(struct i2c_client *client)
  {
        struct dme1737_data *data = i2c_get_clientdata(client);
-       int ix, err;
+       int err;
  
 -      hwmon_device_unregister(data->class_dev);
 +      hwmon_device_unregister(data->hwmon_dev);
-       for (ix = 0; ix < ARRAY_SIZE(dme1737_fan_group); ix++) {
-               if (data->has_fan & (1 << ix)) {
-                       sysfs_remove_group(&client->dev.kobj,
-                                          &dme1737_fan_group[ix]);
-               }
-       }
-       for (ix = 0; ix < ARRAY_SIZE(dme1737_pwm_group); ix++) {
-               if (data->has_pwm & (1 << ix)) {
-                       sysfs_remove_group(&client->dev.kobj,
-                                          &dme1737_pwm_group[ix]);
-               }
-       }
-       sysfs_remove_group(&client->dev.kobj, &dme1737_group);
+       dme1737_remove_files(&client->dev);
  
        if ((err = i2c_detach_client(client))) {
                return err;