From 91cc1e82143b939bfb4fce97429b07105333e146 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Mon, 10 Mar 2014 16:42:34 +1000 Subject: eventcomm: drop calculation of slot offset The kernel guarantees slots start at 0 Signed-off-by: Peter Hutterer Reviewed-by: Hans de Goede Reviewed-by: Benjamin Tissoires (cherry picked from commit 5b7e1726369d4973859996f225bec743c2e21288) --- src/eventcomm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/eventcomm.c b/src/eventcomm.c index a9a344b..5db7e48 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -98,7 +98,7 @@ last_mt_vals_slot(const SynapticsPrivate * priv) { struct eventcomm_proto_data *proto_data = (struct eventcomm_proto_data *) priv->proto_data; - int value = proto_data->cur_slot - proto_data->mtdev->caps.slot.minimum; + int value = proto_data->cur_slot; return value < priv->num_slots ? value : -1; } -- cgit v1.2.3