From 169b6a7a6e91e1ea32136681b475cbaf2074bf35 Mon Sep 17 00:00:00 2001 From: Anton Vorontsov Date: Mon, 28 Apr 2008 02:14:47 -0700 Subject: gpiochip_reserve() Add a new function gpiochip_reserve() to reserve ranges of gpios that platform code has pre-allocated. That is, this marks gpio numbers which will be claimed by drivers that haven't yet been loaded, and thus are not available for dynamic gpio number allocation. [akpm@linux-foundation.org: remove unneeded __must_check] [david-b@pacbell.net: don't export gpiochip_reserve (section fix)] Signed-off-by: Anton Vorontsov Signed-off-by: David Brownell Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/asm-generic/gpio.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/asm-generic/gpio.h') diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h index 464c5b334dc..ecf675a59d2 100644 --- a/include/asm-generic/gpio.h +++ b/include/asm-generic/gpio.h @@ -74,6 +74,7 @@ struct gpio_chip { extern const char *gpiochip_is_requested(struct gpio_chip *chip, unsigned offset); +extern int __init __must_check gpiochip_reserve(int start, int ngpio); /* add/remove chips */ extern int gpiochip_add(struct gpio_chip *chip); -- cgit v1.2.3