mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2024-12-29 09:13:38 +00:00
OMAP/gpio: drop MPUIO static base
The OMAP GPIO driver hardcodes the MPIO chip base, but there is no point: we have already moved all consumers over to using descriptor look-ups. Drop the MPUIO GPIO base and use dynamic assignment. Root out the unused instances of the OMAP_MPUIO() macro and delete the unused OMAP_GPIO_IS_MPUIO() macro. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Tony Lindgren <tony@atomide.com> Tested-by: Janusz Krzysztofik <jmkrzyszt@gmail.com> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
This commit is contained in:
parent
c31071eabb
commit
968118fcf0
@ -51,11 +51,6 @@
|
||||
#define PALMTE_HDQ_GPIO 11
|
||||
#define PALMTE_HEADPHONES_GPIO 14
|
||||
#define PALMTE_SPEAKER_GPIO 15
|
||||
#define PALMTE_DC_GPIO OMAP_MPUIO(2)
|
||||
#define PALMTE_MMC_SWITCH_GPIO OMAP_MPUIO(4)
|
||||
#define PALMTE_MMC1_GPIO OMAP_MPUIO(6)
|
||||
#define PALMTE_MMC2_GPIO OMAP_MPUIO(7)
|
||||
#define PALMTE_MMC3_GPIO OMAP_MPUIO(11)
|
||||
|
||||
static const unsigned int palmte_keymap[] = {
|
||||
KEY(0, 0, KEY_F1), /* Calendar */
|
||||
|
@ -1048,15 +1048,14 @@ static int omap_gpio_chip_init(struct gpio_bank *bank, struct device *pm_dev)
|
||||
bank->chip.label = "mpuio";
|
||||
if (bank->regs->wkup_en)
|
||||
bank->chip.parent = &omap_mpuio_device.dev;
|
||||
bank->chip.base = OMAP_MPUIO(0);
|
||||
} else {
|
||||
label = devm_kasprintf(bank->chip.parent, GFP_KERNEL, "gpio-%d-%d",
|
||||
gpio, gpio + bank->width - 1);
|
||||
if (!label)
|
||||
return -ENOMEM;
|
||||
bank->chip.label = label;
|
||||
bank->chip.base = -1;
|
||||
}
|
||||
bank->chip.base = -1;
|
||||
bank->chip.ngpio = bank->width;
|
||||
|
||||
irq = &bank->chip.irq;
|
||||
|
@ -144,9 +144,6 @@
|
||||
|
||||
#define OMAP_MAX_GPIO_LINES 192
|
||||
|
||||
#define OMAP_MPUIO(nr) (OMAP_MAX_GPIO_LINES + (nr))
|
||||
#define OMAP_GPIO_IS_MPUIO(nr) ((nr) >= OMAP_MAX_GPIO_LINES)
|
||||
|
||||
#ifndef __ASSEMBLER__
|
||||
struct omap_gpio_reg_offs {
|
||||
u16 revision;
|
||||
|
Loading…
Reference in New Issue
Block a user