linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Input: cros_ec_keyb: mask out extra flags in event_type
@ 2019-06-14  6:54 Ting Shen
  2019-06-14 18:27 ` Enrico Granata
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Ting Shen @ 2019-06-14  6:54 UTC (permalink / raw)
  To: LKML
  Cc: Nicolas Boichat, Pi-Hsun Shih, Enrico Granata, Ting Shen,
	Enric Balletbo i Serra, Heiko Stuebner, Guenter Roeck,
	Brian Norris, Benson Leung, Dmitry Torokhov, linux-input,
	Colin Ian King

http://crosreview.com/1341159 added a EC_MKBP_HAS_MORE_EVENTS flag to
the event_type field, the receiver side should mask out this extra bit when
processing the event.

Signed-off-by: Ting Shen <phoenixshen@chromium.org>

---

 drivers/input/keyboard/cros_ec_keyb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/input/keyboard/cros_ec_keyb.c b/drivers/input/keyboard/cros_ec_keyb.c
index d5600118159835..38cb6d82d8fe67 100644
--- a/drivers/input/keyboard/cros_ec_keyb.c
+++ b/drivers/input/keyboard/cros_ec_keyb.c
@@ -237,7 +237,7 @@ static int cros_ec_keyb_work(struct notifier_block *nb,
 	if (queued_during_suspend && !device_may_wakeup(ckdev->dev))
 		return NOTIFY_OK;
 
-	switch (ckdev->ec->event_data.event_type) {
+	switch (ckdev->ec->event_data.event_type & EC_MKBP_EVENT_TYPE_MASK) {
 	case EC_MKBP_EVENT_KEY_MATRIX:
 		pm_wakeup_event(ckdev->dev, 0);
 
-- 
2.22.0.rc2.383.gf4fbbf30c2-goog

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-06-18  8:43 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-14  6:54 [PATCH] Input: cros_ec_keyb: mask out extra flags in event_type Ting Shen
2019-06-14 18:27 ` Enrico Granata
2019-06-14 18:55   ` Dmitry Torokhov
2019-06-14 19:09     ` Benson Leung
2019-06-14 19:19       ` Dmitry Torokhov
2019-06-14 19:32 ` Benson Leung
2019-06-18  8:43 ` Enric Balletbo i Serra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).