gpio.h 688 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Generic GPIO API and pinmux table support
  3. *
  4. * Copyright (c) 2008 Magnus Damm
  5. *
  6. * This file is subject to the terms and conditions of the GNU General Public
  7. * License. See the file "COPYING" in the main directory of this archive
  8. * for more details.
  9. */
  10. #ifndef __ASM_ARCH_GPIO_H
  11. #define __ASM_ARCH_GPIO_H
  12. #include <linux/kernel.h>
  13. #include <linux/errno.h>
  14. #define ARCH_NR_GPIOS 1024
  15. #include <linux/sh_pfc.h>
  16. #ifdef CONFIG_GPIOLIB
  17. #define __ARM_GPIOLIB_TRIVIAL
  18. static inline int gpio_to_irq(unsigned gpio)
  19. {
  20. return __gpio_to_irq(gpio);
  21. }
  22. static inline int irq_to_gpio(unsigned int irq)
  23. {
  24. return -ENOSYS;
  25. }
  26. #endif /* CONFIG_GPIOLIB */
  27. #endif /* __ASM_ARCH_GPIO_H */