Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-10 Thread Rui Miguel Silva
Hi, On Thu, Aug 10, 2017 at 04:56:50PM +0300, Sakari Ailus wrote: > Hi Hans, > > On Thu, Aug 10, 2017 at 03:02:46PM +0200, Hans Verkuil wrote: > > > @@ -534,25 +534,20 @@ static int gb_lights_light_v4l2_register(struct > > > gb_light *light) > > > { > > > struct gb_connection *connection =

Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-10 Thread Sakari Ailus
Hi Hans, On Thu, Aug 10, 2017 at 03:02:46PM +0200, Hans Verkuil wrote: > > @@ -534,25 +534,20 @@ static int gb_lights_light_v4l2_register(struct > > gb_light *light) > > { > > struct gb_connection *connection = get_conn_from_light(light); > > struct device *dev = >bundle->dev; > > -

Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-10 Thread Hans Verkuil
On 10/08/17 15:02, Hans Verkuil wrote: > On 09/08/17 13:15, Sakari Ailus wrote: >> From: Rui Miguel Silva >> >> We are allocating memory for the v4l2 flash configuration structure and >> leak it in the normal path. Just use the stack for this as we do not >> use it outside of

Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-10 Thread Hans Verkuil
On 09/08/17 13:15, Sakari Ailus wrote: > From: Rui Miguel Silva > > We are allocating memory for the v4l2 flash configuration structure and > leak it in the normal path. Just use the stack for this as we do not > use it outside of this function. I'm not sure why this is part

Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-09 Thread Sakari Ailus
Hi Rui, On Wed, Aug 09, 2017 at 02:20:02PM +0100, Rui Miguel Silva wrote: > Hi Sakari, > On Wed, Aug 09, 2017 at 02:15:53PM +0300, Sakari Ailus wrote: > > From: Rui Miguel Silva > > > > We are allocating memory for the v4l2 flash configuration structure and > > leak it in the

Re: [PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-09 Thread Rui Miguel Silva
Hi Sakari, On Wed, Aug 09, 2017 at 02:15:53PM +0300, Sakari Ailus wrote: > From: Rui Miguel Silva > > We are allocating memory for the v4l2 flash configuration structure and > leak it in the normal path. Just use the stack for this as we do not > use it outside of this

[PATCH v2 1/3] staging: greybus: light: fix memory leak in v4l2 register

2017-08-09 Thread Sakari Ailus
From: Rui Miguel Silva We are allocating memory for the v4l2 flash configuration structure and leak it in the normal path. Just use the stack for this as we do not use it outside of this function. Fixes: 2870b52bae4c ("greybus: lights: add lights implementation") Reported-by: