[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <OSAPR01MB30570EDCFD88E77818F0A2FCC8D80@OSAPR01MB3057.jpnprd01.prod.outlook.com>
Date: Thu, 16 Apr 2020 08:10:11 +0000
From: Xiaojian Cao <xiaojian.cao@...alps.com>
To: Jiri Kosina <jikos@...nel.org>
CC: Artem Borisov <dedsa2002@...il.com>,
Masaki Ota <masaki.ota@...salpine.com>,
Benjamin Tissoires <benjamin.tissoires@...hat.com>,
Henrik Rydberg <rydberg@...math.org>,
"linux-input@...r.kernel.org" <linux-input@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Tetsuya Nomura <tetsuya.nomura@...salpine.com>,
"vadim@...que.com" <vadim@...que.com>,
"pod.alcht@...alps.com" <pod.alcht@...alps.com>
Subject: RE: [PATCH 2/2] HID: alps: Refactor axis resolution logic
Hi Jiri,
It's my pleasure.
The latest modification is suitable now.
Best Regards,
----------------------------------------------
Jason Cao(曹晓建)
-----Original Message-----
From: Jiri Kosina <jikos@...nel.org>
Sent: Wednesday, April 15, 2020 8:55 PM
To: 曹 曉建 Xiaojian Cao <xiaojian.cao@...alps.com>
Cc: Artem Borisov <dedsa2002@...il.com>; 太田 真喜 Masaki Ota <masaki.ota@...salpine.com>; Benjamin Tissoires <benjamin.tissoires@...hat.com>; Henrik Rydberg <rydberg@...math.org>; linux-input@...r.kernel.org; linux-kernel@...r.kernel.org; 野村 哲哉 Tetsuya Nomura <tetsuya.nomura@...salpine.com>; Vadim Klishko <vadim@...que.com>; #ALCHT_ML_POD_CN <pod.alcht@...alps.com>
Subject: RE: [PATCH 2/2] HID: alps: Refactor axis resolution logic
On Wed, 15 Apr 2020, Xiaojian Cao wrote:
> Thanks for your checking, my feedbacks are as below:
>
> 1.It is about the coding style that we should not use HWID in the
> string "HID_DEVICE_ID_ALPS_1657", there are a large number of HWIDs
> using this touchpad. We should use the device type information in this
> string, such as "U1_UNICORN_LEGACY".
Ok, thanks for the feedback. Based on it, I am queuing the patch below.
HID_DEVICE_ID_ALPS_1657 PID is too specific, as there are many other ALPS hardware IDs using this particular touchpad.
Rename the identifier to HID_DEVICE_ID_ALPS_U1_UNICORN_LEGACY in order to describe reality better.
Fixes: 640e403b1fd24 ("HID: alps: Add AUI1657 device ID")
Reported-by: Xiaojian Cao <xiaojian.cao@...alps.com>
Signed-off-by: Jiri Kosina <jkosina@...e.cz>
---
drivers/hid/hid-alps.c | 2 +-
drivers/hid/hid-ids.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/hid/hid-alps.c b/drivers/hid/hid-alps.c index c2a2bd528890..b2ad319a74b9 100644
--- a/drivers/hid/hid-alps.c
+++ b/drivers/hid/hid-alps.c
@@ -802,7 +802,7 @@ static int alps_probe(struct hid_device *hdev, const struct hid_device_id *id)
break;
case HID_DEVICE_ID_ALPS_U1_DUAL:
case HID_DEVICE_ID_ALPS_U1:
- case HID_DEVICE_ID_ALPS_1657:
+ case HID_DEVICE_ID_ALPS_U1_UNICORN_LEGACY:
data->dev_type = U1;
break;
default:
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h index e3e2fa6733fb..6eb25b9e8575 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -79,9 +79,9 @@
#define HID_DEVICE_ID_ALPS_U1_DUAL_PTP 0x121F
#define HID_DEVICE_ID_ALPS_U1_DUAL_3BTN_PTP 0x1220
#define HID_DEVICE_ID_ALPS_U1 0x1215
+#define HID_DEVICE_ID_ALPS_U1_UNICORN_LEGACY 0x121E
#define HID_DEVICE_ID_ALPS_T4_BTNLESS 0x120C
#define HID_DEVICE_ID_ALPS_1222 0x1222
-#define HID_DEVICE_ID_ALPS_1657 0x121E
#define USB_VENDOR_ID_AMI 0x046b
#define USB_DEVICE_ID_AMI_VIRT_KEYBOARD_AND_MOUSE 0xff10
--
Jiri Kosina
SUSE Labs
Powered by blists - more mailing lists