From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754512AbcEPRxr (ORCPT ); Mon, 16 May 2016 13:53:47 -0400 Received: from mail-pa0-f68.google.com ([209.85.220.68]:34279 "EHLO mail-pa0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754398AbcEPRxp (ORCPT ); Mon, 16 May 2016 13:53:45 -0400 From: Dmitry Torokhov X-Google-Original-From: Dmitry Torokhov Date: Mon, 16 May 2016 10:53:42 -0700 To: =?utf-8?B?5buW5bSH5qau?= Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, zac.hsieh@emc.com.tw, =?utf-8?B?6buD5LiW6bWsIOe2k+eQhg==?= , "'Charles Mooney'" , "'Agnes Cheng'" Subject: Re: [PATCH] Input: Change BTN_TOOL_FINGER flag when hover event trigger Message-ID: <20160516175342.GD12752@dtor-ws> References: <006901d1acea$8207d090$861771b0$@emc.com.tw> <00be01d1af65$ec37c290$c4a747b0$@emc.com.tw> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <00be01d1af65$ec37c290$c4a747b0$@emc.com.tw> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Kt, On Mon, May 16, 2016 at 07:27:25PM +0800, 廖崇榮 wrote: > > Only ABS_DISTANCE is not enough for upper OS to distingiush hover event be > triggered from object from faraway to and close touchpad surface or from > object prepare to leave the touchpad surface. Add BTN_TOOL_FINGER flag to > help it. > > object_from_faraway object_inside_hover_area > object_touch_surface > BTN_TOUCH 0 0 1 > BTN_TOOL_FINGER 0 1 1 > ABS_DISTANCE 0 1 0 > > Signed-off by: Duson Lin I was wondering if we could do without modifying all the drivers that are using input_mt_report_pointer_emulation(), by figuring out if we should be emitting BTN_TOOL_FINGER right there: "If device supports ABS_DISTANCE and does not support ABS_MT_DISTANCE and ABS_DISTANCE != 0 is reported in current frame and there are no other contacts then report BTN_TOOL_FINGER." Thanks. -- Dmitry