Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1803065pxb; Sat, 23 Jan 2021 06:10:50 -0800 (PST) X-Google-Smtp-Source: ABdhPJzXy42yUWHJw3mqxmXOh6bL1pF+Zb8gbxg2xUy5gSuvpXDRVNffmpsssx1byg4s83JPpdlG X-Received: by 2002:a17:906:5ad0:: with SMTP id x16mr1497800ejs.135.1611411050436; Sat, 23 Jan 2021 06:10:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611411050; cv=none; d=google.com; s=arc-20160816; b=iYxlENOrnLQJ+FMnjL/etc+vjan4FJFvQXUH/Jg96REgSTlHq3W1ioR5t1GIaikDQ/ 2lhLd8nCPhf6+jel7qU+cLHmNInFhMbj7DWF+WMuYhlzLR/T4UBuv/tuKDuHn7e3gwDk EGzQmyYmB3JBYqsrc4GbrJLJ6RcDXn0Fl4Pnv2lRDKgm4dxzOhsQRiAVAX3L1ZE1gTHx a69XU/9L2gEBnlLipkHSzshOfc/gTabr3OGtaATQCf7wzPQG+U5/MRhD9eEr6TH1bVK2 REbdhPb7SpEbPUGFbwqXXELNhjoU0VBsTQkbOoCax1SCSokoJjzP/iQJltcJRadXdptx Ph5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=LI2hVcEVJK1l9uCzeyjkqP1h/8vAAXInB5SI6rzxlfQ=; b=MZL+R4S4XTv/taAxiJKd1GaMota5maGhVnwOc5V2IGpWGflJy8yAii4za6HmWq2Yxw I2fg0xx+O/MZDQyKJNyU1M7MbMGwOxayXblJXN6iAiINrAjKOy9w/4vTUdmGpwiQnEVO 1PDKMt1Nykvl6HiMv2fFS0RJULVDg5IMUF30ChFX+JO0O4bxqGo3OofkKAxMgnxmDq+y nCS5lCZbGFcu3r+YpNLcw4isX0mHbl/w9tzmnLhHegsTtOScTlZpYrmVCEG5ImMfVGt9 MqtfkOWLFtikgwq+R2kDJu/+2m092d9GeRWQqSBfcEhXQLP2ChghUy2DjQitY3kNNwI/ sXrg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GmCSo731; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id sb9si4318106ejb.655.2021.01.23.06.10.25; Sat, 23 Jan 2021 06:10:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=GmCSo731; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725921AbhAWOIl (ORCPT + 99 others); Sat, 23 Jan 2021 09:08:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46344 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725550AbhAWOIh (ORCPT ); Sat, 23 Jan 2021 09:08:37 -0500 Received: from mail-lj1-x229.google.com (mail-lj1-x229.google.com [IPv6:2a00:1450:4864:20::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7BDA4C0613D6; Sat, 23 Jan 2021 06:07:53 -0800 (PST) Received: by mail-lj1-x229.google.com with SMTP id a25so8712253ljn.0; Sat, 23 Jan 2021 06:07:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=LI2hVcEVJK1l9uCzeyjkqP1h/8vAAXInB5SI6rzxlfQ=; b=GmCSo731Xgv9wFf9egwK59HBJId9/h3545uMHo85hgK5xcLrSxpclZ0ifIqCT1NhWd AJCYR3S8SToVTkHDHfd/vORXQfnCoXRkYpWSXKav3yh2hCO9qFgjRlDC8xH/fM9I+RGg 74oXQ89ig1ITlMwNeCXDxFetrEuR7OeRaXAYzS3Fs6utXeppAPs8R58S58Ad2FyDG//u GOpRjhr+mykcoEcfESW5Q/66WBH8inGgq5v2DExSHumt1oIA838mwmk7JdrRA+m05t8u pIVQI/tD4m/nMBPYvK9kX3/al7mERnf+J0za0PDnq2KR2uoOA371KdK+5OGsELfgytjI e+dQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=LI2hVcEVJK1l9uCzeyjkqP1h/8vAAXInB5SI6rzxlfQ=; b=UQ4/IX2uPOudzVyk3jPy9ia74JuazSV0z9i1f/ZmKIfA2pL1ivCxCXo9W7GJ3SQ6XI FASOdd5fphjfDUISETYiU+TpqHOFol5NPY8qKAwiFMPEmW3veBIS/Vi5ZIw3J6KbcPTj D3BkhfOiF10whWYroNNLVDfuJ6DPzAEzEbSF7jCFrUT1W2YC5iHIcrlO5M+XQmLue2sz UMJrR7s9axDitkG24MRsam1fAqcc9HCUWckxyQNVaOuBJ6Hn/a373xKaE1PeHnN3FC3g p5ZblB9XhYtZh2a2ds0yBnuezS5aKVNm11h6Qaico18PjLI01XsWVuJ9FUPfg6Vq+GmM 2Thw== X-Gm-Message-State: AOAM532pecQLG9mt7lIOtZQSFzcD3JqEwFaq1XbUO7WXh6HJgTn0LgS3 /Pt4w+TpkppcH8e7BEADzP+zj6An99Q= X-Received: by 2002:a05:651c:513:: with SMTP id o19mr1095187ljp.68.1611410871766; Sat, 23 Jan 2021 06:07:51 -0800 (PST) Received: from [192.168.2.145] (109-252-192-57.dynamic.spd-mgts.ru. [109.252.192.57]) by smtp.googlemail.com with ESMTPSA id z9sm1196724lfs.183.2021.01.23.06.07.50 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 23 Jan 2021 06:07:51 -0800 (PST) Subject: Re: [PATCH RESEND v8 2/4] input: elants: support old touch report format To: =?UTF-8?B?TWljaGHFgiBNaXJvc8WCYXc=?= Cc: Dmitry Torokhov , Johnny Chuang , linux-input@vger.kernel.org, linux-kernel@vger.kernel.org References: <20201211160917.GA23095@qmqm.qmqm.pl> <3d872d19-a0b2-ed83-4b08-5c9a4755c2fe@gmail.com> <20201211170401.GA31605@qmqm.qmqm.pl> <79cf6571-4239-e98e-6001-70a4bf8b0fe5@gmail.com> <4c443c59-a7f8-bf16-cc0b-0e542c0d127f@gmail.com> <20210122223718.GE17048@qmqm.qmqm.pl> From: Dmitry Osipenko Message-ID: <1fe4d1e7-e356-efea-c913-7ca24c5f9cff@gmail.com> Date: Sat, 23 Jan 2021 17:07:50 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.2 MIME-Version: 1.0 In-Reply-To: <20210122223718.GE17048@qmqm.qmqm.pl> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 23.01.2021 01:37, Michał Mirosław пишет: > On Fri, Jan 22, 2021 at 11:10:52PM +0300, Dmitry Osipenko wrote: >> 08.01.2021 01:06, Dmitry Osipenko пишет: >>> 11.12.2020 21:48, Dmitry Torokhov пишет: >>>> On Fri, Dec 11, 2020 at 06:04:01PM +0100, Michał Mirosław wrote: >>>>> On Fri, Dec 11, 2020 at 07:39:33PM +0300, Dmitry Osipenko wrote: >>>>>> 11.12.2020 19:09, Michał Mirosław пишет: >>>>>>> On Thu, Dec 10, 2020 at 11:29:40PM -0800, Dmitry Torokhov wrote: >>>>>>>> Hi Michał, >>>>>>>> On Fri, Dec 11, 2020 at 07:53:56AM +0100, Michał Mirosław wrote: >>>>>>>>> @@ -998,17 +1011,18 @@ static irqreturn_t elants_i2c_irq(int irq, void *_dev) >>>>>>>>> } >>>>>>>>> >>>>>>>>> report_len = ts->buf[FW_HDR_LENGTH] / report_count; >>>>>>>>> - if (report_len != PACKET_SIZE) { >>>>>>>>> + if (report_len != PACKET_SIZE && >>>>>>>>> + report_len != PACKET_SIZE_OLD) { >>>>>>>>> dev_err(&client->dev, >>>>>>>>> - "mismatching report length: %*ph\n", >>>>>>>>> + "unsupported report length: %*ph\n", >>>>>>>>> HEADER_SIZE, ts->buf); >>>>>>>> Do I understand this correctly that the old packets are only observed on >>>>>>>> EKTF3624? If so can we expand the check so that we only accept packets >>>>>>>> with "old" size when we know we are dealing with this device? >>>>>>> >>>>>>> We only have EKTF3624 and can't be sure there are no other chips needing this. >>>>>> >>>>>> In practice this older packet format should be seen only on 3624, but >>>>>> nevertheless we could make it more explicit by adding the extra chip_id >>>>>> checks. >>>>>> >>>>>> It won't be difficult to change it in the future if will be needed. >>>>>> >>>>>> I think the main point that Dmitry Torokhov conveys here is that we >>>>>> should minimize the possible impact on the current EKT3500 code since we >>>>>> don't have definitive answers regarding the firmware differences among >>>>>> the hardware variants. >>>>> >>>>> The only possible impact here is that older firmware instead of breaking >>>>> would suddenly work. Maybe we can accept such a risk? >>>> >>>> These are not controllers we'll randomly find in devices: Windows boxes >>>> use I2C HID, Chrome devices use "new" firmware, so that leaves random >>>> ARM where someone needs to consciously add proper compatible before the >>>> driver will engage with the controller. >>>> >>>> I would prefer we were conservative and not accept potentially invalid >>>> data. >>>> >>>> Thanks. >>>> >>> >>> Michał, will you be able to make v9 with all the review comments addressed? >>> >> >> I'll make a v9 over this weekend. >> >> Michał, please let me know if you already started to work on this or >> have any objections. > > Hi, > > Sorry for staying quiet so long. I have to revive my Transformer before > I can test anything, so please go ahead. No problems, hope it's nothing serious and you'll have some spare time to revive it soon!