Re: [PATCH 1/5] [RFC-HACK] pinctrl-single: init by postcore_initcall()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Christoph Fritz <chf.fritz@xxxxxxxxxxxxxx> [140522 16:07]:
> --- a/drivers/pinctrl/pinctrl-single.c
> +++ b/drivers/pinctrl/pinctrl-single.c
> @@ -2069,7 +2069,22 @@ static struct platform_driver pcs_driver = {
>  #endif
>  };
>  
> +#ifdef CONFIG_USE_OF
> +static int __init pcs_driver_drv_init(void)
> +{
> +       return platform_driver_register(&pcs_driver);
> +}
> +postcore_initcall(pcs_driver_drv_init);
> +
> +static void __exit pcs_driver_drv_exit(void)
> +{
> +       platform_driver_unregister(&pcs_driver);
> +}
> +module_exit(pcs_driver_drv_exit);
> +#else
>  module_platform_driver(pcs_driver);
> +#endif
> +

I would prefer to initialize all the drivers with module_init
and and if necessary, selected frameworks with subsys_initcall. 

In drivers/Makefile we do have painctrl before gpio, so this
too could be just module_init once the other drivers are fixed.

Regards,

Tony
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux