add gpio_is_valid(); ifxmips, mmc_gpio was not building correctly
authorJohn Crispin <john@openwrt.org>
Thu, 25 Sep 2008 16:27:54 +0000 (16:27 +0000)
committerJohn Crispin <john@openwrt.org>
Thu, 25 Sep 2008 16:27:54 +0000 (16:27 +0000)
SVN-Revision: 12704

target/linux/ifxmips/files/include/asm-mips/mach-ifxmips/gpio.h

index 76d42c2e3b4b55925f7338b9394040833d5d3923..0dece372d13f2449e0ffbf682d45554dbb339b0d 100644 (file)
@@ -86,5 +86,9 @@ static inline void gpio_set_value_cansleep(unsigned gpio, int value) {
         gpio_set_value(gpio, value);
 }
 
-#endif
+static inline int gpio_is_valid(int number)
+{
+       return ((unsigned)number) < 8;
+}
 
+#endif