[CFT] changes and updates to x11 input devices

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

[CFT] changes and updates to x11 input devices

Niclas Zeising-6
Hi!
I've been working for a little while on incorporating the various
patches floating around for changes and updates to xorg input drivers,
mostly related to libinput.  The result can be found here, in the x11
team development repo:

https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input

It contains upates to libinput, libeevdev, libwacom, xf86-input-libinput
and dependencies.

Please help me in testing this as much as possible, so that we can land
it in the ports system

The branch above is a complete ports tree, so you can use it to build
from, or to point poudriere at it.  Please test various input devices,
synaptics touchpads, wacom devices and so on.  Both success and failure
stories are interesting.
Thanks!
Regards
--
Niclas Zeising
FreeBSD x11/graphics team
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Vladimir Kondratyev-3
On 2018-06-10 10:01, Niclas Zeising wrote:
> Hi!
> I've been working for a little while on incorporating the various
> patches floating around for changes and updates to xorg input drivers,
> mostly related to libinput.  The result can be found here, in the x11
> team development repo:
>
> https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>

Thank you, Niclas

IMO patch is more convenient way of distribution as it reduces size of
download and allows to keep private changes intact.

Cumulative diff of consecutive commits can be done with next command:
git diff <first>^...<last>


--
WBR
Vladimir Kondratyev
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Niclas Zeising-5
In reply to this post by Niclas Zeising-6
On 06/10/18 09:01, Niclas Zeising wrote:

> Hi!
> I've been working for a little while on incorporating the various
> patches floating around for changes and updates to xorg input drivers,
> mostly related to libinput.  The result can be found here, in the x11
> team development repo:
>
> https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>
> It contains upates to libinput, libeevdev, libwacom, xf86-input-libinput
> and dependencies.
>
> Please help me in testing this as much as possible, so that we can land
> it in the ports system
>
> The branch above is a complete ports tree, so you can use it to build
> from, or to point poudriere at it.  Please test various input devices,
> synaptics touchpads, wacom devices and so on.  Both success and failure
> stories are interesting.

On request, attached is a patch with all changes.
Regards
--
Niclas

_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"

