acpiphp: Execute ACPI _REG method for hotadded devices
[linux/fpc-iii.git] / arch / arm / mach-ns9xxx / include / mach / gpio.h
blob5eb349032579b0dd6c1cf9474c147af26ff0c2e0
1 /*
2 * arch/arm/mach-ns9xxx/include/mach/gpio.h
4 * Copyright (C) 2007 by Digi International Inc.
5 * All rights reserved.
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License version 2 as published by
9 * the Free Software Foundation.
11 #ifndef __ASM_ARCH_GPIO_H
12 #define __ASM_ARCH_GPIO_H
14 #include <asm/errno.h>
16 int gpio_request(unsigned gpio, const char *label);
18 void gpio_free(unsigned gpio);
20 int ns9xxx_gpio_configure(unsigned gpio, int inv, int func);
22 int gpio_direction_input(unsigned gpio);
24 int gpio_direction_output(unsigned gpio, int value);
26 int gpio_get_value(unsigned gpio);
28 void gpio_set_value(unsigned gpio, int value);
31 * ns9xxx can use gpio pins to trigger an irq, but it's not generic
32 * enough to be supported by the gpio_to_irq/irq_to_gpio interface
34 static inline int gpio_to_irq(unsigned gpio)
36 return -EINVAL;
39 static inline int irq_to_gpio(unsigned irq)
41 return -EINVAL;
44 /* get the cansleep() stubs */
45 #include <asm-generic/gpio.h>
47 #endif /* ifndef __ASM_ARCH_GPIO_H */