From f11262b8a4c3753912af8c6bf5360ba015887a5d Mon Sep 17 00:00:00 2001 From: Ting Shen Date: Wed, 5 May 2021 18:30:36 +0800 Subject: touchpad_elan: add ic type 0x15 support Sync the elan_get_fwinfo function from kernel v5.12 to ec codebase. BUG=b:183899273 TEST=no "unknown ic_type: 21" in ec console BRANCH=trogdor Signed-off-by: Ting Shen Change-Id: I0499d2666151448a504d1759d1ee6c3f5376a97a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2874946 Reviewed-by: Wai-Hong Tam Commit-Queue: Ting Shen Tested-by: Ting Shen --- driver/touchpad_elan.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/driver/touchpad_elan.c b/driver/touchpad_elan.c index 6cd07dd2c2..06a6b1ed13 100644 --- a/driver/touchpad_elan.c +++ b/driver/touchpad_elan.c @@ -292,6 +292,7 @@ static int elan_get_fwinfo(void) case 0x00: case 0x10: case 0x14: + case 0x15: elan_tp_params.page_count = 1024; break; default: @@ -299,7 +300,7 @@ static int elan_get_fwinfo(void) return EC_ERROR_UNKNOWN; } - if (ic_type == 0x14 && iap_version >= 2) { + if ((ic_type == 0x14 || ic_type == 0x15) && iap_version >= 2) { elan_tp_params.page_count /= 8; elan_tp_params.page_size = 512; } else if (ic_type >= 0x0D && iap_version >= 1) { -- cgit v1.2.1