ports.input.diff (53K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

pete wright
In reply to this post by Niclas Zeising-6


On 06/10/2018 00:01, Niclas Zeising wrote:

> Hi!
> I've been working for a little while on incorporating the various
> patches floating around for changes and updates to xorg input drivers,
> mostly related to libinput.  The result can be found here, in the x11
> team development repo:
>
> https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>
> It contains upates to libinput, libeevdev, libwacom,
> xf86-input-libinput and dependencies.
>
> Please help me in testing this as much as possible, so that we can
> land it in the ports system
>
> The branch above is a complete ports tree, so you can use it to build
> from, or to point poudriere at it.  Please test various input devices,
> synaptics touchpads, wacom devices and so on.  Both success and
> failure stories are interesting.


i haven't had any issues installing pkgs via this branch.  one question
tho - i believe to make use of libevdev it requires a kernel built with
evdev support correct?  if that is so - is there a specific patchset
that should be used?

i tested out evdev a while ago - but am not sure the patchset i have
laying around is the correct one.

thanks!
-pete

--
Pete Wright
[hidden email]
@nomadlogicLA

_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Johannes Lundberg
On Sun, Jun 10, 2018 at 9:58 PM Pete Wright <[hidden email]> wrote:

>
>
> On 06/10/2018 00:01, Niclas Zeising wrote:
> > Hi!
> > I've been working for a little while on incorporating the various
> > patches floating around for changes and updates to xorg input drivers,
> > mostly related to libinput.  The result can be found here, in the x11
> > team development repo:
> >
> > https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
> >
> > It contains upates to libinput, libeevdev, libwacom,
> > xf86-input-libinput and dependencies.
> >
> > Please help me in testing this as much as possible, so that we can
> > land it in the ports system
> >
> > The branch above is a complete ports tree, so you can use it to build
> > from, or to point poudriere at it.  Please test various input devices,
> > synaptics touchpads, wacom devices and so on.  Both success and
> > failure stories are interesting.
>
>
> i haven't had any issues installing pkgs via this branch.  one question
> tho - i believe to make use of libevdev it requires a kernel built with
> evdev support correct?  if that is so - is there a specific patchset
> that should be used?
>
> i tested out evdev a while ago - but am not sure the patchset i have
> laying around is the correct one.
>

Hi

For evdev simply add to your kernel config

options        EVDEV_SUPPORT
device        evdev


> thanks!
> -pete
>
> --
> Pete Wright
> [hidden email]
> @nomadlogicLA
>
> _______________________________________________
> [hidden email] mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-x11
> To unsubscribe, send any mail to "[hidden email]"
>
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Jonathan Anderson-2
On 11 Jun 2018, at 3:32, Johannes Lundberg wrote:

> For evdev simply add to your kernel config
>
> options        EVDEV_SUPPORT
> device        evdev

Is there a plan to add these options to amd64 GENERIC? If evdev is the
path forward for modern hardware (is that the correct assessment?), are
we moving towards including it on our install media?

Also, in case anyone's interested, I have a Jenkins job producing EVDEV
base packages daily. The package repository, should anyone else want to
use it for testing, is at https://allendale.engr.mun.ca/freebsd-evdev.
This repo is built daily with the following script:

```
export
MINE=https://raw.githubusercontent.com/trombonehero/freebsd/evdev-support
export KERNCONF=EVDEV
fetch \
        ${MINE}/sys/amd64/conf/${KERNCONF} \
     ${MINE}/sys/amd64/conf/${KERNCONF}-NODEBUG \
     -o sys/amd64/conf/

export KERNCONF=${KERNCONF}-NODEBUG

nice make -j32 buildworld
nice make -j32 buildkernel
nice make packages
```


Jon
--
[hidden email]
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Denis Polygalov
Enabling EVDEV in GENERIC kernel will also allow to compile weston -
(reference Wayland composer) without re-compiling the kernel.
Unfortunately I can not find link now, but few weeks ago I read
a report stating that using evdev in FreeBSD cause kernel panic
after DIS-connection of some devices....
I also would like to know - is the evdev is the right way
for FreeBSD or there is (will be) alternative solution?

Regards,
Denis.

On 11/06/2018 9:57 PM, Jonathan Anderson wrote:

> On 11 Jun 2018, at 3:32, Johannes Lundberg wrote:
>
>> For evdev simply add to your kernel config
>>
>> options        EVDEV_SUPPORT
>> device        evdev
>
> Is there a plan to add these options to amd64 GENERIC? If evdev is the
> path forward for modern hardware (is that the correct assessment?), are
> we moving towards including it on our install media?
>
> Also, in case anyone's interested, I have a Jenkins job producing EVDEV
> base packages daily. The package repository, should anyone else want to
> use it for testing, is at https://allendale.engr.mun.ca/freebsd-evdev.
> This repo is built daily with the following script:
>
> ```
> export
> MINE=https://raw.githubusercontent.com/trombonehero/freebsd/evdev-support
> export KERNCONF=EVDEV
> fetch \
>      ${MINE}/sys/amd64/conf/${KERNCONF} \
>      ${MINE}/sys/amd64/conf/${KERNCONF}-NODEBUG \
>      -o sys/amd64/conf/
>
> export KERNCONF=${KERNCONF}-NODEBUG
>
> nice make -j32 buildworld
> nice make -j32 buildkernel
> nice make packages
> ```
>
>
> Jon
> --
> [hidden email]
> _______________________________________________
> [hidden email] mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-x11
> To unsubscribe, send any mail to "[hidden email]"
>
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

pete wright
In reply to this post by Johannes Lundberg


On 06/10/2018 23:02, Johannes Lundberg wrote:

>
>
> On Sun, Jun 10, 2018 at 9:58 PM Pete Wright <[hidden email]
> <mailto:[hidden email]>> wrote:
>
>
>
>     On 06/10/2018 00:01, Niclas Zeising wrote:
>     > Hi!
>     > I've been working for a little while on incorporating the various
>     > patches floating around for changes and updates to xorg input
>     drivers,
>     > mostly related to libinput.  The result can be found here, in
>     the x11
>     > team development repo:
>     >
>     > https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>     >
>     > It contains upates to libinput, libeevdev, libwacom,
>     > xf86-input-libinput and dependencies.
>     >
>     > Please help me in testing this as much as possible, so that we can
>     > land it in the ports system
>     >
>     > The branch above is a complete ports tree, so you can use it to
>     build
>     > from, or to point poudriere at it.  Please test various input
>     devices,
>     > synaptics touchpads, wacom devices and so on.  Both success and
>     > failure stories are interesting.
>
>
>     i haven't had any issues installing pkgs via this branch. one
>     question
>     tho - i believe to make use of libevdev it requires a kernel built
>     with
>     evdev support correct?  if that is so - is there a specific patchset
>     that should be used?
>
>     i tested out evdev a while ago - but am not sure the patchset i have
>     laying around is the correct one.
>
>
> Hi
>
> For evdev simply add to your kernel config
>
> options     EVDEV_SUPPORT
> device        evdev
>

oh awesome - didn't realize it had been upstreamed.  thanks johannes!
-pete

--
Pete Wright
[hidden email]
@nomadlogicLA

_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Greg V
In reply to this post by Denis Polygalov
On 06/11, Denis Polygalov wrote:
>Enabling EVDEV in GENERIC kernel will also allow to compile weston -
>(reference Wayland composer) without re-compiling the kernel.
>Unfortunately I can not find link now, but few weeks ago I read
>a report stating that using evdev in FreeBSD cause kernel panic
>after DIS-connection of some devices....
>I also would like to know - is the evdev is the right way
>for FreeBSD or there is (will be) alternative solution?

Hi! I think the problem blocking evdev from on-by-default was the
keyboard deadlock that could happen when using the debugger:
https://reviews.freebsd.org/D15070

And of course evdev is the right way. We even have evdev-only drivers
now: wmt(4)
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Johannes Lundberg
In reply to this post by pete wright

Pete Wright writes:

> On 06/10/2018 23:02, Johannes Lundberg wrote:
>>
>>
>> On Sun, Jun 10, 2018 at 9:58 PM Pete Wright <[hidden email]
>> <mailto:[hidden email]>> wrote:
>>
>>
>>
>>     On 06/10/2018 00:01, Niclas Zeising wrote:
>>     > Hi!
>>     > I've been working for a little while on incorporating the various
>>     > patches floating around for changes and updates to xorg input
>>     drivers,
>>     > mostly related to libinput. The result can be found here, in
>>     the x11
>>     > team development repo:
>>     >
>>     > https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>>     >
>>     > It contains upates to libinput, libeevdev, libwacom,
>>     > xf86-input-libinput and dependencies.
>>     >
>>     > Please help me in testing this as much as possible, so that we can
>>     > land it in the ports system
>>     >
>>     > The branch above is a complete ports tree, so you can use it to
>>     build
>>     > from, or to point poudriere at it. Please test various input
>>     devices,
>>     > synaptics touchpads, wacom devices and so on. Both success and
>>     > failure stories are interesting.
>>
>>
>>     i haven't had any issues installing pkgs via this branch. one
>>     question
>>     tho - i believe to make use of libevdev it requires a kernel built
>>     with
>>     evdev support correct? if that is so - is there a specific patchset
>>     that should be used?
>>
>>     i tested out evdev a while ago - but am not sure the patchset i have
>>     laying around is the correct one.
>>
>>
>> Hi
>>
>> For evdev simply add to your kernel config
>>
>> options  EVDEV_SUPPORT
>> device  evdev
>>
>
> oh awesome - didn't realize it had been upstreamed. thanks johannes!
> -pete

Don't forget to set the sysctl. I have this in my /etc/sysctl.conf

# define        EVDEV_RCPT_SYSMOUSE     (1<<0)
# define        EVDEV_RCPT_KBDMUX       (1<<1)
# define        EVDEV_RCPT_HW_MOUSE     (1<<2)
# define        EVDEV_RCPT_HW_KBD       (1<<3)

# Legacy mode
#kern.evdev.rcpt_mask=3

# Libinput and friends
kern.evdev.rcpt_mask=12
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

pete wright


On 06/11/2018 12:29, Johannes Lundberg wrote:

> Pete Wright writes:
>
>> On 06/10/2018 23:02, Johannes Lundberg wrote:
>>>
>>> On Sun, Jun 10, 2018 at 9:58 PM Pete Wright <[hidden email]
>>> <mailto:[hidden email]>> wrote:
>>>
>>>
>>>
>>>      On 06/10/2018 00:01, Niclas Zeising wrote:
>>>      > Hi!
>>>      > I've been working for a little while on incorporating the various
>>>      > patches floating around for changes and updates to xorg input
>>>      drivers,
>>>      > mostly related to libinput. The result can be found here, in
>>>      the x11
>>>      > team development repo:
>>>      >
>>>      > https://github.com/FreeBSDDesktop/freebsd-ports/tree/feature/input
>>>      >
>>>      > It contains upates to libinput, libeevdev, libwacom,
>>>      > xf86-input-libinput and dependencies.
>>>      >
>>>      > Please help me in testing this as much as possible, so that we can
>>>      > land it in the ports system
>>>      >
>>>      > The branch above is a complete ports tree, so you can use it to
>>>      build
>>>      > from, or to point poudriere at it. Please test various input
>>>      devices,
>>>      > synaptics touchpads, wacom devices and so on. Both success and
>>>      > failure stories are interesting.
>>>
>>>
>>>      i haven't had any issues installing pkgs via this branch. one
>>>      question
>>>      tho - i believe to make use of libevdev it requires a kernel built
>>>      with
>>>      evdev support correct? if that is so - is there a specific patchset
>>>      that should be used?
>>>
>>>      i tested out evdev a while ago - but am not sure the patchset i have
>>>      laying around is the correct one.
>>>
>>>
>>> Hi
>>>
>>> For evdev simply add to your kernel config
>>>
>>> options  EVDEV_SUPPORT
>>> device  evdev
>>>
>> oh awesome - didn't realize it had been upstreamed. thanks johannes!
>> -pete
> Don't forget to set the sysctl. I have this in my /etc/sysctl.conf
>
> # define        EVDEV_RCPT_SYSMOUSE     (1<<0)
> # define        EVDEV_RCPT_KBDMUX       (1<<1)
> # define        EVDEV_RCPT_HW_MOUSE     (1<<2)
> # define        EVDEV_RCPT_HW_KBD       (1<<3)
>
> # Legacy mode
> #kern.evdev.rcpt_mask=3
>
> # Libinput and friends
> kern.evdev.rcpt_mask=12

thanks again johannes!

i've been running this on two drm-next systems for a day or so now
without issues.  one is a laptop with synaptics touchpad, other is a
workstation.  the biggest gap in my testing is that i don't have a
patch-set handy for evdev enabled xorg-server port handy.

i might take a look at past attempts and see if i can get it working
tonight - but if others have something working already i'd be keen to
check it out :)

