[PATCH] soc: mediatek: SCPSYS: use module_platform_driver

Sascha Hauer s.hauer at pengutronix.de
Tue Dec 15 07:42:03 PST 2015


On Tue, Dec 15, 2015 at 03:30:01PM +0100, Arnd Bergmann wrote:
> On Tuesday 15 December 2015 15:16:06 Sascha Hauer wrote:
> > @@ -542,6 +542,7 @@ static const struct of_device_id of_scpsys_match_tbl[] = {
> >  };
> >  
> >  static struct platform_driver scpsys_drv = {
> > +       .probe = scpsys_probe,
> >         .driver = {
> >                 .name = "mtk-scpsys",
> >                 .owner = THIS_MODULE,
> > @@ -549,4 +550,4 @@ static struct platform_driver scpsys_drv = {
> >         },
> >  };
> >  
> > -module_platform_driver_probe(scpsys_drv, scpsys_probe);
> > +module_platform_driver(scpsys_drv);
> > 
> 
> Good idea, but I wonder why there is no remove function in the
> driver. Do we also need to make the module non-removable and
> set .suppress_bind_attrs, or is all of the probe function
> reversible through devm_* helpers?

pm domains currently can't be unregistered, removal of this driver is
not supported. The driver can't be compiled as a module.

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 |



More information about the linux-arm-kernel mailing list