From ef964229202bd9afdf8aaa7bc60bba1d8e401531 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 1 Aug 2013 14:31:24 +0000 Subject: gpio-button-hotplug: use gpio_button_get_value() to fetch state. Signed-off-by: Yousong Zhou SVN-Revision: 37642 --- package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'package/kernel/gpio-button-hotplug') diff --git a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c index 7fe1690..9cbee21 100644 --- a/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c +++ b/package/kernel/gpio-button-hotplug/src/gpio-button-hotplug.c @@ -288,10 +288,7 @@ static void gpio_keys_polled_check_state(struct gpio_keys_button *button, { int state; - if (bdata->can_sleep) - state = !!gpio_get_value_cansleep(button->gpio); - else - state = !!gpio_get_value(button->gpio); + state = gpio_button_get_value(button, bdata); state = !!(state ^ button->active_low); if (state != bdata->last_state) { -- cgit v1.1