From 0a861e9eb76c68b23be1aa4758269c5b412089a9 Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Tue, 12 May 2009 15:13:32 +0000 Subject: soc-camera: unify i2c camera device platform data Unify i2c camera device platform data to point to struct soc_camera_link for a smooth transition to soc-camera as a platform driver. Signed-off-by: Guennadi Liakhovetski Signed-off-by: Paul Mundt --- drivers/media/video/tw9910.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'drivers/media/video/tw9910.c') diff --git a/drivers/media/video/tw9910.c b/drivers/media/video/tw9910.c index a3994764399..aa5065ea09e 100644 --- a/drivers/media/video/tw9910.c +++ b/drivers/media/video/tw9910.c @@ -875,10 +875,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, -- cgit v1.2.3-70-g09d2