summaryrefslogtreecommitdiff
path: root/arch/blackfin
diff options
context:
space:
mode:
authorUwe Kleine-Koenig <ukleinek@strlen.de>2009-02-04 17:02:30 +0800
committerBryan Wu <cooloney@kernel.org>2009-02-04 17:02:30 +0800
commit45c4f2a0b6c6302c5617534b8189c0e9b5a4a048 (patch)
tree13f7088078cfedb735354df7aed9a6720e3302bf /arch/blackfin
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>
Diffstat (limited to 'arch/blackfin')
-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)
if (check_gpio(gpio) < 0)
return;
+ might_sleep();
+
local_irq_save_hw(flags);
if (unlikely(!(reserved_gpio_map[gpio_bank(gpio)] & gpio_bit(gpio)))) {