Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1427183
| From | 廖崇榮 <kt.liao@emc.com.tw> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | RE: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode |
| Date | 2016-06-21 03:40 +0200 |
| Message-ID | <rMiPv-7uu-11@gated-at.bofh.it> (permalink) |
| References | <rHpoC-3hJ-45@gated-at.bofh.it> <rMbuF-2Oc-19@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi Dmitry,
The modification from Chris is a special case.
Because the Touchpad FW is a little different from normal one, It cause
problem in Asus's OBE test.
That's why Elan's driver use work-around to solve the problem. It's not
tested by other touchpad.
Let me discuss with internal FW team to confirm the harmless of the patch.
B.R KT
-----Original Message-----
From: Dmitry Torokhov [mailto:dmitry.torokhov@gmail.com]
Sent: Tuesday, June 21, 2016 1:43 AM
To: Chris Chiu; kt.liao@emc.com.tw
Cc: Charlie Mooney; Michele Curti; Krzysztof Kozlowski; Benson Leung;
linux-input@vger.kernel.org; linux-kernel@vger.kernel.org;
linux@endlessm.com
Subject: Re: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS
mode
On Tue, Jun 07, 2016 at 09:34:09PM +0800, Chris Chiu wrote:
> When performing a warm reboot from a system which does not correctly
> support ELAN I2C touchpads, the touchpad will sometimes enter standard
> mouse mode, cursor then never respond to touchpad event, and making
> the driver discard the HID reports and flood dmesg with following
> error messages.
> "elan_i2c i2c-ELAN1000:00: invalid report id data (1)"
>
> This change is from ELAN's correction. It needs 200ms delay before
> set_mode() so that the mode setting will correctly take effect.
KT, is this feasible?
>
> Signed-off-by: Chris Chiu <chiu@endlessm.com>
> ---
> drivers/input/mouse/elan_i2c_core.c | 12 +++++++-----
> 1 file changed, 7 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/input/mouse/elan_i2c_core.c
> b/drivers/input/mouse/elan_i2c_core.c
> index 2f58985..95080f9 100644
> --- a/drivers/input/mouse/elan_i2c_core.c
> +++ b/drivers/input/mouse/elan_i2c_core.c
> @@ -210,18 +210,20 @@ static int __elan_initialize(struct elan_tp_data
*data)
> return error;
> }
>
> - data->mode |= ETP_ENABLE_ABS;
> - error = data->ops->set_mode(client, data->mode);
> + error = data->ops->sleep_control(client, false);
> if (error) {
> dev_err(&client->dev,
> - "failed to switch to absolute mode: %d\n", error);
> + "failed to wake device up: %d\n", error);
> return error;
> }
>
> - error = data->ops->sleep_control(client, false);
> + msleep(200);
> +
> + data->mode |= ETP_ENABLE_ABS;
> + error = data->ops->set_mode(client, data->mode);
> if (error) {
> dev_err(&client->dev,
> - "failed to wake device up: %d\n", error);
> + "failed to switch to absolute mode: %d\n", error);
> return error;
> }
>
> --
> 2.1.4
>
Thanks.
--
Dmitry
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2016-06-20 19:50 +0200
RE: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode 廖崇榮 <kt.liao@emc.com.tw> - 2016-06-21 03:40 +0200
RE: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode 廖崇榮 <kt.liao@emc.com.tw> - 2016-06-21 14:50 +0200
Re: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode Daniel Drake <drake@endlessm.com> - 2016-06-21 17:00 +0200
RE: [PATCH] Input: elan_i2c - +200 ms delay before setting to ABS mode 廖崇榮 <kt.liao@emc.com.tw> - 2016-06-22 14:10 +0200
csiph-web