Hi Kalle,
> > This patch will fix a bug regarding ConnMan not starting
> > wpa_supplican when using new supplican interface.
>
> I noticed the same issue. I created a bit different patch for this and
> was supposed to send it to the list, but I can't find it from the
> archives anymore. I'll send it now anyway.
>
> (git-send is not working for me right now, so I need to copy-paste this.
> Sorry about that.)
>
> gsupplicant: enable dbus auto start
>
> From: Kalle Valo <[email protected]>
>
> In Ubuntu wpasupplicant is started with dbus auto activation, but
> gsupplicant
> disables this feature and hence wifi didn't work at all. Enable this feature
> to make it possible to start wpasupplicant when needed.
>
> I don't know how other distros start wpasupplicant, but at least with
> wifi-legacy wpasupplicant was automatically started by dbus.
> ---
> gsupplicant/dbus.c | 2 --
> gsupplicant/supplicant.c | 6 +++---
> 2 files changed, 3 insertions(+), 5 deletions(-)
>
> diff --git a/gsupplicant/dbus.c b/gsupplicant/dbus.c
> index 53c56ae..2301807 100644
> --- a/gsupplicant/dbus.c
> +++ b/gsupplicant/dbus.c
> @@ -154,8 +154,6 @@ int supplicant_dbus_property_get_all(const char
> *path, const char *interface,
> return -ENOMEM;
> }
>
> - dbus_message_set_auto_start(message, FALSE);
> -
> dbus_message_append_args(message, DBUS_TYPE_STRING, &interface, NULL);
this patch is wrong. The non-autostart stuff is there on purpose. We do
want control when the daemon is started. And more important in case of
crash situation to be able to clean this properly.
The whole D-Bus autostart by default is stupid btw. If you don't monitor
the daemon going away properly, you end up in all kinds of weird
situations.
> if (dbus_connection_send_with_reply(connection, message,
> diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c
> index 322b63d..4b62ad3 100644
> --- a/gsupplicant/supplicant.c
> +++ b/gsupplicant/supplicant.c
> @@ -2421,12 +2421,12 @@ int g_supplicant_register(const
> GSupplicantCallbacks *callbacks)
> dbus_connection_flush(connection);
>
> if (dbus_bus_name_has_owner(connection,
> - SUPPLICANT_SERVICE, NULL) == TRUE) {
> + SUPPLICANT_SERVICE, NULL) == TRUE)
> system_available = TRUE;
> - supplicant_dbus_property_get_all(SUPPLICANT_PATH,
> +
> + supplicant_dbus_property_get_all(SUPPLICANT_PATH,
> SUPPLICANT_INTERFACE,
> service_property, NULL);
> - }
I actually prefer to autostart a daemon by asking for the introspection
data and not via an actual method call. Just a quick hint here.
Regards
Marcel
_______________________________________________
connman mailing list
[email protected]
http://lists.connman.net/listinfo/connman