mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-28 23:24:50 +00:00
pinctrl: apple: use modulo rather than bitwise and
This expresses the intention clearer. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20211121165642.27883-11-joey.gouly@arm.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
parent
44bddfad97
commit
077db34c2b
1 changed files with 1 additions and 1 deletions
|
@ -252,7 +252,7 @@ static void apple_gpio_irq_ack(struct irq_data *data)
|
|||
struct apple_gpio_pinctrl *pctl = gpiochip_get_data(irq_data_get_irq_chip_data(data));
|
||||
unsigned int irqgrp = FIELD_GET(REG_GPIOx_GRP, apple_gpio_get_reg(pctl, data->hwirq));
|
||||
|
||||
writel(BIT(data->hwirq & 31), pctl->base + REG_IRQ(irqgrp, data->hwirq));
|
||||
writel(BIT(data->hwirq % 32), pctl->base + REG_IRQ(irqgrp, data->hwirq));
|
||||
}
|
||||
|
||||
static unsigned int apple_gpio_irq_type(unsigned int type)
|
||||
|
|
Loading…
Reference in a new issue