Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1575088
| From | Dmitry Torokhov <dmitry.torokhov@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 03/10] Input: synaptics-rmi4 - f30/f03: Forward mechanical buttons on buttonpads to PS/2 guest |
| Date | 2017-02-06 20:30 +0100 |
| Message-ID | <t7X97-Lb-9@gated-at.bofh.it> (permalink) |
| References | <sY7jr-3z6-5@gated-at.bofh.it> <sY7js-3z6-29@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi Benjamin,
On Tue, Jan 10, 2017 at 05:11:21PM +0100, Benjamin Tissoires wrote:
> +void rmi_f03_commit_buttons(struct rmi_function *fn)
> +{
> + struct f03_data *f03 = dev_get_drvdata(&fn->dev);
> + int i;
> +
> + f03->serio->extra_byte = f03->overwrite_buttons;
> +
> + for (i = 0; i < 3; i++)
> + serio_interrupt(f03->serio, 0x00, 0x00);
How does this work with protocols larger than 3 bytes (i.e. anything but
bare PS/2)? Or F03 limits the kind of devices we connect to RMI4 device?
Overall, I am very uncomfortable with the concept of "extra byte" at
serio level. Maybe we should define a new flag, something like
SERIO_SYNTHETIC or SERIO_OOB_DATA, and have something like:
void rmi_f03_commit_buttons(struct rmi_function *fn)
{
struct serio *serio = f03->serio;
serio_pause_rx(serio);
if (serio->drv) {
serio->drv->interrupt(serio, PSMOUSE_EXTRA_BTNS,
SERIO_OOB_DATA);
serio->drv->interrupt(serio, f03->overwrite_buttons.
SERIO_OOB_DATA);
}
serio_pause_rx(serio);
}
and have psmouse driver store and use it as it sees fit.
Thanks.
--
Dmitry
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [PATCH 03/10] Input: synaptics-rmi4 - f30/f03: Forward mechanical buttons on buttonpads to PS/2 guest Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2017-02-06 20:30 +0100
Re: [PATCH 03/10] Input: synaptics-rmi4 - f30/f03: Forward mechanical buttons on buttonpads to PS/2 guest Benjamin Tissoires <benjamin.tissoires@redhat.com> - 2017-02-07 17:30 +0100
[PATCH v2 2/2] Input: synaptics-rmi4 - f30/f03: Forward mechanical buttons on buttonpads to PS/2 guest Benjamin Tissoires <benjamin.tissoires@redhat.com> - 2017-02-07 17:30 +0100
[PATCH v2 1/2] Input: psmouse - add a custom serio protocol to send extra information Benjamin Tissoires <benjamin.tissoires@redhat.com> - 2017-02-07 17:30 +0100
Re: [PATCH v2 1/2] Input: psmouse - add a custom serio protocol to send extra information Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2017-02-08 09:30 +0100
Re: [PATCH v2 1/2] Input: psmouse - add a custom serio protocol to send extra information Benjamin Tissoires <benjamin.tissoires@redhat.com> - 2017-02-08 19:00 +0100
csiph-web