summaryrefslogtreecommitdiff
path: root/drivers/gpio/gpio-mvebu.c
diff options
context:
space:
mode:
authorGregory CLEMENT <gregory.clement@free-electrons.com>2012-12-19 15:31:11 +0400
committerGrant Likely <grant.likely@secretlab.ca>2012-12-20 02:15:14 +0400
commitbc1008cf7d243cf6ad87b1e16d3dbbd8c8d6f35c (patch)
treedeeda109d75da9c4035e766f59bdb1c4ffaa0fb0 /drivers/gpio/gpio-mvebu.c
parentd39a948fef2446cfac3749bbfcfdd536335c3764 (diff)
downloadlinux-bc1008cf7d243cf6ad87b1e16d3dbbd8c8d6f35c.tar.xz
gpio/mvebu-gpio: Make mvebu-gpio depend on OF_CONFIG
When building without device tree support (for the mv78x00 SoCs for example), the build failed because of_irq_count is undeclared. However mvebu-gpio is not designed to build without device tree support. So make it depends on OF_CONFIG, remove the #ifdef OF_CONFIG line and the platform_device_id. Tested on RD-78x00-mASA, DB-78460-BP, DB-88F6710-BP-DDR3, DB-MV784MP-GP, Mirabox and OpenBlocks AX3. Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/gpio/gpio-mvebu.c')
-rw-r--r--drivers/gpio/gpio-mvebu.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/drivers/gpio/gpio-mvebu.c b/drivers/gpio/gpio-mvebu.c
index d767b534c4af..7d9bd94be8d2 100644
--- a/drivers/gpio/gpio-mvebu.c
+++ b/drivers/gpio/gpio-mvebu.c
@@ -41,7 +41,6 @@
#include <linux/io.h>
#include <linux/of_irq.h>
#include <linux/of_device.h>
-#include <linux/platform_device.h>
#include <linux/pinctrl/consumer.h>
/*
@@ -469,19 +468,6 @@ static void mvebu_gpio_irq_handler(unsigned int irq, struct irq_desc *desc)
}
}
-static struct platform_device_id mvebu_gpio_ids[] = {
- {
- .name = "orion-gpio",
- }, {
- .name = "mv78200-gpio",
- }, {
- .name = "armadaxp-gpio",
- }, {
- /* sentinel */
- },
-};
-MODULE_DEVICE_TABLE(platform, mvebu_gpio_ids);
-
static struct of_device_id mvebu_gpio_of_match[] = {
{
.compatible = "marvell,orion-gpio",
@@ -555,9 +541,7 @@ static int mvebu_gpio_probe(struct platform_device *pdev)
mvchip->chip.base = id * MVEBU_MAX_GPIO_PER_BANK;
mvchip->chip.ngpio = ngpios;
mvchip->chip.can_sleep = 0;
-#ifdef CONFIG_OF
mvchip->chip.of_node = np;
-#endif
spin_lock_init(&mvchip->lock);
mvchip->membase = devm_request_and_ioremap(&pdev->dev, res);
@@ -698,7 +682,6 @@ static struct platform_driver mvebu_gpio_driver = {
.of_match_table = mvebu_gpio_of_match,
},
.probe = mvebu_gpio_probe,
- .id_table = mvebu_gpio_ids,
};
static int __init mvebu_gpio_init(void)