mirror of
https://github.com/libretro/RetroArch
synced 2025-03-05 10:13:51 +00:00
This change makes the call to 'udev_enumerate_scan_devices' much faster. In particular, for some bluetooth devices, this function may implicitly read its battery's virtual file 'uevent', e.g. /sys/devices/*/usb1/1-1/*/bluetooth/hci0/*/power_supply/hid-*-battery/uevent Reading this file may (for unknown reasons) block up to 10 seconds. Since udev_enumerate_scan_devices is called 4 times (for keyboard, mouse, touchpad, and joypad) during startup this may cause a considerable delay. Limiting the scan to subsystem 'input' yields the same devices but makes the scan faster and does not read 'uevent' of the input controller's power_supply.