summaryrefslogtreecommitdiff
path: root/arch/arm/include
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2015-04-22 11:31:22 +0200
committerHans de Goede <hdegoede@redhat.com>2015-05-04 16:51:53 +0200
commitf9b7a04bc8aae9b1ffe35c8cc90e1a59f618a9ab (patch)
tree9a076843fd7ae13a1b1564c8af8175e442c69aa1 /arch/arm/include
parent2fcf033d36618da4c86de135a0d447fd3bbaf8ea (diff)
downloadu-boot-imx-f9b7a04bc8aae9b1ffe35c8cc90e1a59f618a9ab.zip
u-boot-imx-f9b7a04bc8aae9b1ffe35c8cc90e1a59f618a9ab.tar.gz
u-boot-imx-f9b7a04bc8aae9b1ffe35c8cc90e1a59f618a9ab.tar.bz2
sunxi: axp: Add driver-model support to the axp_gpio code
Add driver-model support to the axp_gpio code, note that this needs a small tweak to the driver-model version of sunxi_name_to_gpio to deal with the vbus detect and enable pins which are not standard numbered gpios. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Ian Campbell <ijc@hellion.org.uk>
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/arch-sunxi/gpio.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/arm/include/asm/arch-sunxi/gpio.h b/arch/arm/include/asm/arch-sunxi/gpio.h
index f743a73..d5caeed 100644
--- a/arch/arm/include/asm/arch-sunxi/gpio.h
+++ b/arch/arm/include/asm/arch-sunxi/gpio.h
@@ -203,8 +203,10 @@ enum sunxi_gpio_number {
#define SUNXI_GPIO_PULL_DOWN 2
/* Virtual AXP0 GPIOs */
-#define SUNXI_GPIO_AXP0_VBUS_DETECT 8
-#define SUNXI_GPIO_AXP0_VBUS_ENABLE 9
+#define SUNXI_GPIO_AXP0_PREFIX "AXP0-"
+#define SUNXI_GPIO_AXP0_VBUS_DETECT 4
+#define SUNXI_GPIO_AXP0_VBUS_ENABLE 5
+#define SUNXI_GPIO_AXP0_GPIO_COUNT 6
void sunxi_gpio_set_cfgbank(struct sunxi_gpio *pio, int bank_offset, u32 val);
void sunxi_gpio_set_cfgpin(u32 pin, u32 val);