summaryrefslogtreecommitdiff
path: root/arch/blackfin/cpu
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-05-10 16:56:58 (GMT)
committerMike Frysinger <vapier@gentoo.org>2011-07-12 06:17:45 (GMT)
commit95b4b9d97a5bb6a93ec269cb9cf85e95a8f8295d (patch)
tree8717427f06e5ac86318f687936c91668187ba5cc /arch/blackfin/cpu
parent272d2fc2f5184740e5890e9afeb9fd78d308e51a (diff)
downloadu-boot-fsl-qoriq-95b4b9d97a5bb6a93ec269cb9cf85e95a8f8295d.tar.xz
Blackfin: gpio: optimize free path a little
When we aren't doing resource tracking, the gpio_free() function is a stub that simply returns, so pull this logic up a level and make it an inline stub in the header. Now we don't have to waste time at any of the call sites. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'arch/blackfin/cpu')
-rw-r--r--arch/blackfin/cpu/gpio.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/blackfin/cpu/gpio.c b/arch/blackfin/cpu/gpio.c
index cb96721..5674d42 100644
--- a/arch/blackfin/cpu/gpio.c
+++ b/arch/blackfin/cpu/gpio.c
@@ -665,6 +665,7 @@ int bfin_gpio_request(unsigned gpio, const char *label)
return 0;
}
+#ifdef CONFIG_BFIN_GPIO_TRACK
void bfin_gpio_free(unsigned gpio)
{
if (check_gpio(gpio) < 0)
@@ -679,6 +680,7 @@ void bfin_gpio_free(unsigned gpio)
set_label(gpio, "free");
}
+#endif
#ifdef BFIN_SPECIAL_GPIO_BANKS
DECLARE_RESERVED_MAP(special_gpio, gpio_bank(MAX_RESOURCES));