diff options
author | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2008-07-22 11:22:41 +0000 |
---|---|---|
committer | juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2008-07-22 11:22:41 +0000 |
commit | 92aeca315789b390e50bc605f267eaf372c49801 (patch) | |
tree | 5099b8a4615d1f7cefa2b8004e97def92655ffb1 /target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch | |
parent | d9fc823912a9cdff5f80c0334aa3e2d79e98f617 (diff) |
[brcm47xx] fix compile error (closes #3799)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@11907 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch')
-rw-r--r-- | target/linux/generic-2.6/patches-2.6.25/961-backport_gpio_define_gpio_valid.patch | 8 |
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 2e826d43f4..58e65efa7f 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. */ |