Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-08 Thread Herbert Xu
On Thu, Sep 08, 2016 at 05:47:13PM +0200, Romain Perier wrote: > > I was wondering something. hwrng_unregister does not check the kref > reference counter of the object... so technically if the current > rng_device is in use, with or without devm... calling > platform->remove will break the driver

Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-08 Thread Romain Perier
Le 07/09/2016 16:45, PrasannaKumar Muralidharan a écrit : On 7 September 2016 at 19:53, Romain Perier wrote: Hello, Le 06/09/2016 18:31, PrasannaKumar Muralidharan a écrit : Use devm_hwrng_register instead of hwrng_register. It avoids the need to handle unregistration explicitly from the

Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-07 Thread Romain Perier
Le 07/09/2016 16:45, PrasannaKumar Muralidharan a écrit : On 7 September 2016 at 19:53, Romain Perier wrote: Hello, Le 06/09/2016 18:31, PrasannaKumar Muralidharan a écrit : Use devm_hwrng_register instead of hwrng_register. It avoids the need to handle unregistration explicitly from the

Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-07 Thread PrasannaKumar Muralidharan
On 7 September 2016 at 19:53, Romain Perier wrote: > Hello, > > > Le 06/09/2016 18:31, PrasannaKumar Muralidharan a écrit : >>> >>> Use devm_hwrng_register instead of hwrng_register. It avoids the need >>> to handle unregistration explicitly from the remove function. >>> >>> Signed-off-by: Romain

Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-07 Thread Romain Perier
Hello, Le 06/09/2016 18:31, PrasannaKumar Muralidharan a écrit : Use devm_hwrng_register instead of hwrng_register. It avoids the need to handle unregistration explicitly from the remove function. Signed-off-by: Romain Perier --- drivers/char/hw_random/omap-rng.c | 4 +--- 1 file changed, 1

Re: [PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-06 Thread PrasannaKumar Muralidharan
> Use devm_hwrng_register instead of hwrng_register. It avoids the need > to handle unregistration explicitly from the remove function. > > Signed-off-by: Romain Perier > --- > drivers/char/hw_random/omap-rng.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/drivers/ch

[PATCH 4/9] hwrng: omap - Use the managed device resource API for registration

2016-09-06 Thread Romain Perier
Use devm_hwrng_register instead of hwrng_register. It avoids the need to handle unregistration explicitly from the remove function. Signed-off-by: Romain Perier --- drivers/char/hw_random/omap-rng.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/char/hw_random/oma