Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-23 Thread Mauro Carvalho Chehab
Hi Laurent, Thanks for reviewing it. Em Wed, 23 Mar 2016 18:57:50 +0200 Laurent Pinchart escreveu: > On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: > > Now that the media_device can be used by multiple drivers, > > via devres, we need to be sure that it will be dropped only > > whe

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-23 Thread Laurent Pinchart
On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: > Now that the media_device can be used by multiple drivers, > via devres, we need to be sure that it will be dropped only > when all drivers stop using it. > > Signed-off-by: Mauro Carvalho Chehab > --- > > v2: The kref is now used onl

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-23 Thread Laurent Pinchart
Hi Shuah, On Monday 21 Mar 2016 07:42:34 Shuah Khan wrote: > On 03/21/2016 05:10 AM, Laurent Pinchart wrote: > > On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: > >> Now that the media_device can be used by multiple drivers, > >> via devres, we need to be sure that it will be dropped o

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-22 Thread Shuah Khan
On 03/18/2016 06:42 PM, Mauro Carvalho Chehab wrote: > Now that the media_device can be used by multiple drivers, > via devres, we need to be sure that it will be dropped only > when all drivers stop using it. > > Signed-off-by: Mauro Carvalho Chehab > --- > > v2: The kref is now used only when

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-21 Thread Shuah Khan
On 03/21/2016 05:58 AM, Mauro Carvalho Chehab wrote: > Em Mon, 21 Mar 2016 13:10:33 +0200 > Laurent Pinchart escreveu: > >> Hi Mauro, >> >> Thank you for the patch. >> >> On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: >>> Now that the media_device can be used by multiple drivers, >>>

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-21 Thread Shuah Khan
On 03/21/2016 05:10 AM, Laurent Pinchart wrote: > Hi Mauro, > > Thank you for the patch. > > On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: >> Now that the media_device can be used by multiple drivers, >> via devres, we need to be sure that it will be dropped only >> when all drivers

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-21 Thread Mauro Carvalho Chehab
Em Mon, 21 Mar 2016 13:10:33 +0200 Laurent Pinchart escreveu: > Hi Mauro, > > Thank you for the patch. > > On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: > > Now that the media_device can be used by multiple drivers, > > via devres, we need to be sure that it will be dropped only >

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-21 Thread Laurent Pinchart
Hi Mauro, Thank you for the patch. On Friday 18 Mar 2016 21:42:16 Mauro Carvalho Chehab wrote: > Now that the media_device can be used by multiple drivers, > via devres, we need to be sure that it will be dropped only > when all drivers stop using it. I've discussed this with Shuah previously an

[PATCH v2] [media] media-device: use kref for media_device instance

2016-03-18 Thread Mauro Carvalho Chehab
Now that the media_device can be used by multiple drivers, via devres, we need to be sure that it will be dropped only when all drivers stop using it. Signed-off-by: Mauro Carvalho Chehab --- v2: The kref is now used only when media_device is allocated via the media_device*_devress. This wa

Re: [PATCH v2] [media] media-device: use kref for media_device instance

2016-03-18 Thread Shuah Khan
On 03/18/2016 06:42 PM, Mauro Carvalho Chehab wrote: > Now that the media_device can be used by multiple drivers, > via devres, we need to be sure that it will be dropped only > when all drivers stop using it. > > Signed-off-by: Mauro Carvalho Chehab Looks good. Tested it doing bind/unbind, rmmo