X11 Mutter crashes when applying Wacom Button mapping since Gnome 44
Affected version
- Fedora 38
- Gnome/Mutter 44.1
- XOrg
- Wacom Intuos BT M (Device ID 0x379)
Bug summary
Gnome Shell/Mutter crashes very frequently when it wants to apply the tablet button mapping This is a follow up to #2758 (closed) since the crashes are much more sever and disturbing than the button mapping not being applied.
Those crashes only happen on XOrg, not on Wayland. Those crashes did not happen with Gnome 43 on Fedora 37.
Steps to reproduce
The crash usually happens when re-entering the tablet area with the stylus and just hovering over it so that the mouse cursor moves between windows. Resting the stylus and picking it up again to use it happens very often (well, the way I use the stylus as a mouse replacement), thus the crashes happen very frequently, like every few seconds when constantly switching between keyboard and stylus.
Those crashes are not related to setting any Wacom parameters in Gnome settings. I've cleared all tablet settings using dconf-editor
, but this made no difference. The only way to get rid of those crashes is to remove the xorg-x11-drv-wacom
package, but this removes all possibilities to make any customization like setting aspect ratio or button mapping.
What happened
Gnome Shell restarts due to having crashed.
What did you expect to happen
Gnome Shell should not crash.
Relevant logs, screenshots, screencasts etc.
journalctl
says:
gnome-shell[20994]: Could not set stylus button map for Wacom Intuos BT M Pen stylus
gnome-shell[20994]: Could not set stylus button map for Wacom Intuos BT M Pen stylus
gnome-shell[20994]: Received an X Window System error.
This probably reflects a bug in the program.
The error was 'XI_BadDevice (invalid Device parameter)'.
(Details: serial 22478 error_code 129 request_code 131 (XInputExtension) minor_code 29)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the MUTTER_SYNC environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the meta_x_error() function.)
Stack trace of thread 20994:
#0 0x00007fb2ddab0844 __pthread_kill_implementation (libc.so.6 + 0x8e844)
#1 0x00007fb2dda5fabe raise (libc.so.6 + 0x3dabe)
#2 0x00005564efb22946 dump_gjs_stack_on_signal_handler (gnome-shell + 0x4946)
#3 0x00007fb2dda5fb70 __restore_rt (libc.so.6 + 0x3db70)
#4 0x00007fb2de146a2f g_log_structured_array (libglib-2.0.so.0 + 0x61a2f)
#5 0x00007fb2de146d1c g_log_default_handler (libglib-2.0.so.0 + 0x61d1c)
#6 0x00007fb2de146fc0 g_logv (libglib-2.0.so.0 + 0x61fc0)
#7 0x00007fb2de1472a3 g_log (libglib-2.0.so.0 + 0x622a3)
#8 0x00007fb2ddd138ee meta_x_error (libmutter-12.so.0 + 0x1138ee)
#9 0x00007fb2dd6cd8ab _XError (libX11.so.6 + 0x4b8ab)
#10 0x00007fb2dd6cd9bf handle_error (libX11.so.6 + 0x4b9bf)
#11 0x00007fb2dd6cf9aa _XReply (libX11.so.6 + 0x4d9aa)
#12 0x00007fb2dbddd8d0 XSetDeviceButtonMapping (libXi.so.6 + 0xb8d0)
#13 0x00007fb2ddd03c5f meta_input_settings_x11_set_stylus_button_map (libmutter-12.so.0 + 0x103c5f)
#14 0x00007fb2ddcfa97a meta_clutter_backend_x11_translate_event (libmutter-12.so.0 + 0xfa97a)
#15 0x00007fb2ddda0d78 meta_x11_handle_event.isra.0 (libmutter-12.so.0 + 0x1a0d78)
#16 0x00007fb2ddcf87ef x_event_source_dispatch (libmutter-12.so.0 + 0xf87ef)
#17 0x00007fb2de14139c g_main_context_dispatch (libglib-2.0.so.0 + 0x5c39c)
#18 0x00007fb2de19f438 g_main_context_iterate.isra.0 (libglib-2.0.so.0 + 0xba438)
#19 0x00007fb2de14099f g_main_loop_run (libglib-2.0.so.0 + 0x5b99f)
#20 0x00007fb2ddcd53ba meta_context_run_main_loop (libmutter-12.so.0 + 0xd53ba)
#21 0x00005564efb21f87 main (gnome-shell + 0x3f87)
#22 0x00007fb2dda49b4a __libc_start_call_main (libc.so.6 + 0x27b4a)
#23 0x00007fb2dda49c0b __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x27c0b)
#24 0x00005564efb22265 _start (gnome-shell + 0x4265)
Note that setting the button mapping manually by using
xinput set-button-map "Wacom Intuos BT M Pen stylus" 1 3 2 4 5 6 7 8
or
xsetwacom --set "Wacom Intuos BT M Pen stylus" button 2 3
xsetwacom --set "Wacom Intuos BT M Pen stylus" button 3 2
works just fine, so I would say that X11/libinput seems to work just fine with the tablet.