Back to home page

OSCL-LXR

 
 

    


0001 /*
0002  * arch/arm/plat-orion/include/plat/orion-gpio.h
0003  *
0004  * Marvell Orion SoC GPIO handling.
0005  *
0006  * This file is licensed under the terms of the GNU General Public
0007  * License version 2.  This program is licensed "as is" without any
0008  * warranty of any kind, whether express or implied.
0009  */
0010 
0011 #ifndef __PLAT_GPIO_H
0012 #define __PLAT_GPIO_H
0013 
0014 #include <linux/init.h>
0015 #include <linux/types.h>
0016 #include <linux/irqdomain.h>
0017 
0018 struct gpio_desc;
0019 
0020 /*
0021  * Orion-specific GPIO API extensions.
0022  */
0023 void orion_gpio_set_unused(unsigned pin);
0024 void orion_gpio_set_blink(unsigned pin, int blink);
0025 int orion_gpio_led_blink_set(struct gpio_desc *desc, int state,
0026     unsigned long *delay_on, unsigned long *delay_off);
0027 
0028 #define GPIO_INPUT_OK       (1 << 0)
0029 #define GPIO_OUTPUT_OK      (1 << 1)
0030 void orion_gpio_set_valid(unsigned pin, int mode);
0031 
0032 /* Initialize gpiolib. */
0033 void __init orion_gpio_init(int gpio_base, int ngpio,
0034                 void __iomem *base, int mask_offset,
0035                 int secondary_irq_base,
0036                 int irq[4]);
0037 
0038 #endif