From: kfx Date: Tue, 23 Apr 2013 06:46:43 +0000 (+0800) Subject: keyboard: fixed bug 'report repeatedly wake-up event in suspend' X-Git-Tag: firefly_0821_release~7233 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b3097fc14b20606e5ae2b2b035d2f7087b454000;p=firefly-linux-kernel-4.4.55.git keyboard: fixed bug 'report repeatedly wake-up event in suspend' --- diff --git a/drivers/input/keyboard/rk29_keys.c b/drivers/input/keyboard/rk29_keys.c index eba9f0eb3124..28554103017b 100755 --- a/drivers/input/keyboard/rk29_keys.c +++ b/drivers/input/keyboard/rk29_keys.c @@ -258,13 +258,11 @@ static irqreturn_t keys_isr(int irq, void *dev_id) BUG_ON(irq != gpio_to_irq(button->gpio)); if(button->wakeup == 1 && bdata->ddata->in_suspend == true){ + bdata->state = 1; key_dbg(bdata, "wakeup: %skey[%s]: report ev[%d] state[%d]\n", (button->gpio == INVALID_GPIO)?"ad":"io", button->desc, button->code, bdata->state); - input_event(input, type, button->code, 1); - input_sync(input); - input_event(input, type, button->code, 0); + input_event(input, type, button->code, bdata->state); input_sync(input); - return IRQ_HANDLED; } bdata->long_press_count = 0; mod_timer(&bdata->timer,