Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Kernel & Hardware
  • Search

libinput doesn't recognise any devices

Kernel not recognizing your hardware? Problems with power management or PCMCIA? What hardware is compatible with Gentoo? See here. (Only for kernels supported by Gentoo.)
Post Reply
Advanced search
26 posts
  • 1
  • 2
  • Next
Author
Message
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

libinput doesn't recognise any devices

  • Quote

Post by zinstack » Thu Nov 09, 2017 6:16 am

So my problem is I want to use libinput, but libinput-list-devices shows none and libinput-debug-events shows "Expected device added events on startup but got none. Maybe you don't have the right permissions?". But, in fact, i use root with all these commands. All the devices show up in dmesg and, using cat, I managed to find needed devices in /dev/input/event*, and currently I have keyboard mapped to /dev/input/event5 and touchpad mapped to /dev/input/event9. GPM works just perfectly. I have a synaptics touchpad, some "general" ps/2 keyboard, a laptop and a lot of time. I have all drivers incompiled, run without initrd and have absolutely no modules. EVDEV, PS2_SYNAPTICS and PS2_SYNAPTICS_SMBUS were set to yes. Maybe that's because I messed up with use flags? I tried not to edit them and in /etc/portage/make.conf only have alsa and input_devices_libinput. After switching to kde profile it didn't help either (before there was a clean default/linux/amd64/13.0 one). More than that, X doesn't recognise my keyboard. So what am I doing wrong? How do I fix this?
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Thu Nov 09, 2017 7:50 am

Do you have an Xorg log, the best advice I can give you is to include in your post some of the basic troubleshooting information and then let someone help steer you over to victory! For what you described, I would think that an X log should show an error regarding the keyboard. Also, depending on the Xorg configuration file, kernel settings, etc. there's a lot of potential things that could be an issue so it is helpful to see the output from your system.

If you like post back using wgetpaste or similar pastebin tool with emerge --info, and any relevant logs (the Xorg.log is important) that are stored in the folder /var/log and you should be able to catch the attention of some good answers from adding some more of that type of information here to the picture!
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Thu Nov 09, 2017 12:10 pm

Here are my settings and logs. The problem is not in Xorg, its libinput. And, I think the keyboard problem has the same cause as a touchpad, so it will probably be easy to solve, just as we know why doesn't libinput work as intended.
Top
mir3x
Guru
Guru
User avatar
Posts: 455
Joined: Sat Jun 02, 2012 3:22 pm

  • Quote

Post by mir3x » Thu Nov 09, 2017 5:25 pm

You don't have even anything related to libinput in logs.
Something like:

Code: Select all

(II) LoadModule: "libinput"
(II) Loading /usr/lib64/xorg/modules/input/libinput_drv.so
(II) Module libinput: vendor="X.Org Foundation
(II) Using input driver 'libinput' for 'Keyboard0'
(II) Using input driver 'libinput' for 'Mouse0'
"
Have u configured xorg.conf ?
Have u added libinput to INPUT_DEVICES in make.conf ?
Sent from Windows
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Fri Nov 10, 2017 8:09 pm

mir3x wrote: Have u configured xorg.conf ?
Have u added libinput to INPUT_DEVICES in make.conf ?
libinput has been added to input devices, but no effect, as expected, haven't touched xorg.conf though (haven't found that yet, do you mean xorg.conf.d, if yes, then of cource i did), but, as I already said, the problem is not that xorg doesn't read libinput, it is that libinput doesn't read devices. I guess it has something to do with the daemons or rc.
Last edited by zinstack on Fri Nov 10, 2017 8:16 pm, edited 1 time in total.
Top
mir3x
Guru
Guru
User avatar
Posts: 455
Joined: Sat Jun 02, 2012 3:22 pm

  • Quote

Post by mir3x » Fri Nov 10, 2017 8:11 pm

Your problem is xorg doesnt even try to use libinput.
And I meant xorg.conf
Sent from Windows
Top
Myu
Apprentice
Apprentice
User avatar
Posts: 164
Joined: Wed Oct 22, 2014 7:28 am
Location: Belgium

  • Quote

Post by Myu » Fri Nov 10, 2017 8:43 pm

For what it's worth, I've this file in /etc/X11/xorg.conf.d/40-libinput.conf

Code: Select all

# Match on all types of devices but tablet devices and joysticks
Section "InputClass"
        Identifier "libinput pointer catchall"
        MatchIsPointer "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput keyboard catchall"
        MatchIsKeyboard "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchpad catchall"
        MatchIsTouchpad "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput touchscreen catchall"
        MatchIsTouchscreen "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection

Section "InputClass"
        Identifier "libinput tablet catchall"
        MatchIsTablet "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
