Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp6707384imm; Tue, 24 Jul 2018 01:24:43 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdRPna0oUIGpMMVzHbyPElhGydDNjd+kZ7U3Sz2MOmVnonznF09r7InwmWycGbLIOia9RUU X-Received: by 2002:a17:902:5a08:: with SMTP id q8-v6mr15863259pli.300.1532420683338; Tue, 24 Jul 2018 01:24:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532420683; cv=none; d=google.com; s=arc-20160816; b=OlgGqE3fODbkC0C2MIVv6plXz8mPk4Fq8yi3xrB1xGdxZpQhoT5gnCCBvNNPD7S9hI hLXrb7ZlB4nB7Dh3uFidOcjQgAgLIC0c7vCIli3hgKn2Mz6VxTREFU2yRPHfNSExarI1 SQbDkJUqrXOYxR3AI/EqT+s8sojCNcTqduEuHVw9UoBeutzRLc89nC+N7xGgLnnIrUIr mpUa9OpYNQGEQHnOOeQyFZd1v7ycbRf3wzCjKy7YeNdrNb3Pnw1k3I9xBfPSsPnNGcx4 4USZgMltAyuYX84jxtiF2hxbXSbUl5ibk9+o6M22coJZFQ5SDAxnCFUd62wIe0x3V8Cr sq5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:arc-authentication-results; bh=Ol5PE3bdZzm+SUyyEOUUcSGUlBOkB5pTp/BEJ8iyNWI=; b=FDYRhyZcx6dryL7icw2KarnASHHsYA+VOm0S+8EWNbBPurYmgtD2MmXBqd9Rrg9CbX fkZsSoHvwUVt38mZXzmAjuCVan2CIe5vn+cRtZkLqsPVc4H6KjVL3BL+6Zd6Jb6Bv7Tf n86Cup2Il62MFfP6F0S7Ld3DaA/k0YhUXX47t9bSWBvk8JImoNav+oLqKfk066P8OMdg Immcuo/OYapo556axqcipRpyKU550zHfP8Z5XAR4rFqxU4wiiMwQXMYfzgyLiqDwh+o/ lqUk/B2GnorJe94nL0SBEy2gT90njIYGzJyvSmuj+PEHqblmgwgj7jEQ3Gm0KjE8AJK3 m7ug== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h1-v6si10047113pld.485.2018.07.24.01.24.28; Tue, 24 Jul 2018 01:24:43 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388628AbeGXJ26 (ORCPT + 99 others); Tue, 24 Jul 2018 05:28:58 -0400 Received: from mail-qk0-f196.google.com ([209.85.220.196]:37213 "EHLO mail-qk0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388346AbeGXJ26 (ORCPT ); Tue, 24 Jul 2018 05:28:58 -0400 Received: by mail-qk0-f196.google.com with SMTP id t79-v6so2107622qke.4 for ; Tue, 24 Jul 2018 01:23:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Ol5PE3bdZzm+SUyyEOUUcSGUlBOkB5pTp/BEJ8iyNWI=; b=BC30fELFbREIxmTKlcByUmulYwyJ3+JJOF6Oyl441cOpyuiIA4XVCHNUQ+1jdjYKPL +N7grDP1BR4CQG16v8N2JAqiB7YSGkp+zJgG5SM0AuYALZ3X24If1HjKHy/FSFUC3/db VN6+HT4HgdPVvImPNAeabMsxLUzbEZoBNhd6fj7EVgtqb+jvfp5qTOlbtpVUvB3vLa/1 urxGWD1p/WFbxvtRu9alq3EckiUxLlEmN20V22pxCfch8Lwmtga2I/W1X8snKIMkzl0P wxRxuxvrW3sK725y7BIiUpE9m8T8sUNQP+m7pKNdchW+M12WjKYjelt6fNKC1pCN6YM+ IIHA== X-Gm-Message-State: AOUpUlFeOQJk1df/Zp8olz2I89RoRMdd9U00EVoY5/CXZ64CoZScuJr1 rzUjLI6IJzNl9fOEVXwr82haOuGWsXjArUmcOT0NpA== X-Received: by 2002:a37:afc5:: with SMTP id y188-v6mr14832324qke.273.1532420618649; Tue, 24 Jul 2018 01:23:38 -0700 (PDT) MIME-Version: 1.0 References: <20180720215122.23558-1-nick@shmanahar.org> <20180720215122.23558-9-nick@shmanahar.org> <20180723223347.GJ100814@dtor-ws> In-Reply-To: <20180723223347.GJ100814@dtor-ws> From: Benjamin Tissoires Date: Tue, 24 Jul 2018 10:23:27 +0200 Message-ID: Subject: Re: [PATCH v1 09/10] Input: atmel_mxt_ts - tool type is ignored when slot is closed To: Dmitry Torokhov Cc: Nick Dyer , lkml , "open list:HID CORE LAYER" , cphealy@gmail.com, nikita.yoush@cogentembedded.com, l.stach@pengutronix.de, nick.dyer@itdev.co.uk, Peter Hutterer Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 24, 2018 at 12:34 AM Dmitry Torokhov wrote: > > On Fri, Jul 20, 2018 at 10:51:21PM +0100, Nick Dyer wrote: > > From: Nick Dyer > > > > input_mt_report_slot_state() ignores the tool when the slot is closed. > > Remove the tool type from these function calls, which has caused a bit of > > confusion. > > Hmm, maybe we could introduce MT_TOOL_NONE or MT_TOOL_INACTIVE and get > rid of the 3rd parameter? It will require a bit of macro trickery for a > release or 2... I am not sure what would be the benefit of adding those new tools, if the input_mt code discards them. Do you want to forward them to the userspace with the release? This reminds me the discussion we had recently with the touchscreens releasing the slots with a MT_TOOL_PALM. Anyway, better include Peter as he will be using this new MT_TOOL. Cheers, Benjamin > > > > > Signed-off-by: Nick Dyer > > --- > > drivers/input/touchscreen/atmel_mxt_ts.c | 5 ++--- > > 1 file changed, 2 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers/input/touchscreen/atmel_mxt_ts.c > > index d7023d261458..c31af790ef84 100644 > > --- a/drivers/input/touchscreen/atmel_mxt_ts.c > > +++ b/drivers/input/touchscreen/atmel_mxt_ts.c > > @@ -838,8 +838,7 @@ static void mxt_proc_t9_message(struct mxt_data *data, u8 *message) > > * have happened. > > */ > > if (status & MXT_T9_RELEASE) { > > - input_mt_report_slot_state(input_dev, > > - MT_TOOL_FINGER, 0); > > + input_mt_report_slot_state(input_dev, 0, 0); > > mxt_input_sync(data); > > } > > > > @@ -855,7 +854,7 @@ static void mxt_proc_t9_message(struct mxt_data *data, u8 *message) > > input_report_abs(input_dev, ABS_MT_TOUCH_MAJOR, area); > > } else { > > /* Touch no longer active, close out slot */ > > - input_mt_report_slot_state(input_dev, MT_TOOL_FINGER, 0); > > + input_mt_report_slot_state(input_dev, 0, 0); > > } > > > > data->update_input = true; > > -- > > 2.17.1 > > > > -- > Dmitry