File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -938,15 +938,15 @@ static void gfx_ctx_drm_input_driver(void *data,
938938 const char * joypad_name ,
939939 input_driver_t * * input , void * * input_data )
940940{
941- #ifdef HAVE_X11
942941 settings_t * settings = config_get_ptr ();
943942
944- /* We cannot use the X11 input driver for DRM/KMS */
945- if (string_is_equal (settings -> arrays .input_driver , "x" ))
943+ /* We cannot use the X11 input driver for DRM/KMS, and udev may be restricted */
944+ if ( string_is_equal (settings -> arrays .input_driver , "x" )
945+ || string_is_equal (settings -> arrays .input_driver , "udev" ))
946946 {
947947#ifdef HAVE_UDEV
948948 {
949- /* Try to set it to udev instead */
949+ /* Try to set it to udev */
950950 void * udev = input_driver_init_wrap (& input_udev , joypad_name );
951951 if (udev )
952952 {
@@ -958,7 +958,7 @@ static void gfx_ctx_drm_input_driver(void *data,
958958#endif
959959#if defined(__linux__ ) && !defined(ANDROID )
960960 {
961- /* Try to set it to linuxraw instead */
961+ /* Try to set it to linuxraw if not available or failed to initialize */
962962 void * linuxraw = input_driver_init_wrap (& input_linuxraw , joypad_name );
963963 if (linuxraw )
964964 {
@@ -969,7 +969,6 @@ static void gfx_ctx_drm_input_driver(void *data,
969969 }
970970#endif
971971 }
972- #endif
973972
974973 * input = NULL ;
975974 * input_data = NULL ;
You can’t perform that action at this time.
0 commit comments