lkml.org 
[lkml]   [2013]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 10/10] drivers: misc: use module_platform_driver_probe()
On Thu, Mar 14, 2013 at 01:58:05PM +0000, Arnd Bergmann wrote:
> On Thursday 14 March 2013, Fabio Porcedda wrote:
> > This patch converts the drivers to use the
> > module_platform_driver_probe() macro which makes the code smaller and
> > a bit simpler.
> >
> > Signed-off-by: Fabio Porcedda <fabio.porcedda@gmail.com>
> > Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> > Cc: Arnd Bergmann <arnd@arndb.de>
> > ---
> > drivers/misc/atmel_pwm.c | 12 +-----------
> > drivers/misc/ep93xx_pwm.c | 13 +------------
> > 2 files changed, 2 insertions(+), 23 deletions(-)
>
> The patch itself seems fine, but there are two issues around it:
>
> * The PWM drivers should really get moved to drivers/pwm and converted to the new
> PWM subsystem. I don't know if Hartley or Hans-Christian have plans to do
> that already.
>
> * Regarding the use of module_platform_driver_probe, I'm a little worried about
> the interactions with deferred probing. I don't think there are any regressions,
> but we should probably make people aware that one cannot return -EPROBE_DEFER
> from a platform_driver_probe function.

I'm worried about this aswell. I think platform_driver_probe shouldn't
be used anymore. Even if a driver does not explicitly make use of
-EPROBE_DEFER, it leaks in very quickly if a driver for example uses a
regulator and just returns the error value from regulator_get.

Sascha

--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |


\
 
 \ /
  Last update: 2013-03-14 15:43    [W:0.134 / U:1.356 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site