• Jussi Laakkonen's avatar
    [connman] Add developer mode tracking/query plugin. JB#43928 · bcec6362
    Jussi Laakkonen authored
    This commit adds a plugin to monitor and react to developer mode changes
    in Sailfis OS. When a change is detected connman_device_status_notify()
    is called with appropriate values.
    Using rtnl notifier and device.c to check if the device that was brought
    up & running or put down, exists and has a device. Bluetooth, cellular,
    GPS and WiFi devices are ignored, they are never developer mode devices.
    Plugin reports the device to be non-managed (managed = false), so
    connman should not manage it.
    The device brought up must be also running and have lower layer set as
    well (carrier is setup). If a device exists and usb moded is in correct
    state (developer mode), call notifier. If the usb moded is not queried
    the status is explicitely queried and notification is sent when reply is
    This plugin keeps a reference of all devices that have been detected
    being up. This is because rtnl priority for the plugin is low to get the
    notification after device.c has added a struct connman_device. But a
    reference must be kept for removal since with low rtnl priority device.c
    has already removed the struct connman_device. The notification is only
    done for the devices that have been added to the internal list and are
    queried only from there.
    Plugin also listens for status change signals from usb moded.
    If an interface is put down notifier is called after device checks. Even
    when interface goes down there must be a device for it. After this the
    device is removed from internal list.
Last commit
Last update
connman.spec Loading commit data...
main.conf Loading commit data...