Received: by 10.223.164.202 with SMTP id h10csp3728972wrb; Tue, 28 Nov 2017 16:29:46 -0800 (PST) X-Google-Smtp-Source: AGs4zMareNZ4WcUPv++CC804XyuhKWs7MW/9S9zn3SmG8Bk6MyRTmznG2k3WBeDITCZQAShE24bT X-Received: by 10.98.201.29 with SMTP id k29mr1030531pfg.27.1511915386128; Tue, 28 Nov 2017 16:29:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1511915386; cv=none; d=google.com; s=arc-20160816; b=QaKjKeLmNUO3y74J8DQsKfbVv+jA2Ro6uOtTYNGjMzgYoFqzsCY9Qp3l93Qqrrcn65 GpyLgwQMsUi1aGZQic1JhXS6+rsHtbdD2eKvBRqkTL7OaVu+k2Q4CX7DMVhcCQeGqxI7 i5w3h3fvJjYSL7osjo7u0FBvxHV4VM/C1Q83Jwid2TUdw65dCPz2VrXo5Ry2C7pV2hco eN9poPHywcvDUw7sLT1wBDeL05/XN+uELKs20lPw3q85lDJjdPwT+zeoPrUsyyHbj6q5 /OkSJaer6Tbcr/I5sPBhVLGI4PjrQh0h7CWnTRKc36ciCNqKhB3y63KSeSmQZ0UCnqsB zdmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=09AUnr6ggVL3/OoqqznHuXeebvINa4E2eXp9N+mO9wI=; b=d/MjjUmsNTZHIbBfJJmHq1vPH4UkynErxAO72QSbeFfa2p2yZ9/588H4OSjIhfapIq 2Ia6gp4nsCvrJubW6jzCdgjCXGQ+5tN0HP8rNwc/HzH+WKTByB5/1MhEr0gMHN0cPnfh tWgoYiMa8huAvbFoRCwn+KD7zQU8OGqq1yUeJCBvqD4Nj5Jjj/5klA2lF0wIqWqjBvd/ oLLTYzxioxbycn9k6ZoCQTL4jlGeJ2R8P20XJe3LUOjOs4WDy3w1GhouavsqSixZxbgw phx2TNM99ZnfXZ+gczVBtUOQ5DlxwKveHgfirf5sNP1UCqLyWVeeCw84CFyRPZRpTY2S 7y4A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alpsgroup.onmicrosoft.com header.s=selector1-jp-alps-com header.b=mFkFz/51; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c11si281979pgv.412.2017.11.28.16.29.35; Tue, 28 Nov 2017 16:29:46 -0800 (PST) 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; dkim=pass header.i=@alpsgroup.onmicrosoft.com header.s=selector1-jp-alps-com header.b=mFkFz/51; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752549AbdK2A26 (ORCPT + 70 others); Tue, 28 Nov 2017 19:28:58 -0500 Received: from mail-ty1jpn01on0070.outbound.protection.outlook.com ([104.47.93.70]:20704 "EHLO JPN01-TY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751722AbdK2A24 (ORCPT ); Tue, 28 Nov 2017 19:28:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alpsgroup.onmicrosoft.com; s=selector1-jp-alps-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=09AUnr6ggVL3/OoqqznHuXeebvINa4E2eXp9N+mO9wI=; b=mFkFz/51nhDa2ODKNIddxs+h2xLCnU2HUoXVpZFSu57vJWNwL0Ysl8fnO0BUsCCj0oI7bepQ2zR8q+BIG6cBqq5J6PI5RCMVZMDw6miEudeB7aIKCAzXpb/FCoNcZc8eIsOWPuqgIa//g10+Jtm4nPzRz0mLjI2xEnAZ0fewBu0= Received: from TYXPR01MB0719.jpnprd01.prod.outlook.com (10.168.44.10) by TYXPR01MB0718.jpnprd01.prod.outlook.com (10.168.44.9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.260.4; Wed, 29 Nov 2017 00:28:51 +0000 Received: from TYXPR01MB0719.jpnprd01.prod.outlook.com ([10.168.44.10]) by TYXPR01MB0719.jpnprd01.prod.outlook.com ([10.168.44.10]) with mapi id 15.20.0260.007; Wed, 29 Nov 2017 00:28:51 +0000 From: Masaki Ota To: Dmitry Torokhov , Masaki Ota <012nexus@gmail.com> CC: "benjamin.tissoires@redhat.com" , "pali.rohar@gmail.com" , "aaron.ma@canonical.com" , "jaak@ristioja.ee" , "linux-input@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: RE: [PATCH] Support TrackStick of Thinkpad L570 Thread-Topic: [PATCH] Support TrackStick of Thinkpad L570 Thread-Index: AQHTYdT2HFG582h6Z0eoBSc7x32zcKMl086AgAS27dA= Date: Wed, 29 Nov 2017 00:28:51 +0000 Message-ID: References: <20171120075530.4880-1-masaki.ota@jp.alps.com> <20171126001559.uqeud7wxgjhkldgd@dtor-ws> In-Reply-To: <20171126001559.uqeud7wxgjhkldgd@dtor-ws> Accept-Language: ja-JP, en-US Content-Language: ja-JP X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=masaki.ota@jp.alps.com; x-originating-ip: [106.184.109.136] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;TYXPR01MB0718;20:AU8NvVgaI5mqtRxRnx1NPF0AROLOGlCGRgU7F8uu+2eRDJBh+PUUDckXena9G3IQiFod7eGyOXhXZ66iCV3R+iP82tpOMyEAK7pa9k76OrnVLeuGV806WX7noMVIsX+iWIz/RSgCBgWL/ry9r7exR7Cqf99SbTzn7RfE5v/P7Kc= x-ms-exchange-antispam-srfa-diagnostics: SSOS; x-ms-office365-filtering-correlation-id: adec4a86-4fe9-4946-0f94-08d536c02a88 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(5600026)(4604075)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(48565401081)(2017052603199);SRVR:TYXPR01MB0718; x-ms-traffictypediagnostic: TYXPR01MB0718: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(9452136761055)(198206253151910)(9931346810618); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(8121501046)(5005006)(10201501046)(93006095)(93001095)(3002001)(3231022)(6055026)(6041248)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123555025)(20161123564025)(20161123560025)(6072148)(201708071742011);SRVR:TYXPR01MB0718;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:TYXPR01MB0718; x-forefront-prvs: 05066DEDBB x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(6009001)(366004)(376002)(346002)(39860400002)(189002)(13464003)(199003)(24454002)(2900100001)(3280700002)(6246003)(3660700001)(81166006)(8676002)(5660300001)(2950100002)(99286004)(81156014)(42882006)(3846002)(6116002)(102836003)(4326008)(2906002)(110136005)(85182001)(97736004)(316002)(189998001)(7696005)(54906003)(7736002)(105586002)(8936002)(74316002)(305945005)(68736007)(66066001)(575784001)(53546010)(86362001)(106356001)(9686003)(53936002)(25786009)(55016002)(39060400002)(101416001)(50986999)(478600001)(54356999)(33656002)(76176999)(6506006)(6436002)(14454004)(77096006)(229853002);DIR:OUT;SFP:1101;SCL:1;SRVR:TYXPR01MB0718;H:TYXPR01MB0719.jpnprd01.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:0;LANG:en; received-spf: None (protection.outlook.com: jp.alps.com does not designate permitted sender hosts) spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: jp.alps.com X-MS-Exchange-CrossTenant-Network-Message-Id: adec4a86-4fe9-4946-0f94-08d536c02a88 X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Nov 2017 00:28:51.5630 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 57e76998-77bd-4b82-a424-198f46eb2254 X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYXPR01MB0718 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, Domitry, I think we can add the code to HID for this device, but we will not use SMB= us interface for Touchpad in the future. We should not do it. Best Regards, Masaki Ota -----Original Message----- From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]=20 Sent: Sunday, November 26, 2017 9:16 AM To: Masaki Ota <012nexus@gmail.com> Cc: benjamin.tissoires@redhat.com; pali.rohar@gmail.com; aaron.ma@canonical= .com; jaak@ristioja.ee; =1B$BB@ED=1B(B =1B$B??4n=1B(B Masaki Ota ; linux-input@vger.kernel.org; linux-kernel@vger.kernel.org Subject: Re: [PATCH] Support TrackStick of Thinkpad L570 Hi, On Mon, Nov 20, 2017 at 04:55:30PM +0900, Masaki Ota wrote: > From: Masaki Ota > - The issue is that Thinkpad L570 TrackStick does not work. Because the m= ain interface of Thinkpad L570 device is SMBus, so ALPS overlooked PS2 inte= rface Firmware setting of TrackStick. The detail is that TrackStick otp bit= is disabled. Is it custom protocol over SMBus/I2C or HID (via i2c-hid)? If it is custom = protocol, can we add the proper driver to the kernel for it so we can get a= way from the PS/2 emulation in firmware? Thanks! > - Add the code that checks 0xD7 address value. This value is device numbe= r information, so we can identify the device by checking this value. > - If we check 0xD7 value, we need to enable Command mode and after check = the value we need to disable Command mode, then we have to enable the devic= e(0xF4 command). > - Thinkpad L570 device number is 0x0C or 0x1D. If it is TRUE, enable ALPS= _DUALPOINT flag. >=20 > Signed-off-by: Masaki Ota > --- > drivers/input/mouse/alps.c | 21 ++++++++++++++++++--- > 1 file changed, 18 insertions(+), 3 deletions(-) >=20 > diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c=20 > index 850b00e3ad8e..cce52104ed5a 100644 > --- a/drivers/input/mouse/alps.c > +++ b/drivers/input/mouse/alps.c > @@ -2541,13 +2541,28 @@ static int=20 > alps_update_btn_info_ss4_v2(unsigned char otp[][4], } > =20 > static int alps_update_dual_info_ss4_v2(unsigned char otp[][4], > - struct alps_data *priv) > + struct alps_data *priv, > + struct psmouse *psmouse) > { > bool is_dual =3D false; > + int reg_val =3D 0; > + struct ps2dev *ps2dev =3D &psmouse->ps2dev; > =20 > - if (IS_SS4PLUS_DEV(priv->dev_id)) > + if (IS_SS4PLUS_DEV(priv->dev_id)) { > is_dual =3D (otp[0][0] >> 4) & 0x01; > =20 > + /* For support TrackStick of Thinkpad L570 device */ > + if (alps_exit_command_mode(psmouse) =3D=3D 0 && > + alps_enter_command_mode(psmouse) =3D=3D 0) { > + reg_val =3D alps_command_mode_read_reg(psmouse, 0xD7); > + } > + alps_exit_command_mode(psmouse); > + ps2_command(ps2dev, NULL, PSMOUSE_CMD_ENABLE); > + > + if (reg_val =3D=3D 0x0C || reg_val =3D=3D 0x1D) > + is_dual =3D true; > + } > + > if (is_dual) > priv->flags |=3D ALPS_DUALPOINT | > ALPS_DUALPOINT_WITH_PRESSURE; > @@ -2570,7 +2585,7 @@ static int alps_set_defaults_ss4_v2(struct=20 > psmouse *psmouse, > =20 > alps_update_btn_info_ss4_v2(otp, priv); > =20 > - alps_update_dual_info_ss4_v2(otp, priv); > + alps_update_dual_info_ss4_v2(otp, priv, psmouse); > =20 > return 0; > } > -- > 2.14.1 >=20 --=20 Dmitry From 1585085885364704925@xxx Sun Nov 26 00:21:38 +0000 2017 X-GM-THRID: 1584570916340987763 X-Gmail-Labels: Inbox,Category Forums,HistoricalUnread