-pete

--
Pete Wright
[hidden email]
@nomadlogicLA

_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Vladimir Kondratyev-3
In reply to this post by Niclas Zeising-5
On 2018-06-10 16:54, Niclas Zeising wrote:
> On 06/10/18 09:01, Niclas Zeising wrote:

> On request, attached is a patch with all changes.
> Regards

New libinput catches SIGSEGV in my setup. It looks like use-after-free
somewhere in libinput->libudev interaction.

The simplest way to reproduce is to run 'libinput list-devices' from
command line.

--
WBR
Vladimir Kondratyev
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"
Reply | Threaded
Open this post in threaded view
|

Re: [CFT] changes and updates to x11 input devices

Vladimir Kondratyev-3
On 2018-06-12 21:48, Vladimir Kondratyev wrote:

> On 2018-06-10 16:54, Niclas Zeising wrote:
>> On 06/10/18 09:01, Niclas Zeising wrote:
>
>> On request, attached is a patch with all changes.
>> Regards
>
> New libinput catches SIGSEGV in my setup. It looks like use-after-free
> somewhere in libinput->libudev interaction.
>
> The simplest way to reproduce is to run 'libinput list-devices' from
> command line.

Finally I was able to fix both X11 and libinput with following steps:

1. Revert epoll-shim. It fixed X11 device driver attachment. (New
version was working for me some time ago. I should check what has
happened recently)
2. Fix its linkage with adding 'LDFLAGS= -pthread -lrt' line to Makefile
3. Remove patch-src_evdev.c.reopen from libinput to fix 'libinput
list-devices' crash (The patch is integrated in to patch-src_evdev.c in
last revision)
4. Restore libinput-record with replacing versionsort with alphasort.
Add '${REINPLACE_CMD} -e 's|versionsort|alphasort|'  
${WRKSRC}/tools/libinput-record.c' to post-patch target.


--
WBR
Vladimir Kondratyev
_______________________________________________
[hidden email] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[hidden email]"