From 71f8f83c1e99eb2701eea8bdf0ceae8d7196a850 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Wed, 30 Aug 2006 15:23:16 -0300 Subject: Last patch wrongly applied. Reverting it... From: Mauro Carvalho Chehab Signed-off-by: Mauro Carvalho Chehab --- linux/drivers/media/video/saa7115.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'linux/drivers/media/video') diff --git a/linux/drivers/media/video/saa7115.c b/linux/drivers/media/video/saa7115.c index 84258d44b..c1cf58652 100644 --- a/linux/drivers/media/video/saa7115.c +++ b/linux/drivers/media/video/saa7115.c @@ -1057,9 +1057,6 @@ static int saa711x_get_v4lfmt(struct i2c_client *client, struct v4l2_format *fmt return 0; } -/* - * Sets Task B FIR filters to scale - works only on saa7114 or upper - */ static int saa711x_set_size(struct i2c_client *client, int width, int height) { struct saa711x_state *state = i2c_get_clientdata(client); @@ -1083,14 +1080,14 @@ static int saa711x_set_size(struct i2c_client *client, int width, int height) return -EINVAL; if (height != Vsrc) return -EINVAL; - - return 0; } + if (!saa711x_has_reg(state->ident,R_CC_B_HORIZ_OUTPUT_WINDOW_LENGTH)) + return 0; /* probably have a valid size, let's set it */ /* Set output width/height */ - /* width */ + saa711x_write(client, R_CC_B_HORIZ_OUTPUT_WINDOW_LENGTH, (u8) (width & 0xff)); saa711x_write(client, R_CD_B_HORIZ_OUTPUT_WINDOW_LENGTH_MSB, -- cgit v1.2.3