Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
orion-gpio.h
Go to the documentation of this file.
1 /*
2  * arch/arm/plat-orion/include/plat/orion-gpio.h
3  *
4  * Marvell Orion SoC GPIO handling.
5  *
6  * This file is licensed under the terms of the GNU General Public
7  * License version 2. This program is licensed "as is" without any
8  * warranty of any kind, whether express or implied.
9  */
10 
11 #ifndef __PLAT_GPIO_H
12 #define __PLAT_GPIO_H
13 
14 #include <linux/init.h>
15 #include <linux/types.h>
16 #include <linux/irqdomain.h>
17 /*
18  * Orion-specific GPIO API extensions.
19  */
20 void orion_gpio_set_unused(unsigned pin);
21 void orion_gpio_set_blink(unsigned pin, int blink);
22 int orion_gpio_led_blink_set(unsigned gpio, int state,
23  unsigned long *delay_on, unsigned long *delay_off);
24 
25 #define GPIO_INPUT_OK (1 << 0)
26 #define GPIO_OUTPUT_OK (1 << 1)
27 void orion_gpio_set_valid(unsigned pin, int mode);
28 
29 /* Initialize gpiolib. */
30 void __init orion_gpio_init(struct device_node *np,
31  int gpio_base, int ngpio,
32  void __iomem *base, int mask_offset,
33  int secondary_irq_base,
34  int irq[4]);
35 
36 void __init orion_gpio_of_init(int irq_gpio_base);
37 #endif