Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 96973
b: refs/heads/master
c: 803a8d2
h: refs/heads/master
i:
  96971: 1ac6fe9
v: v3
  • Loading branch information
Michael Hennerich authored and Bryan Wu committed May 17, 2008
1 parent 2d28559 commit 963f29e
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 92322da9b568a5ddc3ab872491bdc0f1b47ef904
refs/heads/master: 803a8d2acbf220aeb27f0a98dacb36d4af3d6559
19 changes: 19 additions & 0 deletions trunk/arch/blackfin/kernel/bfin_gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1130,6 +1130,25 @@ void bfin_gpio_irq_prepare(unsigned gpio)

#else

int gpio_get_value(unsigned gpio)
{
unsigned long flags;
int ret;

if (unlikely(get_gpio_edge(gpio))) {
local_irq_save(flags);
set_gpio_edge(gpio, 0);
ret = get_gpio_data(gpio);
set_gpio_edge(gpio, 1);
local_irq_restore(flags);

return ret;
} else
return get_gpio_data(gpio);
}
EXPORT_SYMBOL(gpio_get_value);


int gpio_direction_input(unsigned gpio)
{
unsigned long flags;
Expand Down
1 change: 0 additions & 1 deletion trunk/include/asm-blackfin/gpio.h
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,6 @@ void gpio_set_value(unsigned gpio, int arg);
int gpio_get_value(unsigned gpio);

#ifndef BF548_FAMILY
#define gpio_get_value(gpio) get_gpio_data(gpio)
#define gpio_set_value(gpio, value) set_gpio_data(gpio, value)
#endif

Expand Down

0 comments on commit 963f29e

Please sign in to comment.