diff options
Diffstat (limited to 'linux/drivers/media/video/tw9910.c')
-rw-r--r-- | linux/drivers/media/video/tw9910.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/linux/drivers/media/video/tw9910.c b/linux/drivers/media/video/tw9910.c index 5c145085a..f75787594 100644 --- a/linux/drivers/media/video/tw9910.c +++ b/linux/drivers/media/video/tw9910.c @@ -879,10 +879,12 @@ static int tw9910_probe(struct i2c_client *client, const struct tw9910_scale_ctrl *scale; int i, ret; - info = client->dev.platform_data; - if (!info) + if (!client->dev.platform_data) return -EINVAL; + info = container_of(client->dev.platform_data, + struct tw9910_video_info, link); + if (!i2c_check_functionality(to_i2c_adapter(client->dev.parent), I2C_FUNC_SMBUS_BYTE_DATA)) { dev_err(&client->dev, |