From bbdcbd93cb1ab87e2375b6da7ed69458440e9880 Mon Sep 17 00:00:00 2001 From: chewitt Date: Sun, 15 Nov 2015 20:42:04 +0400 Subject: [PATCH] connman: update to connman-1.30 --- packages/network/connman/package.mk | 2 +- ...ve-the-DHCP-server-IP-when-REBOOTING.patch | 32 ------- ...covery-request-timeout-and-retry-val.patch | 38 -------- ...-an-actual-IP-address-when-rebinding.patch | 35 -------- ...-crashes-when-connected-to-network-w.patch | 90 ------------------- 5 files changed, 1 insertion(+), 196 deletions(-) delete mode 100644 packages/network/connman/patches/connman-07_gdhcp-Save-the-DHCP-server-IP-when-REBOOTING.patch delete mode 100644 packages/network/connman/patches/connman-08_gdhcp-adjust-discovery-request-timeout-and-retry-val.patch delete mode 100644 packages/network/connman/patches/connman-09_gdhcp-Request-an-actual-IP-address-when-rebinding.patch delete mode 100644 packages/network/connman/patches/connman-10_dhcp-Fix-further-crashes-when-connected-to-network-w.patch diff --git a/packages/network/connman/package.mk b/packages/network/connman/package.mk index 57866d6fea..2ef77c7229 100644 --- a/packages/network/connman/package.mk +++ b/packages/network/connman/package.mk @@ -18,7 +18,7 @@ PKG_NAME="connman" # DO NOT UPGRADE!! -PKG_VERSION="1.23" +PKG_VERSION="1.30" PKG_REV="1" PKG_ARCH="any" PKG_LICENSE="GPL" diff --git a/packages/network/connman/patches/connman-07_gdhcp-Save-the-DHCP-server-IP-when-REBOOTING.patch b/packages/network/connman/patches/connman-07_gdhcp-Save-the-DHCP-server-IP-when-REBOOTING.patch deleted file mode 100644 index bd779293f7..0000000000 --- a/packages/network/connman/patches/connman-07_gdhcp-Save-the-DHCP-server-IP-when-REBOOTING.patch +++ /dev/null @@ -1,32 +0,0 @@ -From 8068601eeddef150e0323bc9094a6c54a36ac45b Mon Sep 17 00:00:00 2001 -From: Justin Maggard -Date: Mon, 14 Jul 2014 10:27:47 -0700 -Subject: [PATCH] gdhcp: Save the DHCP server IP when REBOOTING - -We need to save the server IP when REBOOTING as well as SELECTING. -Without this, DHCP renew will never work, because we don't know where -to send the unicast renew packets. ---- - gdhcp/client.c | 6 ++++++ - 1 file changed, 6 insertions(+) - -diff --git a/gdhcp/client.c b/gdhcp/client.c -index 2b7202a..47ce2e8 100644 ---- a/gdhcp/client.c -+++ b/gdhcp/client.c -@@ -2366,6 +2366,12 @@ static gboolean listener_event(GIOChannel *channel, GIOCondition condition, - g_free(dhcp_client->assigned_ip); - dhcp_client->assigned_ip = get_ip(packet.yiaddr); - -+ if (dhcp_client->state == REBOOTING) { -+ option = dhcp_get_option(&packet, -+ DHCP_SERVER_ID); -+ dhcp_client->server_ip = get_be32(option); -+ } -+ - /* Address should be set up here */ - if (dhcp_client->lease_available_cb) - dhcp_client->lease_available_cb(dhcp_client, --- -2.1.0 - diff --git a/packages/network/connman/patches/connman-08_gdhcp-adjust-discovery-request-timeout-and-retry-val.patch b/packages/network/connman/patches/connman-08_gdhcp-adjust-discovery-request-timeout-and-retry-val.patch deleted file mode 100644 index ad20f19df6..0000000000 --- a/packages/network/connman/patches/connman-08_gdhcp-adjust-discovery-request-timeout-and-retry-val.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 7279ad0d48c367acfbeae325bf4290057fa0a09c Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Pasi=20Sj=C3=B6holm?= -Date: Wed, 16 Jul 2014 22:30:34 +0300 -Subject: [PATCH] gdhcp: adjust discovery/request timeout and retry values - -Some dhcp servers are acting lazy (eg. Buffalo WBMR-G125) -therefore 3 second timeout value for discovery or request -is not enough. Adjusting the timeout value from 3 seconds -to 5 will fix the problem together with adjusting the -retry value not to increase the total time for waiting -for getting the lease. ---- - gdhcp/client.c | 8 ++++---- - 1 file changed, 4 insertions(+), 4 deletions(-) - -diff --git a/gdhcp/client.c b/gdhcp/client.c -index 47ce2e8..7b47ad2 100644 ---- a/gdhcp/client.c -+++ b/gdhcp/client.c -@@ -47,11 +47,11 @@ - #include "common.h" - #include "ipv4ll.h" - --#define DISCOVER_TIMEOUT 3 --#define DISCOVER_RETRIES 10 -+#define DISCOVER_TIMEOUT 5 -+#define DISCOVER_RETRIES 6 - --#define REQUEST_TIMEOUT 3 --#define REQUEST_RETRIES 5 -+#define REQUEST_TIMEOUT 5 -+#define REQUEST_RETRIES 3 - - typedef enum _listen_mode { - L_NONE, --- -2.1.0 - diff --git a/packages/network/connman/patches/connman-09_gdhcp-Request-an-actual-IP-address-when-rebinding.patch b/packages/network/connman/patches/connman-09_gdhcp-Request-an-actual-IP-address-when-rebinding.patch deleted file mode 100644 index 9ceb50c86e..0000000000 --- a/packages/network/connman/patches/connman-09_gdhcp-Request-an-actual-IP-address-when-rebinding.patch +++ /dev/null @@ -1,35 +0,0 @@ -From e4d54a59f6db20a79181e1666a28d292b07a4652 Mon Sep 17 00:00:00 2001 -From: Justin Maggard -Date: Wed, 16 Jul 2014 11:12:12 -0700 -Subject: [PATCH] gdhcp: Request an actual IP address when rebinding - -We need to specify a requested IP address when our DHCP client state -is REBINDING as well as REQUESTING and REBOOTING; or else we end up -sending a DHCP request for 0.0.0.0, which generally just gets ignored. ---- - gdhcp/client.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/gdhcp/client.c b/gdhcp/client.c -index 7b47ad2..45922f1 100644 ---- a/gdhcp/client.c -+++ b/gdhcp/client.c -@@ -484,13 +484,13 @@ static int send_request(GDHCPClient *dhcp_client) - - add_send_options(dhcp_client, &packet); - -- if (dhcp_client->state == RENEWING) { -+ if (dhcp_client->state == RENEWING || dhcp_client->state == REBINDING) - packet.ciaddr = htonl(dhcp_client->requested_ip); - -+ if (dhcp_client->state == RENEWING) - return dhcp_send_kernel_packet(&packet, - dhcp_client->requested_ip, CLIENT_PORT, - dhcp_client->server_ip, SERVER_PORT); -- } - - return dhcp_send_raw_packet(&packet, INADDR_ANY, CLIENT_PORT, - INADDR_BROADCAST, SERVER_PORT, --- -2.1.0 - diff --git a/packages/network/connman/patches/connman-10_dhcp-Fix-further-crashes-when-connected-to-network-w.patch b/packages/network/connman/patches/connman-10_dhcp-Fix-further-crashes-when-connected-to-network-w.patch deleted file mode 100644 index f83be4f315..0000000000 --- a/packages/network/connman/patches/connman-10_dhcp-Fix-further-crashes-when-connected-to-network-w.patch +++ /dev/null @@ -1,90 +0,0 @@ -From 88c490b3a743dcfdc0dc071b7a7055f1468719f5 Mon Sep 17 00:00:00 2001 -From: Alexandru Costache -Date: Wed, 2 Jul 2014 09:23:38 -0400 -Subject: [PATCH] dhcp: Fix further crashes when connected to network without - dhcp - -There are several crashing conditions in dhcp_retry_cb() and in -ipv4ll_available_cb(), when service is NULL or dhcp->network is -either NULL or has been freed. Fixed all by removing timeout and -ipv4ll callback when invalidating dhcp. ---- - src/dhcp.c | 40 +++++++++++++++++++++++++--------------- - 1 file changed, 25 insertions(+), 15 deletions(-) - -diff --git a/src/dhcp.c b/src/dhcp.c -index e4bac67..70a7d96 100644 ---- a/src/dhcp.c -+++ b/src/dhcp.c -@@ -70,6 +70,20 @@ static void dhcp_free(struct connman_dhcp *dhcp) - g_free(dhcp); - } - -+static void ipv4ll_stop_client(struct connman_dhcp *dhcp) -+{ -+ if (!dhcp->ipv4ll_client) -+ return; -+ -+ g_dhcp_client_stop(dhcp->ipv4ll_client); -+ g_dhcp_client_unref(dhcp->ipv4ll_client); -+ dhcp->ipv4ll_client = NULL; -+ ipv4ll_running = false; -+ -+ g_free(dhcp->ipv4ll_debug_prefix); -+ dhcp->ipv4ll_debug_prefix = NULL; -+} -+ - /** - * dhcp_invalidate: Invalidate an existing DHCP lease - * @dhcp: pointer to the DHCP lease to invalidate. -@@ -132,6 +146,14 @@ static void dhcp_invalidate(struct connman_dhcp *dhcp, bool callback) - __connman_ipconfig_set_gateway(ipconfig, NULL); - __connman_ipconfig_set_prefixlen(ipconfig, 0); - -+ if (dhcp->timeout > 0) { -+ g_source_remove(dhcp->timeout); -+ dhcp->timeout = 0; -+ } -+ -+ if (ipv4ll_running) -+ ipv4ll_stop_client(dhcp); -+ - if (dhcp->callback && callback) { - g_hash_table_remove(network_table, dhcp->network); - network_removed = true; -@@ -157,20 +179,6 @@ static void dhcp_debug(const char *str, void *data) - connman_info("%s: %s", (const char *) data, str); - } - --static void ipv4ll_stop_client(struct connman_dhcp *dhcp) --{ -- if (!dhcp->ipv4ll_client) -- return; -- -- g_dhcp_client_stop(dhcp->ipv4ll_client); -- g_dhcp_client_unref(dhcp->ipv4ll_client); -- dhcp->ipv4ll_client = NULL; -- ipv4ll_running = false; -- -- g_free(dhcp->ipv4ll_debug_prefix); -- dhcp->ipv4ll_debug_prefix = NULL; --} -- - static void ipv4ll_lost_cb(GDHCPClient *dhcp_client, gpointer user_data); - static void ipv4ll_available_cb(GDHCPClient *ipv4ll_client, gpointer user_data); - -@@ -574,8 +582,10 @@ static int dhcp_release(struct connman_dhcp *dhcp) - { - DBG("dhcp %p", dhcp); - -- if (dhcp->timeout > 0) -+ if (dhcp->timeout > 0) { - g_source_remove(dhcp->timeout); -+ dhcp->timeout = 0; -+ } - - if (dhcp->dhcp_client) { - g_dhcp_client_stop(dhcp->dhcp_client); --- -1.7.10.4 -