]> Pileus Git - ~andy/linux/blobdiff - drivers/hwmon/w83627hf.c
Merge by Hand
[~andy/linux] / drivers / hwmon / w83627hf.c
index 494274d27f01dc560786b8e330542cc40494ba55..70ef926c3bd8341a8cb304455a6ec2e24cfd087f 100644 (file)
@@ -201,7 +201,6 @@ superio_exit(void)
 
 #define W83627HF_REG_PWM1 0x5A
 #define W83627HF_REG_PWM2 0x5B
-#define W83627HF_REG_PWMCLK12 0x5C
 
 #define W83627THF_REG_PWM1             0x01    /* 697HF and 637HF too */
 #define W83627THF_REG_PWM2             0x03    /* 697HF and 637HF too */
@@ -1046,11 +1045,10 @@ static int w83627hf_detect(struct i2c_adapter *adapter)
           client structure, even though we cannot fill it completely yet.
           But it allows us to access w83627hf_{read,write}_value. */
 
-       if (!(data = kmalloc(sizeof(struct w83627hf_data), GFP_KERNEL))) {
+       if (!(data = kzalloc(sizeof(struct w83627hf_data), GFP_KERNEL))) {
                err = -ENOMEM;
                goto ERROR1;
        }
-       memset(data, 0, sizeof(struct w83627hf_data));
 
        new_client = &data->client;
        i2c_set_clientdata(new_client, data);
@@ -1373,12 +1371,6 @@ static void w83627hf_init_client(struct i2c_client *client)
                        }
                }
 
-               if (type == w83627hf) {
-                       /* enable PWM2 control (can't hurt since PWM reg
-                          should have been reset to 0xff) */
-                       w83627hf_write_value(client, W83627HF_REG_PWMCLK12,
-                                           0x19);
-               }
                /* enable comparator mode for temp2 and temp3 so
                   alarm indication will work correctly */
                i = w83627hf_read_value(client, W83781D_REG_IRQ);