* [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad
@ 2014-03-24 13:49 Hans de Goede
2014-03-28 8:01 ` Dmitry Torokhov
0 siblings, 1 reply; 3+ messages in thread
From: Hans de Goede @ 2014-03-24 13:49 UTC (permalink / raw)
To: Dmitry Torokhov
Cc: Benjamin Tissoires, linux-input, Hans de Goede, Adam Williamson,
Peter Hutterer
The cypress PS/2 trackpad models supported by the cypress_ps2 driver emulate
BTN_RIGHT events in firmware based on the finger position, as part of this
no motion events are sent when the finger is in the button area.
The INPUT_PROP_BUTTONPAD property is there to indicate to userspace that
BTN_RIGHT events should be emulated in userspace, which is not necessary
in this case.
When INPUT_PROP_BUTTONPAD is advertised userspace will wait for a motion event
before propagating the button event higher up the stack, as it needs current
abs x + y data for its BTN_RIGHT emulation. Since in the cypress_ps2 pads
don't report motion events in the button area, this means that clicks in the
button area end up being ignored, so INPUT_PROP_BUTTONPAD actually causes
problems for these touchpads, and removing it fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=76341
Reported-by: Adam Williamson <awilliam@redhat.com>
Tested-by: Adam Williamson <awilliam@redhat.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Cc: Adam Williamson <awilliam@redhat.com>
Cc: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
drivers/input/mouse/cypress_ps2.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/input/mouse/cypress_ps2.c b/drivers/input/mouse/cypress_ps2.c
index 87095e2..8af34ff 100644
--- a/drivers/input/mouse/cypress_ps2.c
+++ b/drivers/input/mouse/cypress_ps2.c
@@ -409,7 +409,6 @@ static int cypress_set_input_params(struct input_dev *input,
__clear_bit(REL_X, input->relbit);
__clear_bit(REL_Y, input->relbit);
- __set_bit(INPUT_PROP_BUTTONPAD, input->propbit);
__set_bit(EV_KEY, input->evbit);
__set_bit(BTN_LEFT, input->keybit);
__set_bit(BTN_RIGHT, input->keybit);
--
1.9.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad
2014-03-24 13:49 [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad Hans de Goede
@ 2014-03-28 8:01 ` Dmitry Torokhov
0 siblings, 0 replies; 3+ messages in thread
From: Dmitry Torokhov @ 2014-03-28 8:01 UTC (permalink / raw)
To: Hans de Goede
Cc: Benjamin Tissoires, linux-input, Adam Williamson, Peter Hutterer
On Mon, Mar 24, 2014 at 02:49:35PM +0100, Hans de Goede wrote:
> The cypress PS/2 trackpad models supported by the cypress_ps2 driver emulate
> BTN_RIGHT events in firmware based on the finger position, as part of this
> no motion events are sent when the finger is in the button area.
>
> The INPUT_PROP_BUTTONPAD property is there to indicate to userspace that
> BTN_RIGHT events should be emulated in userspace, which is not necessary
> in this case.
>
> When INPUT_PROP_BUTTONPAD is advertised userspace will wait for a motion event
> before propagating the button event higher up the stack, as it needs current
> abs x + y data for its BTN_RIGHT emulation. Since in the cypress_ps2 pads
> don't report motion events in the button area, this means that clicks in the
> button area end up being ignored, so INPUT_PROP_BUTTONPAD actually causes
> problems for these touchpads, and removing it fixes:
>
> https://bugs.freedesktop.org/show_bug.cgi?id=76341
>
> Reported-by: Adam Williamson <awilliam@redhat.com>
> Tested-by: Adam Williamson <awilliam@redhat.com>
> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
> Cc: Adam Williamson <awilliam@redhat.com>
> Cc: Peter Hutterer <peter.hutterer@who-t.net>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Applied, thank you.
> ---
> drivers/input/mouse/cypress_ps2.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/drivers/input/mouse/cypress_ps2.c b/drivers/input/mouse/cypress_ps2.c
> index 87095e2..8af34ff 100644
> --- a/drivers/input/mouse/cypress_ps2.c
> +++ b/drivers/input/mouse/cypress_ps2.c
> @@ -409,7 +409,6 @@ static int cypress_set_input_params(struct input_dev *input,
> __clear_bit(REL_X, input->relbit);
> __clear_bit(REL_Y, input->relbit);
>
> - __set_bit(INPUT_PROP_BUTTONPAD, input->propbit);
> __set_bit(EV_KEY, input->evbit);
> __set_bit(BTN_LEFT, input->keybit);
> __set_bit(BTN_RIGHT, input->keybit);
> --
> 1.9.0
>
--
Dmitry
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad
2014-03-31 9:08 [PATCH 0/1] input: cypress_ps2: Don't report the cypress PS/2 trackpads Hans de Goede
@ 2014-03-31 9:08 ` Hans de Goede
0 siblings, 0 replies; 3+ messages in thread
From: Hans de Goede @ 2014-03-31 9:08 UTC (permalink / raw)
To: stable
Cc: Dmitry Torokhov, linux-input, Hans de Goede, Adam Williamson,
Peter Hutterer
The cypress PS/2 trackpad models supported by the cypress_ps2 driver emulate
BTN_RIGHT events in firmware based on the finger position, as part of this
no motion events are sent when the finger is in the button area.
The INPUT_PROP_BUTTONPAD property is there to indicate to userspace that
BTN_RIGHT events should be emulated in userspace, which is not necessary
in this case.
When INPUT_PROP_BUTTONPAD is advertised userspace will wait for a motion event
before propagating the button event higher up the stack, as it needs current
abs x + y data for its BTN_RIGHT emulation. Since in the cypress_ps2 pads
don't report motion events in the button area, this means that clicks in the
button area end up being ignored, so INPUT_PROP_BUTTONPAD actually causes
problems for these touchpads, and removing it fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=76341
Reported-by: Adam Williamson <awilliam@redhat.com>
Tested-by: Adam Williamson <awilliam@redhat.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Cc: Adam Williamson <awilliam@redhat.com>
Cc: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: stable@vger.kernel.org
---
drivers/input/mouse/cypress_ps2.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/input/mouse/cypress_ps2.c b/drivers/input/mouse/cypress_ps2.c
index 87095e2..8af34ff 100644
--- a/drivers/input/mouse/cypress_ps2.c
+++ b/drivers/input/mouse/cypress_ps2.c
@@ -409,7 +409,6 @@ static int cypress_set_input_params(struct input_dev *input,
__clear_bit(REL_X, input->relbit);
__clear_bit(REL_Y, input->relbit);
- __set_bit(INPUT_PROP_BUTTONPAD, input->propbit);
__set_bit(EV_KEY, input->evbit);
__set_bit(BTN_LEFT, input->keybit);
__set_bit(BTN_RIGHT, input->keybit);
--
1.9.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-03-31 9:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-24 13:49 [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad Hans de Goede
2014-03-28 8:01 ` Dmitry Torokhov
-- strict thread matches above, loose matches on Subject: below --
2014-03-31 9:08 [PATCH 0/1] input: cypress_ps2: Don't report the cypress PS/2 trackpads Hans de Goede
2014-03-31 9:08 ` [PATCH] input: cypress_ps2: Don't report the cypress PS/2 trackpads as a button pad Hans de Goede
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).