Please sign in to comment.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[dbus] Improve SystemBus connection management. MER#1694
D-Bus SystemBus connection is made from several places. Explicitly from the main() and implicitly from various modules that do ipc with other components. This makes it hard to tell when connection actually gets made, process wide dbus initialization happens in the wrong place and setting up signal matches is delayed by the synchronous initialization activity during startup. Move dbus_threads_init_default() to more appropriate place so that it actually is the first libdbus call that gets made. Handle connecting to SystemBus and installing signal listeners as early as possible and claim usb-moded service name separately when usb-moded is ready to process requests made over D-Bus. Add usb_moded_dbus_get_connection() function that other modules can use to get reference to the SystemBus connection when/if one has been made from the main logic. Signed-off-by: Simo Piiroinen <email@example.com>
- Loading branch information
Showing with 80 additions and 26 deletions.