aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpio/gpio-mb86s7x.c
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2017-10-27 16:21:47 -0400
committerLinus Walleij <linus.walleij@linaro.org>2017-10-31 08:11:38 -0400
commite1289dba18bf905870a42b994c003586688d9353 (patch)
tree159add0401520544411252a2d1da5b13f99173c0 /drivers/gpio/gpio-mb86s7x.c
parent4714221b0c62e6dc3f7ac31d1f50478f16259e71 (diff)
gpio: mb86s7x: share with other SoCs as module
In order to reuse this driver for the Socionext Synquacer SC2A11 SoC, which inherited this IP from Fujitsu, remove the ARCH_MB86S7X Kconfig dependency, and revert the changes that prevent it from being built as a module. This reverts commits d65aa4b67b4f47f303bdeaef1e4d42ef18e6b293 and d5610e514e92144d19bd5e39e5cf3804bbf85f3e. Cc: Geliang Tang <geliangtang@gmail.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> [Folded in module_platform_driver() fixup] Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-mb86s7x.c')
-rw-r--r--drivers/gpio/gpio-mb86s7x.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-mb86s7x.c b/drivers/gpio/gpio-mb86s7x.c
index 94d772677ed6..b140806bded3 100644
--- a/drivers/gpio/gpio-mb86s7x.c
+++ b/drivers/gpio/gpio-mb86s7x.c
@@ -17,6 +17,7 @@
17#include <linux/io.h> 17#include <linux/io.h>
18#include <linux/init.h> 18#include <linux/init.h>
19#include <linux/clk.h> 19#include <linux/clk.h>
20#include <linux/module.h>
20#include <linux/err.h> 21#include <linux/err.h>
21#include <linux/errno.h> 22#include <linux/errno.h>
22#include <linux/ioport.h> 23#include <linux/ioport.h>
@@ -209,6 +210,7 @@ static const struct of_device_id mb86s70_gpio_dt_ids[] = {
209 { .compatible = "fujitsu,mb86s70-gpio" }, 210 { .compatible = "fujitsu,mb86s70-gpio" },
210 { /* sentinel */ } 211 { /* sentinel */ }
211}; 212};
213MODULE_DEVICE_TABLE(of, mb86s70_gpio_dt_ids);
212 214
213static struct platform_driver mb86s70_gpio_driver = { 215static struct platform_driver mb86s70_gpio_driver = {
214 .driver = { 216 .driver = {
@@ -218,5 +220,8 @@ static struct platform_driver mb86s70_gpio_driver = {
218 .probe = mb86s70_gpio_probe, 220 .probe = mb86s70_gpio_probe,
219 .remove = mb86s70_gpio_remove, 221 .remove = mb86s70_gpio_remove,
220}; 222};
223module_platform_driver(mb86s70_gpio_driver);
221 224
222builtin_platform_driver(mb86s70_gpio_driver); 225MODULE_DESCRIPTION("MB86S7x GPIO Driver");
226MODULE_ALIAS("platform:mb86s70-gpio");
227MODULE_LICENSE("GPL");