Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1029908pxb; Thu, 4 Mar 2021 01:05:58 -0800 (PST) X-Google-Smtp-Source: ABdhPJzTCrqww+Pkk4yOqDpndO4ZVHGiDSd1kMDsG8AWdra9QLhLVuMBnCq64ZiUP2bLOjFuBFYu X-Received: by 2002:a17:907:9709:: with SMTP id jg9mr3106388ejc.276.1614848757765; Thu, 04 Mar 2021 01:05:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614848757; cv=none; d=google.com; s=arc-20160816; b=j0BG3/fkEhi0aYt1gclxU0jMo5F63+WfmM6eCdQ4xGmfGdqzyya/Qi5nrzmJTZHL7U yRARP0eOCYSrSxyXrAxt1HnLblcbNMHxmmFYQGVbULxFfHRvHIrt8q7bRa98RRywXvA4 Q7LfHXEvtZwcCWHt0am/uUSMKp8IpRyGxaZP/RKP3VylZdkoijt0YvgHttmCRF0SVLjH eQg9HVNPEkSaz9aERVdomNJtIxiIwylhw0BZmmaSjb0jrYfezadbK9u8Mtux55sKsPup kVSflP4z6Cnxo6K210N5H5F0hI0wMf2eh92NXxlBDB2TWPo4AEH8dYUxFZjK/hKxoMDo hKkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:organization :from:references:cc:to:subject:reply-to; bh=8caApC6fSuzvGnx4JVklEu2OZpT1I1UHABh56hzXVVo=; b=AQvtstQBAKo6Jrl+8EhEn1oc37HeKGWN6WvafIP4PuUvRLITDL/7lW/HTR2xhZA3UU rxNeyBEhRs1vlT3DBe7VRV4UKo3QPqulxT76kKFzUs/yhod1tBVfHoozrSIKRklHZNxP MUdxuDN7Syzn/wmL9ba7P0CHSuX6G3iBknhauoBi229jGGAWaTHWor4h9jSyTV/ctwlR t9RIhmrfFx2a0s1MCywrqLNxRa+YCi0EBHcsz2ToA1CdcQsGHy1XLQb4HTQBRYVMUvEo BYpigpSCCG+GjWxG8re/hMg1JWPMCJwZJJYa/Y5kfD4gWK9zX1ORRd7S5zElnkpkTMAs Sh2Q== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q17si15569565edb.68.2021.03.04.01.05.35; Thu, 04 Mar 2021 01:05:57 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1447217AbhCCNsR (ORCPT + 99 others); Wed, 3 Mar 2021 08:48:17 -0500 Received: from air.basealt.ru ([194.107.17.39]:51952 "EHLO air.basealt.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1582433AbhCCKVh (ORCPT ); Wed, 3 Mar 2021 05:21:37 -0500 Received: by air.basealt.ru (Postfix, from userid 490) id 26C8C58943D; Wed, 3 Mar 2021 10:11:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on sa.local.altlinux.org X-Spam-Level: X-Spam-Status: No, score=-4.3 required=5.0 tests=ALL_TRUSTED,BAYES_00, RP_MATCHES_RCVD autolearn=ham autolearn_force=no version=3.4.1 Received: from nickel-ws.localdomain (obninsk.basealt.ru [217.15.195.17]) by air.basealt.ru (Postfix) with ESMTPSA id 46B3258943B; Wed, 3 Mar 2021 10:11:50 +0000 (UTC) Reply-To: nickel@basealt.ru Subject: Re: Need some help on "Input: elantech - add LEN2146 to SMBus blacklist for ThinkPad L13 Gen2" To: Wolfram Sang Cc: linux-i2c@vger.kernel.org, "open list:HID CORE LAYER" , "Gustavo A. R. Silva" , Colin Ian King , Dmitry Torokhov , Benjamin Tissoires , lkml , "jingle.wu" References: <0d1eaadd-5350-63a4-fe6d-f8f357c49504@basealt.ru> <20210225093801.GA1008@ninjato> From: Nikolai Kostrigin Organization: BaseALT Message-ID: <3ffc29f8-cdf1-15fe-6406-28872bba5716@basealt.ru> Date: Wed, 3 Mar 2021 13:11:50 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.7.1 MIME-Version: 1.0 In-Reply-To: <20210225093801.GA1008@ninjato> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, 25.02.2021 12:38, Wolfram Sang пишет: > Hi, > >> I had a preliminary discussion with Benjamin Tissoires and according to >> our agreement I repost it for wider audience. >> Blacklisting the device was decided to be a bad idea. >> But actually I managed to get touchpad totally operational via SMBus >> using a following hack: >> >> providing a parameter to i2c_i801 driver: >> >> modprobe i2c_i801 disable_features=0x2 (i.e. disable the block buffer). > So, from an I2C perspective, there are two things to mention here: > > a) I am in the process of extending the I2C core to allow block > transfers > 32 byte. This is a slow process, though, because we need to > pay attention to not break userspace ABI. If this is done *and* the i801 > driver supports length > 32 bytes, too, then it would work natively. If > the i801 can do this, this is a question for Jean Delvare. > > b) I don't know Elantech HW but there are devices out there which allow > configuration for the block size. Something like a bit specifying if > block transfers > 32 are allowed. Or the SMBus version to support. Block > transfers > 32 are SMBus 3.0+ only. If your HW does not have that, > disabling SMBus is an option, too. Disabling it in the i801 driver is > too much of a hammer, I'd say. > > Hope this helps! Happy hacking, > > Wolfram Thank you for the information, Wolfram! Finally it turned out that the solution was near me from the very beginning, but I failed to check mainline code at that moment (which is now 5.11). Happily Jingle Wu has pointed me to a couple of  patches of his (co-authored by Dmitry Torokhov): https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git/commit/?h=next&id=056115daede8d01f71732bc7d778fb85acee8eb6 https://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git/commit/?h=next&id=e4c9062717feda88900b566463228d1c4910af6d I applied those to 5.10.17 and trackpoint works like a charm. So I guess theese patches are worth being backported to the longterm 5.10 branch. I'm really sorry for the noise. -- Best regards, Nikolai Kostrigin