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 <sambley@codeaurora.org>
diff --git a/drivers/gpio/gpio-msm-common.c b/drivers/gpio/gpio-msm-common.c
index da3d106..9a9a783 100644
--- a/drivers/gpio/gpio-msm-common.c
+++ b/drivers/gpio/gpio-msm-common.c
@@ -611,12 +611,12 @@
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;