aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/ov6650.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/ov6650.c')
-rw-r--r--drivers/media/video/ov6650.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/media/video/ov6650.c b/drivers/media/video/ov6650.c
index b7cfeab0948..cf93de98806 100644
--- a/drivers/media/video/ov6650.c
+++ b/drivers/media/video/ov6650.c
@@ -754,7 +754,7 @@ static int ov6650_g_fmt(struct v4l2_subdev *sd,
754 754
755static bool is_unscaled_ok(int width, int height, struct v4l2_rect *rect) 755static bool is_unscaled_ok(int width, int height, struct v4l2_rect *rect)
756{ 756{
757 return (width > rect->width >> 1 || height > rect->height >> 1); 757 return width > rect->width >> 1 || height > rect->height >> 1;
758} 758}
759 759
760static u8 to_clkrc(struct v4l2_fract *timeperframe, 760static u8 to_clkrc(struct v4l2_fract *timeperframe,
@@ -840,8 +840,6 @@ static int ov6650_s_fmt(struct v4l2_subdev *sd, struct v4l2_mbus_framefmt *mf)
840 coma_mask |= COMA_BW | COMA_BYTE_SWAP | COMA_WORD_SWAP; 840 coma_mask |= COMA_BW | COMA_BYTE_SWAP | COMA_WORD_SWAP;
841 coma_set |= COMA_RAW_RGB | COMA_RGB; 841 coma_set |= COMA_RAW_RGB | COMA_RGB;
842 break; 842 break;
843 case 0:
844 break;
845 default: 843 default:
846 dev_err(&client->dev, "Pixel format not handled: 0x%x\n", code); 844 dev_err(&client->dev, "Pixel format not handled: 0x%x\n", code);
847 return -EINVAL; 845 return -EINVAL;
@@ -1176,7 +1174,6 @@ static int ov6650_probe(struct i2c_client *client,
1176 1174
1177 if (ret) { 1175 if (ret) {
1178 icd->ops = NULL; 1176 icd->ops = NULL;
1179 i2c_set_clientdata(client, NULL);
1180 kfree(priv); 1177 kfree(priv);
1181 } 1178 }
1182 1179
@@ -1187,7 +1184,6 @@ static int ov6650_remove(struct i2c_client *client)
1187{ 1184{
1188 struct ov6650 *priv = to_ov6650(client); 1185 struct ov6650 *priv = to_ov6650(client);
1189 1186
1190 i2c_set_clientdata(client, NULL);
1191 kfree(priv); 1187 kfree(priv);
1192 return 0; 1188 return 0;
1193} 1189}