diff options
author | Jeff Garzik <jgarzik@pobox.com> | 2006-01-17 10:29:06 -0500 |
---|---|---|
committer | Jeff Garzik <jgarzik@pobox.com> | 2006-01-17 10:29:06 -0500 |
commit | ea9b395fe20ac74be788f415af2622ac8f0c35c7 (patch) | |
tree | d1653e1a4cbe360aa7132ea4e29ab92a02038224 /drivers/media/video/saa7114.c | |
parent | 61420e147a706ee7c7a902008045547fb2a2a330 (diff) | |
parent | 1bc4ccfff8675adc3d96f91245eb7e2dc0043ca9 (diff) |
Merge branch 'upstream'
Diffstat (limited to 'drivers/media/video/saa7114.c')
-rw-r--r-- | drivers/media/video/saa7114.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/drivers/media/video/saa7114.c b/drivers/media/video/saa7114.c index d9f50e2f7b9..fd0a4b4ef01 100644 --- a/drivers/media/video/saa7114.c +++ b/drivers/media/video/saa7114.c @@ -852,22 +852,19 @@ saa7114_detect_client (struct i2c_adapter *adapter, 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_saa7114; - client->flags = I2C_CLIENT_ALLOW_USE; strlcpy(I2C_NAME(client), "saa7114", sizeof(I2C_NAME(client))); - decoder = kmalloc(sizeof(struct saa7114), GFP_KERNEL); + decoder = kzalloc(sizeof(struct saa7114), GFP_KERNEL); if (decoder == NULL) { kfree(client); return -ENOMEM; } - memset(decoder, 0, sizeof(struct saa7114)); decoder->norm = VIDEO_MODE_NTSC; decoder->input = -1; decoder->enable = 1; @@ -1204,11 +1201,11 @@ saa7114_detach_client (struct i2c_client *client) /* ----------------------------------------------------------------------- */ static struct i2c_driver i2c_driver_saa7114 = { - .owner = THIS_MODULE, - .name = "saa7114", + .driver = { + .name = "saa7114", + }, .id = I2C_DRIVERID_SAA7114, - .flags = I2C_DF_NOTIFY, .attach_adapter = saa7114_attach_adapter, .detach_client = saa7114_detach_client, |