aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUwe Kleine-Koenig <ukleinek@strlen.de>2009-02-04 04:02:30 -0500
committerBryan Wu <cooloney@kernel.org>2009-02-04 04:02:30 -0500
commit45c4f2a0b6c6302c5617534b8189c0e9b5a4a048 (patch)
tree13f7088078cfedb735354df7aed9a6720e3302bf
parent2f95d5bd84bfbe8cf62cb1c4306354cfc139370b (diff)
Blackfin arch: explicit add a might sleep to gpio_free
According to the documentation gpio_free should only be called from task context only. To make this more explicit add a might sleep to all implementations. This patch changes the gpio_free implementations for the blackfin architecture. Signed-off-by: Uwe Kleine-Koenig <ukleinek@strlen.de> Cc: David Brownell <david-b@pacbell.net> Acked-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
-rw-r--r--arch/blackfin/kernel/bfin_gpio.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/blackfin/kernel/bfin_gpio.c b/arch/blackfin/kernel/bfin_gpio.c
index 0c4fc31029c2..05bf85ba7443 100644
--- a/arch/blackfin/kernel/bfin_gpio.c
+++ b/arch/blackfin/kernel/bfin_gpio.c
@@ -1081,6 +1081,8 @@ void bfin_gpio_free(unsigned gpio)
1081 if (check_gpio(gpio) < 0) 1081 if (check_gpio(gpio) < 0)
1082 return; 1082 return;
1083 1083
1084 might_sleep();
1085
1084 local_irq_save_hw(flags); 1086 local_irq_save_hw(flags);
1085 1087
1086 if (unlikely(!(reserved_gpio_map[gpio_bank(gpio)] & gpio_bit(gpio)))) { 1088 if (unlikely(!(reserved_gpio_map[gpio_bank(gpio)] & gpio_bit(gpio)))) {