Re: [PATCH 2/2] ov9640: fix OmniVision OV9640 sensor driver's I2C remove function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi David

On Fri, 3 Dec 2010, David Cohen wrote:

> OmniVision OV9640 driver wasn't deallocating properly its private data
> as it was requesting the V4L2 subdev struct address instead of the priv
> struct's one. This patch fixes such problem.

This is a bug-fix, that should go into 2.6.37, but it depends on your 
previous patch, adding to_ov9640_sensor(), which isn't a fix, and so has 
to wait until 2.6.38. Could you please respin this patch without that 
macro and resend?

Thanks
Guennadi

> 
> Signed-off-by: David Cohen <dacohen@xxxxxxxxx>
> ---
>  drivers/media/video/ov9640.c |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/media/video/ov9640.c b/drivers/media/video/ov9640.c
> index c6d8e8a..7628754 100644
> --- a/drivers/media/video/ov9640.c
> +++ b/drivers/media/video/ov9640.c
> @@ -788,7 +788,8 @@ static int ov9640_probe(struct i2c_client *client,
>  
>  static int ov9640_remove(struct i2c_client *client)
>  {
> -	struct ov9640_priv *priv = i2c_get_clientdata(client);
> +	struct v4l2_subdev *sd = i2c_get_clientdata(client);
> +	struct ov9640_priv *priv = to_ov9640_sensor(sd);
>  
>  	kfree(priv);
>  	return 0;
> -- 
> 1.7.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-media" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux