Dear systemd folks,
Trying to decrease the start-up time, I noticed that `systemd-logind` probes devices in serial(?) (instead of parallel). From `manager_enumerate_buttons(Manager *m)` in `src/login/logind.c`: ``` udev_list_entry_foreach(item, first) { _cleanup_(udev_device_unrefp) struct udev_device *d = NULL; int k; d = udev_device_new_from_syspath(m->udev, udev_list_entry_get_name(item)); if (!d) return -ENOMEM; k = manager_process_button_device(m, d); if (k < 0) r = k; } ``` The macro is defined as below: ``` /** * udev_list_entry_foreach: * @list_entry: entry to store the current position * @first_entry: first entry to start with * * Helper to iterate over all entries of a list. */ #define udev_list_entry_foreach(list_entry, first_entry) \ for (list_entry = first_entry; \ list_entry != NULL; \ list_entry = udev_list_entry_get_next(list_entry)) ``` Is there a way to do that in parallel? Kind regards, Paul
smime.p7s
Description: S/MIME Cryptographic Signature
_______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel