diff options
author | Paul Mackerras <paulus@samba.org> | 2005-10-30 21:37:12 -0500 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2005-10-30 21:37:12 -0500 |
commit | 23fd07750a789a66fe88cf173d52a18f1a387da4 (patch) | |
tree | 06fdd6df35fdb835abdaa9b754d62f6b84b97250 /drivers/i2c/chips/m41t00.c | |
parent | bd787d438a59266af3c9f6351644c85ef1dd21fe (diff) | |
parent | ed28f96ac1960f30f818374d65be71d2fdf811b0 (diff) |
Merge ../linux-2.6 by hand
Diffstat (limited to 'drivers/i2c/chips/m41t00.c')
-rw-r--r-- | drivers/i2c/chips/m41t00.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/i2c/chips/m41t00.c b/drivers/i2c/chips/m41t00.c index 3f14528a52a9..3df309ae44a6 100644 --- a/drivers/i2c/chips/m41t00.c +++ b/drivers/i2c/chips/m41t00.c | |||
@@ -174,13 +174,11 @@ m41t00_probe(struct i2c_adapter *adap, int addr, int kind) | |||
174 | struct i2c_client *client; | 174 | struct i2c_client *client; |
175 | int rc; | 175 | int rc; |
176 | 176 | ||
177 | client = kmalloc(sizeof(struct i2c_client), GFP_KERNEL); | 177 | client = kzalloc(sizeof(struct i2c_client), GFP_KERNEL); |
178 | if (!client) | 178 | if (!client) |
179 | return -ENOMEM; | 179 | return -ENOMEM; |
180 | 180 | ||
181 | memset(client, 0, sizeof(struct i2c_client)); | ||
182 | strncpy(client->name, M41T00_DRV_NAME, I2C_NAME_SIZE); | 181 | strncpy(client->name, M41T00_DRV_NAME, I2C_NAME_SIZE); |
183 | client->flags = I2C_DF_NOTIFY; | ||
184 | client->addr = addr; | 182 | client->addr = addr; |
185 | client->adapter = adap; | 183 | client->adapter = adap; |
186 | client->driver = &m41t00_driver; | 184 | client->driver = &m41t00_driver; |