]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/media/video/ov9640.c
Merge branch 'v4l_for_2.6.35' of git://git.kernel.org/pub/scm/linux/kernel/git/mcheha...
[net-next-2.6.git] / drivers / media / video / ov9640.c
index 36599a65f54851759f47a5a412bd5fdc629b8e1f..7ce9e05b47815c764baa56d087dab3d47b4b228d 100644 (file)
@@ -614,10 +614,10 @@ static int ov9640_try_fmt(struct v4l2_subdev *sd,
        return 0;
 }
 
-static int ov9640_enum_fmt(struct v4l2_subdev *sd, int index,
+static int ov9640_enum_fmt(struct v4l2_subdev *sd, unsigned int index,
                           enum v4l2_mbus_pixelcode *code)
 {
-       if ((unsigned int)index >= ARRAY_SIZE(ov9640_codes))
+       if (index >= ARRAY_SIZE(ov9640_codes))
                return -EINVAL;
 
        *code = ov9640_codes[index];
@@ -783,7 +783,6 @@ static int ov9640_probe(struct i2c_client *client,
 
        if (ret) {
                icd->ops = NULL;
-               i2c_set_clientdata(client, NULL);
                kfree(priv);
        }
 
@@ -794,7 +793,6 @@ static int ov9640_remove(struct i2c_client *client)
 {
        struct ov9640_priv *priv = i2c_get_clientdata(client);
 
-       i2c_set_clientdata(client, NULL);
        kfree(priv);
        return 0;
 }