From patchwork Mon Jun 13 07:29:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?5buW5bSH5qau?= X-Patchwork-Id: 9172155 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6DC5C60573 for ; Mon, 13 Jun 2016 07:29:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6084822230 for ; Mon, 13 Jun 2016 07:29:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5507226861; Mon, 13 Jun 2016 07:29:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CFC6322230 for ; Mon, 13 Jun 2016 07:29:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965023AbcFMH3G (ORCPT ); Mon, 13 Jun 2016 03:29:06 -0400 Received: from emcscan.emc.com.tw ([192.72.220.5]:25854 "EHLO emcscan.emc.com.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964986AbcFMH3E convert rfc822-to-8bit (ORCPT ); Mon, 13 Jun 2016 03:29:04 -0400 Received: from unknown (HELO elanic) ([192.168.10.6]) by emcscan.emc.com.tw with ESMTP; 13 Jun 2016 15:29:01 +0800 Received: from elanic (elanic.emc.com.tw [127.0.0.1]) by elanic (Postfix) with ESMTP id B16083CA956; Mon, 13 Jun 2016 15:22:26 +0800 (CST) Received: from nb92073 (unknown [192.168.33.46]) by elanic (Postfix) with ESMTP id 90A963C99F9; Mon, 13 Jun 2016 15:22:26 +0800 (CST) From: =?big5?B?ufmxUrph?= To: , , Cc: , , , "'jeff'" References: <1464493153-2509-1-git-send-email-kt.liao@emc.com.tw> In-Reply-To: Subject: RE: [PATCH] Input: /input/input-mt.c Emit BTN_TOO_FINGER in function input_mt_report_pointer_emulation if touchpad meets hover condition Signed-off-by: KT Liao Date: Mon, 13 Jun 2016 15:29:00 +0800 Message-ID: <003901d1c545$4104e470$c30ead50$@emc.com.tw> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 14.0 Thread-Index: AQJtdif+5g6AgzTuWlaxrGut3MWlf56ent6AgBD+ohA= Content-Language: zh-tw Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi Dmitry, We would like to follow up if there is any update or feedback for this patch. Thanks & B.R KT -----Original Message----- From: 廖崇榮 [mailto:kt.liao@emc.com.tw] Sent: Thursday, June 02, 2016 7:57 PM To: 'linux-kernel@vger.kernel.org'; 'linux-input@vger.kernel.org'; 'dmitry.torokhov@gmail.com' Cc: 'phoenix@emc.com.tw'; 'jeff.chung@emc.com.tw'; 'charliemooney@google.com'; 'agnescheng@google.com'; 'jeff' Subject: RE: [PATCH] Input: /input/input-mt.c Emit BTN_TOO_FINGER in function input_mt_report_pointer_emulation if touchpad meets hover condition Signed-off-by: KT Liao Hi Dmitry, I up-streamed the patch last Sunday, please let me know if you have other concern. Thanks your support KT -----Original Message----- From: KT Liao [mailto:ktalex.liao@gmail.com] Sent: Sunday, May 29, 2016 11:39 AM To: linux-kernel@vger.kernel.org; linux-input@vger.kernel.org; dmitry.torokhov@gmail.com Cc: phoenix@emc.com.tw; kt.liao@emc.com.tw; jeff.chung@emc.com.tw; charliemooney@google.com Subject: [PATCH] Input: /input/input-mt.c Emit BTN_TOO_FINGER in function input_mt_report_pointer_emulation if touchpad meets hover condition Signed-off-by: KT Liao --- drivers/input/input-mt.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) int x = input_mt_get_value(oldest, ABS_MT_POSITION_X); -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/input/input-mt.c b/drivers/input/input-mt.c index 54fce56..b89aaa7 100644 --- a/drivers/input/input-mt.c +++ b/drivers/input/input-mt.c @@ -218,8 +218,17 @@ void input_mt_report_pointer_emulation(struct input_dev *dev, bool use_count) } input_event(dev, EV_KEY, BTN_TOUCH, count > 0); - if (use_count) + + if (use_count) { + if (count == 0 && + !test_bit(ABS_MT_DISTANCE, dev->absbit) && + test_bit(ABS_DISTANCE, dev->absbit) && + input_abs_get_val(dev, ABS_DISTANCE) != 0) { + count = 1; + } input_mt_report_finger_count(dev, count); + } + if (oldest) {