From ee438e2c979fb5da67ccded1caafffb849e1ec88 Mon Sep 17 00:00:00 2001 From: Sathish Ambley Date: Fri, 23 Mar 2012 13:26:56 -0700 Subject: [PATCH] gpio: msm: Assign device node to the gpio chip Remove the redundant free irq range call that was overwriting the allocated irq base. Assign the device node to the gpio chip, this allows for translation to happen from gpio property specified in the device tree to the gpio number. Change-Id: I5a593190aeced6d8fd174d295d9fdc58899c7d72 Signed-off-by: Sathish Ambley --- drivers/gpio/gpio-msm-common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpio/gpio-msm-common.c b/drivers/gpio/gpio-msm-common.c index da3d1062f8d..9a9a7837444 100644 --- a/drivers/gpio/gpio-msm-common.c +++ b/drivers/gpio/gpio-msm-common.c @@ -611,12 +611,12 @@ int __init msm_gpio_of_init(struct device_node *node, return domain->irq_base; } - domain->irq_base = irq_domain_find_free_range(0, NR_MSM_GPIOS); domain->nr_irq = NR_MSM_GPIOS; domain->of_node = of_node_get(node); domain->priv = &msm_gpio; domain->ops = &msm_gpio_irq_domain_ops; irq_domain_add(domain); + msm_gpio.gpio_chip.of_node = of_node_get(node); pr_debug("%s: irq_base = %u\n", __func__, domain->irq_base); return 0;