pinctrl: tegra: Move drivers registration to arch_init level
There is a bug in regards to deferred probing within the drivers core that causes GPIO-driver to suspend after its users. The bug appears if GPIO-driver probe is getting deferred, which happens after introducing dependency on PINCTRL-driver for the GPIO-driver by defining "gpio-ranges" property in device-tree. The bug in the drivers core is old (more than 4 years now) and is well known, unfortunately there is no easy fix for it. The good news is that we can workaround the deferred probe issue by changing GPIO / PINCTRL drivers registration order and hence by moving PINCTRL driver registration to the arch_init level and GPIO to the subsys_init. Signed-off-by: Dmitry Osipenko <digetx@gmail.com> Acked-by: Stefan Agner <stefan@agner.ch> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
Родитель
973232e2a3
Коммит
1e0813ee55
|
@ -1868,4 +1868,9 @@ static struct platform_driver tegra114_pinctrl_driver = {
|
|||
},
|
||||
.probe = tegra114_pinctrl_probe,
|
||||
};
|
||||
builtin_platform_driver(tegra114_pinctrl_driver);
|
||||
|
||||
static int __init tegra114_pinctrl_init(void)
|
||||
{
|
||||
return platform_driver_register(&tegra114_pinctrl_driver);
|
||||
}
|
||||
arch_initcall(tegra114_pinctrl_init);
|
||||
|
|
|
@ -2080,4 +2080,9 @@ static struct platform_driver tegra124_pinctrl_driver = {
|
|||
},
|
||||
.probe = tegra124_pinctrl_probe,
|
||||
};
|
||||
builtin_platform_driver(tegra124_pinctrl_driver);
|
||||
|
||||
static int __init tegra124_pinctrl_init(void)
|
||||
{
|
||||
return platform_driver_register(&tegra124_pinctrl_driver);
|
||||
}
|
||||
arch_initcall(tegra124_pinctrl_init);
|
||||
|
|
|
@ -2277,4 +2277,9 @@ static struct platform_driver tegra20_pinctrl_driver = {
|
|||
},
|
||||
.probe = tegra20_pinctrl_probe,
|
||||
};
|
||||
builtin_platform_driver(tegra20_pinctrl_driver);
|
||||
|
||||
static int __init tegra20_pinctrl_init(void)
|
||||
{
|
||||
return platform_driver_register(&tegra20_pinctrl_driver);
|
||||
}
|
||||
arch_initcall(tegra20_pinctrl_init);
|
||||
|
|
|
@ -1582,4 +1582,9 @@ static struct platform_driver tegra210_pinctrl_driver = {
|
|||
},
|
||||
.probe = tegra210_pinctrl_probe,
|
||||
};
|
||||
builtin_platform_driver(tegra210_pinctrl_driver);
|
||||
|
||||
static int __init tegra210_pinctrl_init(void)
|
||||
{
|
||||
return platform_driver_register(&tegra210_pinctrl_driver);
|
||||
}
|
||||
arch_initcall(tegra210_pinctrl_init);
|
||||
|
|
|
@ -2503,4 +2503,9 @@ static struct platform_driver tegra30_pinctrl_driver = {
|
|||
},
|
||||
.probe = tegra30_pinctrl_probe,
|
||||
};
|
||||
builtin_platform_driver(tegra30_pinctrl_driver);
|
||||
|
||||
static int __init tegra30_pinctrl_init(void)
|
||||
{
|
||||
return platform_driver_register(&tegra30_pinctrl_driver);
|
||||
}
|
||||
arch_initcall(tegra30_pinctrl_init);
|
||||
|
|
Загрузка…
Ссылка в новой задаче