EndSection
I guess that's the one which makes it all work fine ? I didn't had to write it
Gentoo stable with bits of ~amd64 // Xfce 4.13 + Compiz Reloaded.
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Sat Nov 11, 2017 1:34 am

Something I just realized about my own similar issue with using libinput on my laptop as a replacemet for evdev and synaptics, is that while the wiki says the following:
It is a drop-in replacement for the slowly deprecating evdev and synaptics input drivers
This isn't actually totally agreed on, and with other distributions that is not the advice always. Also note that might depend on a few different things, such as desktop versus laptop hardware and also the Desktop environment in use.
Last edited by LIsLinuxIsSogood on Sat Nov 11, 2017 1:44 am, edited 1 time in total.
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Sat Nov 11, 2017 1:43 am

If you are sticking with libinput as your driver (not sure if that's a good idea), but here is what the wiki desribesto make sure that X can be aware of libinput.
In other words, it is not enough to simply compile it with the use flag, but you actually have to go the extra step of configuring, as mentioned in the wiki here:

Code: Select all

root #ln -s /usr/share/X11/xorg.conf.d/40-libinput.conf /etc/X11/xorg.conf.d/
Explanation: The reason for this to me is not totally clear, but I think because there may not have been a chance to remove previous software (by running an emerge --depclean at this point, after installing libinput) that X can easily get confused about what drivers to attempt to load, and this provides the answer to that. Another way would be just copy past the information provided in the previous post for the file, after opening a new file in /etc/X11/xorg.conf.d/ with the name 40-libinput.conf

Or just wait until libinput and Xorg find a more seemless way for your particular system to get upgraded...that is what I'm hopeful about later. At this point, I'm not sure your rush to get onto libinput (since I doubt it will make any noticeable difference) unless you are an application programmer or something like that, I would just change it back and then maybe later figure it out.
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Sat Nov 11, 2017 10:12 am

Do you even guys read my messages? Even with 40-libinput.conf in xorg.conf.d and libinput in INPUT_DEVICES, xorg won't use the keyboard or touchpad, because if libinput doesn't have a basic idea of input devices in my system, the xorg won't as well. I'm telling again: the main problem is in libinput, not xorg, if xorg doesn't use libinput it's just another story and has a very easy fix of editing some config files and maybe recompiling xserver, but, mainly I was surprised by that libinput doesn't recognise any devices. It's no surprise that xinput won't show anything useful. Yes, I had problems with X not using libinput, but this is just above the water. As I already texted in my latest message, I already have everything set up, just as needed, but neither the keybord, nor the touchpad are having no effect, though in logs it does show that it loads libinput.
Top
Ant P.
Watchman
Watchman
Posts: 6920
Joined: Sat Apr 18, 2009 7:18 pm
Contact:
Contact Ant P.
Website

  • Quote

Post by Ant P. » Sat Nov 11, 2017 8:50 pm

You're right, this isn't anything to do with Xorg (so far). Besides, most of the suggestions above to change xorg.conf are wrong and misleading. Xorg loads files from /usr/share/X11/xorg.conf.d automatically, copying or linking things from there does nothing at best and more likely makes things worse. But that can wait until later.


It would help to figure out what's going on if we could see the full output from the following:

Code: Select all

# emerge -pv dev-libs/libinput x11-drivers/xf86-input-libinput /etc/udev
# ls -l /dev/input
# libinput-list-devices
# strace libinput-list-devices 2>&1 1>/dev/null    # (if it's not too long)
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Sun Nov 12, 2017 2:12 pm

Ant P. wrote:You're right, this isn't anything to do with Xorg (so far). Besides, most of the suggestions above to change xorg.conf are wrong and misleading. Xorg loads files from /usr/share/X11/xorg.conf.d automatically, copying or linking things from there does nothing at best and more likely makes things worse. But that can wait until later.


It would help to figure out what's going on if we could see the full output from the following:

Code: Select all

# emerge -pv dev-libs/libinput x11-drivers/xf86-input-libinput /etc/udev
# ls -l /dev/input
# libinput-list-devices
# strace libinput-list-devices 2>&1 1>/dev/null    # (if it's not too long)
Thanks for the reply!
Here is emerge's output:

Code: Select all

These are the packages that would be merged, in order:

Calculating dependencies  ........ done!
[ebuild   R    ] sys-fs/eudev-3.1.5::gentoo  USE="hwdb introspection kmod -rule-generator (-selinux) -static-libs {-test}" ABI_X86="(64) -32 (-x32)" 0 KiB
[ebuild   R    ] dev-libs/libinput-1.7.3:0/10::gentoo  USE="{-test}" INPUT_DEVICES="-wacom" 0 KiB
[ebuild   R    ] x11-drivers/xf86-input-libinput-0.25.1::gentoo  0 KiB

Total: 3 packages (3 reinstalls), Size of downloads: 0 KiB

 * IMPORTANT: 15 news items need reading for repository 'gentoo'.
 * Use eselect news read to view new items.
Here's the ls's output:

Code: Select all

total 0
crw------- 1 root root 13, 64 nov 12 15:38 event0
crw------- 1 root root 13, 65 nov 12 15:38 event1
crw------- 1 root root 13, 66 nov 12 15:38 event2
crw------- 1 root root 13, 67 nov 12 15:38 event3
crw------- 1 root root 13, 68 nov 12 15:38 event4
crw------- 1 root root 13, 69 nov 12 15:38 event5
crw------- 1 root root 13, 70 nov 12 15:38 event6
crw------- 1 root root 13, 71 nov 12 15:38 event7
crw------- 1 root root 13, 72 nov 12 15:38 event8
crw------- 1 root root 13, 73 nov 12 15:38 event9
crw------- 1 root root 13, 63 nov 12 15:38 mice
crw------- 1 root root 13, 32 nov 12 15:38 mouse0
Never seen "total 0" message on ls, never used it with -l though...
Libinput-list-devices gave no output and strace's message was extremely huge, so I couldn's copy it even from the window term from ssh.
Top
mir3x
Guru
Guru
User avatar
Posts: 455
Joined: Sat Jun 02, 2012 3:22 pm

  • Quote

Post by mir3x » Sun Nov 12, 2017 3:21 pm

So maybe you installed xorg with 'minimal' flag enabled ? If yes then disable it.

Code: Select all

equery uses xorg-server
Sent from Windows
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Sun Nov 12, 2017 3:36 pm

mir3x wrote:So maybe you installed xorg with 'minimal' flag enabled ? If yes then disable it.

Code: Select all

equery uses xorg-server
No I didn't. The thread is full of my messages about xorg doing nothing bad. If you have a want to help me, please get aquented with what is already known.
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Mon Nov 13, 2017 5:02 am

Edit: I didn't see the response from Ant P. requesting more info, so I retract all of this below.



zinstack, I realize you are frustrated because it is not a quick answer or the one you want, but in fairness to everyone else, since you have not yet posted the result of emerge --info xorg-server or xorg anything-else, not only is it hard to say what may be the problem, but also concerning is you've provided no support to the problem being outside or not within Xorg. Personally, I think if you are not against sharing it, then you should bypass your own beliefs and then share that information about xorg, since that is what is being asked. It seems like a critical component here, since regardless whether you are running Wayland or whatever libinput is a requirement and has to work with both of those systems (or either one). Do you catch my drift?

I will stick to my initial suggestion for you to bypass libinput drivers in favor of the slowly deprecated ones (evdev and synaptics) but that is because you are so concerned with the use of drivers, when in reality it really doesn't matter as long as things work.

But, just so you have some faith in my answer as well, there is no reason to think that evdev is going to be at least any time in the near future an obsolete tool.
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Mon Nov 13, 2017 7:01 am

strace's message was extremely huge, so I couldn's copy it even from the window term from ssh.
Sorry for the massive confusion, and for not reading posts more careful.

1st of all, I did not realize from the links provided and the messages for the strace being long, you should have already been told about the useful tool for pastebin on the web, there are several options I use wgetpaste.

Code: Select all

emerge --ask app-text/wgetpaste
With that you should be able to include all the output from the strace, and whatever else it was you can't fit in the little box.

Again sorry.

Also, in terms of the following message you are getting, I have never seen it before. Perhaps you could include some further output from dmesg about this?
"Expected device added events on startup but got none. Maybe you don't have the right permissions?"
Top
krinn
Watchman
Watchman
User avatar
Posts: 7476
Joined: Fri May 02, 2003 6:14 am

Re: libinput doesn't recognise any devices

  • Quote

Post by krinn » Mon Nov 13, 2017 10:58 am

zinstack wrote:"Expected device added events on startup but got none. Maybe you don't have the right permissions?".
Well, as nearly always, it just point the problem, but you ignore it, it's not your fault, we all do that.
zinstack wrote:

Code: Select all

total 0
crw------- 1 root root 13, 64 nov 12 15:38 event0
crw------- 1 root root 13, 65 nov 12 15:38 event1 
And here's mine, note the permissions and the group owner

Code: Select all

crw-rw---- 1 root input 13, 65 Oct 24 10:21 event1
crw-rw---- 1 root input 13, 63 Oct 24 10:21 mice
So you have to dig why your device manager is doing that.
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

Re: libinput doesn't recognise any devices

  • Quote

Post by zinstack » Mon Nov 13, 2017 1:40 pm

krinn wrote:
zinstack wrote:"Expected device added events on startup but got none. Maybe you don't have the right permissions?".
Well, as nearly always, it just point the problem, but you ignore it, it's not your fault, we all do that.
zinstack wrote:

Code: Select all

total 0
crw------- 1 root root 13, 64 nov 12 15:38 event0
crw------- 1 root root 13, 65 nov 12 15:38 event1 
And here's mine, note the permissions and the group owner

Code: Select all

crw-rw---- 1 root input 13, 65 Oct 24 10:21 event1
crw-rw---- 1 root input 13, 63 Oct 24 10:21 mice
So you have to dig why your device manager is doing that.
That didn't help, but still thanks for a suggestion!
LIsLinuxIsSogood wrote:
strace's message was extremely huge, so I couldn's copy it even from the window term from ssh.
Sorry for the massive confusion, and for not reading posts more careful.

1st of all, I did not realize from the links provided and the messages for the strace being long, you should have already been told about the useful tool for pastebin on the web, there are several options I use wgetpaste.

Code: Select all

emerge --ask app-text/wgetpaste
With that you should be able to include all the output from the strace, and whatever else it was you can't fit in the little box.

Again sorry.

Also, in terms of the following message you are getting, I have never seen it before. Perhaps you could include some further output from dmesg about this?
"Expected device added events on startup but got none. Maybe you don't have the right permissions?"
Thanks for that, I've got the strace now. Here it is. And here is dmesg.
Top
Jaglover
Watchman
Watchman
User avatar
Posts: 8291
Joined: Sun May 29, 2005 1:57 am
Location: Saint Amant, Acadiana

  • Quote

Post by Jaglover » Mon Nov 13, 2017 6:12 pm

Despite repeated requests there is no emerge --info. Thus we do not know what init system is used and anything else about this system. Anyhow, there is a udev rule responsible for assigning input group, /etc/udev/rules.d/99-dev-input-group.rules.
My Gentoo installation notes.
Please learn how to denote units correctly!
Top
LIsLinuxIsSogood
Veteran
Veteran
Posts: 1186
Joined: Sat Feb 13, 2016 11:41 pm

  • Quote

Post by LIsLinuxIsSogood » Mon Nov 13, 2017 6:24 pm

Providing emerge—info dev-libs/libinput and x11-drivers/xf86-input-libinput, please if possible..

Those permission bits as krinn mentioned and as pointed to earlier are probably not right, so lets check into that.
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Mon Nov 13, 2017 7:12 pm

Ok, sorry. I always forget. Here is "emerge --info", "emerge --info libinput", and "emerge --info xf86-input-libinput". Oh, and I've found that dhcpcd is also having trouble finding interfaces, even though wlan0 is up and connected. Guess that may be useful.
Top
Jaglover
Watchman
Watchman
User avatar
Posts: 8291
Joined: Sun May 29, 2005 1:57 am
Location: Saint Amant, Acadiana

  • Quote

Post by Jaglover » Mon Nov 13, 2017 7:19 pm

Code: Select all

rc-config show all
Check out if your udev and udev-trigger are started in sysinit runlevel.
My Gentoo installation notes.
Please learn how to denote units correctly!
Top
zinstack
n00b
n00b
Posts: 12
Joined: Wed Nov 08, 2017 8:09 pm
Location: Moscow

  • Quote

Post by zinstack » Mon Nov 13, 2017 7:51 pm

Jaglover wrote:

Code: Select all

rc-config show all
Check out if your udev and udev-trigger are started in sysinit runlevel.
Oh my... I thought I've checked that in the very beginning! Everything just started working. Thanks so much to you all for helping me! Never thought I could be THAT dumb.
Top
Ant P.
Watchman
Watchman
Posts: 6920
Joined: Sat Apr 18, 2009 7:18 pm
Contact:
Contact Ant P.
Website

  • Quote

Post by Ant P. » Tue Nov 21, 2017 9:10 pm

zinstack wrote:Oh my... I thought I've checked that in the very beginning! Everything just started working. Thanks so much to you all for helping me! Never thought I could be THAT dumb.
Sorry for not replying sooner (my router decided to die last week...) but good to see it got figured out.

The root/root 0600 perms are a dead giveaway that udev failed to start, and everything else stems from that. Don't blame yourself for it, this one bug is pretty common and I've never figured out what causes it. The only reason I didn't mention it initially was I thought it was due to my weird setup and couldn't possibly happen in openrc; guess I was wrong.
Top
Melunlina
n00b
n00b
Posts: 2
Joined: Mon Jun 04, 2018 3:46 am

  • Quote

Post by Melunlina » Thu Mar 31, 2022 5:24 am

Thanks guys, starting the udev and udev-trigger services manually solved the same problem with my new Logitech G413 keyboard. Curious, why these services were stopped.
Top
Post Reply

26 posts
  • 1
  • 2
  • Next

Return to “Kernel & Hardware”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic