[PATCH] i2c: kzalloc conversion, other drivers
[safe/jmp/linux-2.6] / drivers / i2c / chips / m41t00.c
index 778d7e1..3df309a 100644 (file)
@@ -42,7 +42,6 @@ static struct i2c_client_address_data addr_data = {
        .normal_i2c             = normal_addr,
        .probe                  = ignore,
        .ignore                 = ignore,
-       .force                  = ignore,
 };
 
 ulong
@@ -145,7 +144,7 @@ m41t00_set_tlet(ulong arg)
        return;
 }
 
-ulong  new_time;
+static ulong   new_time;
 
 DECLARE_TASKLET_DISABLED(m41t00_tasklet, m41t00_set_tlet, (ulong)&new_time);
 
@@ -175,13 +174,11 @@ m41t00_probe(struct i2c_adapter *adap, int addr, int kind)
        struct i2c_client *client;
        int rc;
 
-       client = kmalloc(sizeof(struct i2c_client), GFP_KERNEL);
+       client = kzalloc(sizeof(struct i2c_client), GFP_KERNEL);
        if (!client)
                return -ENOMEM;
 
-       memset(client, 0, sizeof(struct i2c_client));
        strncpy(client->name, M41T00_DRV_NAME, I2C_NAME_SIZE);
-       client->flags = I2C_DF_NOTIFY;
        client->addr = addr;
        client->adapter = adap;
        client->driver = &m41t00_driver;