aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/video/wm8775.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/wm8775.c')
-rw-r--r--drivers/media/video/wm8775.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/video/wm8775.c b/drivers/media/video/wm8775.c
index c2e6d2e9f5f..8cb64f8a8a9 100644
--- a/drivers/media/video/wm8775.c
+++ b/drivers/media/video/wm8775.c
@@ -166,11 +166,10 @@ static int wm8775_attach(struct i2c_adapter *adapter, int address, int kind)
if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_BYTE_DATA))
return 0;
- client = kmalloc(sizeof(struct i2c_client), GFP_KERNEL);
+ client = kzalloc(sizeof(struct i2c_client), GFP_KERNEL);
if (client == 0)
return -ENOMEM;
- memset(client, 0, sizeof(struct i2c_client));
client->addr = address;
client->adapter = adapter;
client->driver = &i2c_driver;