Skip to content

Commit

Permalink
gpiolib: allow nested threaded irqs for poll(2)
Browse files Browse the repository at this point in the history
The pca953x driver requires the use of threaded irqs as its irq
demultiplexer can sleep.  Our irq handler can be called from any context,
so use request_any_context_irq to allow threaded irqs as well.

Signed-off-by: Daniel Gl?ckner <dg@emlix.com>
Reported-by: Ian Jeffray <ian@jeffray.co.uk>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Daniel Gl?ckner authored and Linus Torvalds committed Aug 11, 2010
1 parent 5ba1821 commit 364fadb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/gpio/gpiolib.c
Original file line number Diff line number Diff line change
Expand Up @@ -386,9 +386,9 @@ static int gpio_setup_irq(struct gpio_desc *desc, struct device *dev,
}
}

ret = request_irq(irq, gpio_sysfs_irq, irq_flags,
ret = request_any_context_irq(irq, gpio_sysfs_irq, irq_flags,
"gpiolib", value_sd);
if (ret)
if (ret < 0)
goto free_id;

desc->flags |= gpio_flags;
Expand Down

0 comments on commit 364fadb

Please sign in to comment.