summaryrefslogtreecommitdiff
path: root/target/linux/generic-2.6
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2008-07-22 11:22:41 +0000
committerGabor Juhos <juhosg@openwrt.org>2008-07-22 11:22:41 +0000
commite6baf82abd46a0869a1ea77b9334345b402e615c (patch)
tree9306b2b482008ad5f61692fb5b62f22061f8b742 /target/linux/generic-2.6
parent5d5385684def58aabb1e2138747a56c4c6a581af (diff)
downloadmtk-20170518-e6baf82abd46a0869a1ea77b9334345b402e615c.zip
mtk-20170518-e6baf82abd46a0869a1ea77b9334345b402e615c.tar.gz
mtk-20170518-e6baf82abd46a0869a1ea77b9334345b402e615c.tar.bz2
fix compile error (closes #3799)
SVN-Revision: 11907
Diffstat (limited to 'target/linux/generic-2.6')
-rw-r--r--target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch8
1 files changed, 6 insertions, 2 deletions
diff --git a/target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch b/target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch
index 2e826d4..58e65ef 100644
--- a/target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch
+++ b/target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch
@@ -121,16 +121,20 @@ index 7e77b6f..464c5b3 100644
struct seq_file;
struct module;
-@@ -99,6 +105,12 @@ extern int __gpio_cansleep(unsigned gpio);
+@@ -99,6 +105,16 @@ extern int __gpio_cansleep(unsigned gpio);
#else
-+static inline int gpio_is_valid(int number)
++static inline int __gpio_is_valid(int number)
+{
+ /* only non-negative numbers are valid */
+ return number >= 0;
+}
+
++#ifndef gpio_is_valid
++#define gpio_is_valid __gpio_is_valid
++#endif
++
/* platforms that don't directly support access to GPIOs through I2C, SPI,
* or other blocking infrastructure can use these wrappers.
*/