Steve Sakoman | 3b97152 | 2012-06-04 05:35:34 +0000 | [diff] [blame] | 1 | /* |
Wolfgang Denk | 1a45966 | 2013-07-08 09:37:19 +0200 | [diff] [blame] | 2 | * SPDX-License-Identifier: GPL-2.0+ |
Steve Sakoman | 3b97152 | 2012-06-04 05:35:34 +0000 | [diff] [blame] | 3 | */ |
| 4 | #ifndef _GPIO_AM33xx_H |
| 5 | #define _GPIO_AM33xx_H |
| 6 | |
| 7 | #include <asm/omap_gpio.h> |
| 8 | |
Axel Lin | 87bd05d | 2013-06-21 18:54:25 +0800 | [diff] [blame] | 9 | #define OMAP_MAX_GPIO 128 |
| 10 | |
Steve Sakoman | 3b97152 | 2012-06-04 05:35:34 +0000 | [diff] [blame] | 11 | #define AM33XX_GPIO0_BASE 0x44E07000 |
| 12 | #define AM33XX_GPIO1_BASE 0x4804C000 |
| 13 | #define AM33XX_GPIO2_BASE 0x481AC000 |
| 14 | #define AM33XX_GPIO3_BASE 0x481AE000 |
| 15 | |
Lokesh Vutla | b5e01ee | 2013-12-10 15:02:23 +0530 | [diff] [blame] | 16 | #define GPIO_22 22 |
| 17 | |
| 18 | /* GPIO CTRL register */ |
| 19 | #define GPIO_CTRL_DISABLEMODULE_SHIFT 0 |
| 20 | #define GPIO_CTRL_DISABLEMODULE_MASK (1 << 0) |
| 21 | #define GPIO_CTRL_ENABLEMODULE GPIO_CTRL_DISABLEMODULE_MASK |
| 22 | |
| 23 | /* GPIO OUTPUT ENABLE register */ |
| 24 | #define GPIO_OE_ENABLE(x) (1 << x) |
| 25 | |
| 26 | /* GPIO SETDATAOUT register */ |
| 27 | #define GPIO_SETDATAOUT(x) (1 << x) |
Steve Sakoman | 3b97152 | 2012-06-04 05:35:34 +0000 | [diff] [blame] | 28 | #endif /* _GPIO_AM33xx_H */ |