diff options
author | Clément Léger <clement.leger@bootlin.com> | 2022-06-17 12:35:48 +0200 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2022-06-28 09:18:08 +0200 |
commit | 4425205ea38bef591a6c800bb47082fc35e788a0 (patch) | |
tree | 21d0960bd87a89b848a3490a21aca3d3bcf6c88c /drivers/pinctrl/pinctrl-ocelot.c | |
parent | pinctrl: qcom: sc7280: Fix compile bug (diff) | |
download | linux-4425205ea38bef591a6c800bb47082fc35e788a0.tar.xz linux-4425205ea38bef591a6c800bb47082fc35e788a0.zip |
pinctrl: ocelot: allow building as a module
Set PINCTRL_OCELOT config option as a tristate and add
MODULE_DEVICE_TABLE()/MODULE_LICENSE() to export appropriate
information. Moreover, switch from builtin_platform_driver()
to module_platform_driver().
Signed-off-by: Clément Léger <clement.leger@bootlin.com>
Link: https://lore.kernel.org/r/20220617103548.490092-1-clement.leger@bootlin.com
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-ocelot.c')
-rw-r--r-- | drivers/pinctrl/pinctrl-ocelot.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-ocelot.c index 5f4a8c5c6650..349e063a04fa 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1889,6 +1889,7 @@ static const struct of_device_id ocelot_pinctrl_of_match[] = { { .compatible = "microchip,lan966x-pinctrl", .data = &lan966x_desc }, {}, }; +MODULE_DEVICE_TABLE(of, ocelot_pinctrl_of_match); static struct regmap *ocelot_pinctrl_create_pincfg(struct platform_device *pdev) { @@ -1984,4 +1985,5 @@ static struct platform_driver ocelot_pinctrl_driver = { }, .probe = ocelot_pinctrl_probe, }; -builtin_platform_driver(ocelot_pinctrl_driver); +module_platform_driver(ocelot_pinctrl_driver); +MODULE_LICENSE("Dual MIT/GPL"); |