aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpio
diff options
context:
space:
mode:
authorCharulatha V <charu@ti.com>2011-05-25 01:53:50 -0400
committerTarun Kanti DebBarma <tarun.kanti@ti.com>2012-02-06 03:43:43 -0500
commitfad96ea825e7a8ee0c5b77292b470e4978157ee7 (patch)
tree1e013b7a881a3abaa6a6e6b1812bfdd38537cae1 /drivers/gpio
parentab985f0f7c2c0ef90b7c832f0c04f470dda0593d (diff)
gpio/omap: use pinctrl offset instead of macro
Use regs->pinctrl field instead of using the macro OMAP1510_GPIO_PIN_CONTROL Signed-off-by: Charulatha V <charu@ti.com> Reviewed-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: Tony Lindgren <tony@atomide.com> Reviewed-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'drivers/gpio')
-rw-r--r--drivers/gpio/gpio-omap.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
index a948351ad6c4..485b6b207ef9 100644
--- a/drivers/gpio/gpio-omap.c
+++ b/drivers/gpio/gpio-omap.c
@@ -490,15 +490,13 @@ static int omap_gpio_request(struct gpio_chip *chip, unsigned offset)
490 */ 490 */
491 _set_gpio_triggering(bank, offset, IRQ_TYPE_NONE); 491 _set_gpio_triggering(bank, offset, IRQ_TYPE_NONE);
492 492
493#ifdef CONFIG_ARCH_OMAP15XX 493 if (bank->regs->pinctrl) {
494 if (bank->method == METHOD_GPIO_1510) { 494 void __iomem *reg = bank->base + bank->regs->pinctrl;
495 void __iomem *reg;
496 495
497 /* Claim the pin for MPU */ 496 /* Claim the pin for MPU */
498 reg = bank->base + OMAP1510_GPIO_PIN_CONTROL;
499 __raw_writel(__raw_readl(reg) | (1 << offset), reg); 497 __raw_writel(__raw_readl(reg) | (1 << offset), reg);
500 } 498 }
501#endif 499
502 if (bank->regs->ctrl && !bank->mod_usage) { 500 if (bank->regs->ctrl && !bank->mod_usage) {
503 void __iomem *reg = bank->base + bank->regs->ctrl; 501 void __iomem *reg = bank->base + bank->regs->ctrl;
504 u32 ctrl; 502 u32 ctrl;