Re: [PATCH] bluetooth: fix missing 'connected' notifications (rh #1255284)
On Sun, 2015-10-25 at 19:55 +0100, Thomas Haller wrote: > On Fri, 2015-10-23 at 11:50 -0500, Dan Williams wrote: > > Because Bluez5 dropped DUN support, NM must do that manually which > > includes emulating the "connected" property for Bluetooth devices > > when > > DUN is used. It does this by setting priv->connected = TRUE in > > nm_bluez_device_connect_finish(). > > > > But for PAN, when NM does process the 'connected' property change > > notification, priv->connected is already TRUE and > > _take_variant_property_connected() does nothing. Hence the > > corresponding GObject property notification is not emitted, > > nm-device-bt.c::check_connect_continue() will never return success, > > and > > the activation times out. > > > > To fix this, ensure that GObject notifications are emitted when the > > device is connected, even if emulated internally. > > > > > Patch looks good to me. > I merged the patch: > > master: > http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=0e3086e8b885164f24b43a1060cb1f87a62723a8 > > nm-1-0: > http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=cccb8fe5e6945085d43050411c1ced26453d85df Thanks! Dan ___ networkmanager-list mailing list networkmanager-list@gnome.org https://mail.gnome.org/mailman/listinfo/networkmanager-list
Re: [PATCH] bluetooth: fix missing 'connected' notifications (rh #1255284)
On Fri, 2015-10-23 at 11:50 -0500, Dan Williams wrote: > Because Bluez5 dropped DUN support, NM must do that manually which > includes emulating the "connected" property for Bluetooth devices > when > DUN is used. It does this by setting priv->connected = TRUE in > nm_bluez_device_connect_finish(). > > But for PAN, when NM does process the 'connected' property change > notification, priv->connected is already TRUE and > _take_variant_property_connected() does nothing. Hence the > corresponding GObject property notification is not emitted, > nm-device-bt.c::check_connect_continue() will never return success, > and > the activation times out. > > To fix this, ensure that GObject notifications are emitted when the > device is connected, even if emulated internally. > Patch looks good to me. I merged the patch: master: http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=0e3086e8b885164f24b43a1060cb1f87a62723a8 nm-1-0: http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=cccb8fe5e6945085d43050411c1ced26453d85df Thomas signature.asc Description: This is a digitally signed message part ___ networkmanager-list mailing list networkmanager-list@gnome.org https://mail.gnome.org/mailman/listinfo/networkmanager-list
[PATCH] bluetooth: fix missing 'connected' notifications (rh #1255284)
Because Bluez5 dropped DUN support, NM must do that manually which includes emulating the "connected" property for Bluetooth devices when DUN is used. It does this by setting priv->connected = TRUE in nm_bluez_device_connect_finish(). But for PAN, when NM does process the 'connected' property change notification, priv->connected is already TRUE and _take_variant_property_connected() does nothing. Hence the corresponding GObject property notification is not emitted, nm-device-bt.c::check_connect_continue() will never return success, and the activation times out. To fix this, ensure that GObject notifications are emitted when the device is connected, even if emulated internally. --- diff --git a/src/devices/bluetooth/nm-bluez-device.c b/src/devices/bluetooth/nm-bluez-device.c index cc44b9e..b703214 100644 --- a/src/devices/bluetooth/nm-bluez-device.c +++ b/src/devices/bluetooth/nm-bluez-device.c @@ -600,8 +600,10 @@ nm_bluez_device_connect_finish (NMBluezDevice *self, return NULL; device = (const char *) g_simple_async_result_get_op_res_gpointer (simple); - if (device && priv->bluez_version == 5) + if (device && priv->bluez_version == 5) { priv->connected = TRUE; + g_object_notify (G_OBJECT (self), NM_BLUEZ_DEVICE_CONNECTED); + } return device; } ___ networkmanager-list mailing list networkmanager-list@gnome.org https://mail.gnome.org/mailman/listinfo/networkmanager-list