summaryrefslogtreecommitdiff
path: root/drivers/gpio/gpio-tnetv107x.c
diff options
context:
space:
mode:
authorPhilip Avinash <avinashphilip@ti.com>2013-08-18 10:49:03 +0530
committerSekhar Nori <nsekhar@ti.com>2013-09-25 04:16:37 +0530
commitf1a4c52ff5913378b7baf05ac71f10282b341cf7 (patch)
treeca851636c3c3ea8bd510d70f4657631fff24260d /drivers/gpio/gpio-tnetv107x.c
parent834acb2af6e8255a026c754fac3d1bc3f32b0c1a (diff)
ARM: davinci: gpio: use gpiolib API instead of inline functions
Remove NEED_MACH_GPIO_H config select option for ARCH_DAVINCI to start using gpiolib interface for davinci platforms. This makes it easier to use the gpio driver on other platforms as it breaks dependency on mach-davinci. Latencies for gpio_get/set APIs will increase. On measurement, latency was found to have increased by 18 microsecond with gpiolib API as compared to inline APIs. Measurement was done on DA850 EVM for gpio_get_value() API by taking the printk timing across the call with interrupts disabled. inline gpio API with interrupt disabled [ 29.734337] before gpio_get [ 29.736847] after gpio_get Time difference 0.00251 gpio library with interrupt disabled [ 272.876763] before gpio_get [ 272.879291] after gpio_get Time difference 0.002528 Latency increased by (0.002528 - 0.00251) = 18 microsecond. While at it, remove GPIO_TYPE_DAVINCI enum definition as gpio-davinci.c is converted to Linux device driver model. Signed-off-by: Philip Avinash <avinashphilip@ti.com> Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> [nsekhar@ti.com: minor edits to commit message] Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'drivers/gpio/gpio-tnetv107x.c')
-rw-r--r--drivers/gpio/gpio-tnetv107x.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpio/gpio-tnetv107x.c b/drivers/gpio/gpio-tnetv107x.c
index 3fa3e2867e19..58445bb69106 100644
--- a/drivers/gpio/gpio-tnetv107x.c
+++ b/drivers/gpio/gpio-tnetv107x.c
@@ -15,6 +15,7 @@
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/gpio.h>
+#include <linux/platform_data/gpio-davinci.h>
#include <mach/common.h>
#include <mach/tnetv107x.h>