Skip to content

Subsystem management updates in the core

This merge request introduces some changes in the way subsystems are managed in the core daemon:

In the first change we stop monitoring the "usb" subsystem completely. This subsystem was being used for two different things: for cdc-wdm port notifications in kernel < 3.6 (before the "usbmisc" subsystem name was introduced), and for full USB device removal notifications (as the "usb" subsystem notifies also USB interface and USB device events), The loss of the pre-3.6 kernel support isn't a big issue, and the loss of the full device removal notifications also shouldn't be, because we must make sure that the modem object is completely removed when the last port is notified as removed, and not only in USB modems, in all modem kinds.

The second change is related to how we monitor subsystems in the core daemon. Instead of hardcoding the list of subsystems to keep an eye on (e.g. "tty", "net", "usbmisc") we now rely on the plugins telling us what we should monitor. E.g. if a system build is done with one single tty-only plugin, we won't monitor the net or usbmisc subsystems. This is also very helpful when building MM for setups that introduced their own subsystem types (e.g. Qualcomm SoCs introducing the ports via rpmsg subsystem).

The third change introduces a "per-subsystem" logic to decide what the plugin needs to probe in each port, without relying on device port names, which are easy to change.

Edited by Aleksander Morgado

Merge request reports