Merge ~awe/network-manager/+git/ubuntu:touch-vivid2 into network-manager:touch-vivid
- Git
- lp:~awe/network-manager/+git/ubuntu
- touch-vivid2
- Merge into touch-vivid
Proposed by
Tony Espy
Status: | Merged |
---|---|
Approved by: | Mathieu Trudel-Lapierre |
Approved revision: | 418ce9b8e301bd50592edade23d7ff062cdb4412 |
Merged at revision: | 832d695d64c3d9fe37fd410e80da0723dc43b0e9 |
Proposed branch: | ~awe/network-manager/+git/ubuntu:touch-vivid2 |
Merge into: | network-manager:touch-vivid |
Diff against target: |
1538 lines (+832/-167) 24 files modified
debian/changelog (+22/-0) debian/control (+19/-1) debian/default-wifi-powersave-on.conf (+2/-0) debian/indicator-network.pkla (+6/-0) debian/libnm-dev.install (+1/-1) debian/network-manager.install (+1/-1) debian/patches/Add-modem-reconnect-delay-to-policy.patch (+115/-0) debian/patches/Add-new-NMSettingsConnection-reset_retries-get-set-m.patch (+1/-1) debian/patches/Add-sudo-policy-to-DBus-conf-for-indicator-network.patch (+32/-0) debian/patches/Clear-WiFi-requested_scan-if-suppl-exits.patch (+38/-0) debian/patches/Clear-WiFi-requested_scan-if-suppl-goes-INACTIVE.patch (+37/-0) debian/patches/Filter-DNS-servers-to-add-to-dnsmasq-based-on-availa.patch (+1/-0) debian/patches/Fix-openvpn-by-handling-do_add_route-EEXISTS.patch (+32/-0) debian/patches/Ignore-p2p-wifi-devices-from-android.patch (+34/-0) debian/patches/Ignore-rild-modem-devices.patch (+27/-0) debian/patches/Modify-NMDeviceModem-s-available-logic.patch (+4/-4) debian/patches/Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch (+2/-0) debian/patches/Track-killswitch-change-signals-from-urfkill.patch (+4/-4) debian/patches/Update-dnsmasq-parameters.patch (+1/-1) debian/patches/series (+8/-3) debian/patches/wwan-add-support-for-using-oFono-as-a-modem-manager.patch (+74/-89) debian/patches/wwan-fix-ofono-connection-problems.patch (+343/-0) debian/rules (+28/-11) dev/null (+0/-51) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Simon Fels | Approve | ||
Review via email: mp+296476@code.launchpad.net |
Commit message
Description of the change
This merge proposal is a backport of the stable 1.2.2 version of NetworkManager from yakkety to Touch, intended for the Touch overlay PPA.
Changes include ( besides switching to git ):
- Dropping default WiFi powersave patch and installing a config file to do the same
- Syncing the Touch NMManager device patches
- Syncing the Touch WWAN patches
- Adding a few Touch wpa_supplicant & platform patches
- Restoring bug headers in some of the patches
- Disabling ppp and gir in the build, due to build errors on vivid. This should have no impact on our images, and will be fixed when we move to xenial.
- Adding a final patch to deal with ofono connection edge cases, and a mobile-data re-connect hang.
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | diff --git a/debian/changelog b/debian/changelog | |||
2 | index 893a649..813c545 100644 | |||
3 | --- a/debian/changelog | |||
4 | +++ b/debian/changelog | |||
5 | @@ -1,3 +1,25 @@ | |||
6 | 1 | network-manager (1.2.2-0ubuntu1~vivid1) UNRELEASED; urgency=medium | ||
7 | 2 | |||
8 | 3 | * Backported to vivid for Ubuntu Touch: | ||
9 | 4 | - Added d/indicator-network.pkla: policy kit config | ||
10 | 5 | - Modified d/rules: disable bluez, gir*, ppp, systemd-journal, | ||
11 | 6 | and install indicator-network polkit config. | ||
12 | 7 | - Modified d/control: adjusted ppp-dev version, and restored | ||
13 | 8 | -dbg package | ||
14 | 9 | - Modified install files for temporary gir & ppp changes | ||
15 | 10 | - Re-sync d/p/Ignore* nm-manager device patches from Touch | ||
16 | 11 | - Re-synced d/p/wwan-add-support* patch from Touch | ||
17 | 12 | - Re-stored patches from Touch: | ||
18 | 13 | - Add-modem-reconnect-delay* (LP: #1461593) | ||
19 | 14 | - indicator-network DBus 'sudo' policy | ||
20 | 15 | - wpa_suppl scan fixes | ||
21 | 16 | - OpenVPN EEXISTS bug (LP: #1579222) | ||
22 | 17 | - Removed d/p/Set-the-default-powersave*.patch, and instead install | ||
23 | 18 | a config file that accomplishes the same (LP: #1557026). | ||
24 | 19 | - Add d/p/wwan-fix-ofono-connection-problems (LP: #1565717, #1579098). | ||
25 | 20 | |||
26 | 21 | -- Tony Espy <espy@canonical.com> Tue, 24 May 2016 15:30:42 -0400 | ||
27 | 22 | |||
28 | 1 | network-manager (1.2.2-0ubuntu1) yakkety; urgency=medium | 23 | network-manager (1.2.2-0ubuntu1) yakkety; urgency=medium |
29 | 2 | 24 | ||
30 | 3 | * Rebase to upstream stable point release. (LP: #1574347) | 25 | * Rebase to upstream stable point release. (LP: #1574347) |
31 | diff --git a/debian/control b/debian/control | |||
32 | index 354dfd7..e8429c0 100644 | |||
33 | --- a/debian/control | |||
34 | +++ b/debian/control | |||
35 | @@ -16,7 +16,7 @@ Build-Depends: debhelper (>= 9), | |||
36 | 16 | libnl-3-dev (>= 3.2.8), | 16 | libnl-3-dev (>= 3.2.8), |
37 | 17 | libnl-route-3-dev (>= 3.2.8), | 17 | libnl-route-3-dev (>= 3.2.8), |
38 | 18 | libnl-genl-3-dev (>= 3.2.8), | 18 | libnl-genl-3-dev (>= 3.2.8), |
40 | 19 | ppp-dev (>= 2.4.7-1+1), | 19 | ppp-dev (>= 2.4.6), |
41 | 20 | libpolkit-gobject-1-dev, | 20 | libpolkit-gobject-1-dev, |
42 | 21 | libpolkit-agent-1-dev (>= 0.97), | 21 | libpolkit-agent-1-dev (>= 0.97), |
43 | 22 | libgnutls-dev, | 22 | libgnutls-dev, |
44 | @@ -248,6 +248,24 @@ Description: GObject-based client library for NetworkManager (development files) | |||
45 | 248 | . | 248 | . |
46 | 249 | This package contains header and development files. | 249 | This package contains header and development files. |
47 | 250 | 250 | ||
48 | 251 | Package: network-manager-dbg | ||
49 | 252 | Architecture: linux-any | ||
50 | 253 | Section: debug | ||
51 | 254 | Priority: extra | ||
52 | 255 | Depends: ${misc:Depends}, | ||
53 | 256 | network-manager (= ${binary:Version}), | ||
54 | 257 | libnm-util2 (= ${binary:Version}), | ||
55 | 258 | libnm-glib4 (= ${binary:Version}), | ||
56 | 259 | libnm-glib-vpn1 (= ${binary:Version}) | ||
57 | 260 | Description: network management framework (debugging symbols) | ||
58 | 261 | NetworkManager is a system network service that manages your network devices | ||
59 | 262 | and connections, attempting to keep active network connectivity when | ||
60 | 263 | available. It manages ethernet, WiFi, mobile broadband (WWAN), and PPPoE | ||
61 | 264 | devices, and provides VPN integration with a variety of different VPN | ||
62 | 265 | services. | ||
63 | 266 | . | ||
64 | 267 | This package contains detached debugging symbols. | ||
65 | 268 | |||
66 | 251 | Package: gir1.2-networkmanager-1.0 | 269 | Package: gir1.2-networkmanager-1.0 |
67 | 252 | Section: introspection | 270 | Section: introspection |
68 | 253 | Architecture: linux-any | 271 | Architecture: linux-any |
69 | diff --git a/debian/default-wifi-powersave-on.conf b/debian/default-wifi-powersave-on.conf | |||
70 | 254 | new file mode 100644 | 272 | new file mode 100644 |
71 | index 0000000..0580544 | |||
72 | --- /dev/null | |||
73 | +++ b/debian/default-wifi-powersave-on.conf | |||
74 | @@ -0,0 +1,2 @@ | |||
75 | 1 | [connection] | ||
76 | 2 | wifi.powersave = 3 | ||
77 | 0 | \ No newline at end of file | 3 | \ No newline at end of file |
78 | diff --git a/debian/indicator-network.pkla b/debian/indicator-network.pkla | |||
79 | 1 | new file mode 100644 | 4 | new file mode 100644 |
80 | index 0000000..4e64cae | |||
81 | --- /dev/null | |||
82 | +++ b/debian/indicator-network.pkla | |||
83 | @@ -0,0 +1,6 @@ | |||
84 | 1 | [indicator-network-service] | ||
85 | 2 | Identity=unix-group:sudo | ||
86 | 3 | Action=org.freedesktop.NetworkManager.* | ||
87 | 4 | ResultAny=yes | ||
88 | 5 | ResultInactive=no | ||
89 | 6 | ResultActive=yes | ||
90 | diff --git a/debian/libnm-dev.install b/debian/libnm-dev.install | |||
91 | index 4dddc86..58dd896 100644 | |||
92 | --- a/debian/libnm-dev.install | |||
93 | +++ b/debian/libnm-dev.install | |||
94 | @@ -2,4 +2,4 @@ usr/lib/*/pkgconfig/libnm.pc | |||
95 | 2 | usr/lib/*/libnm.so | 2 | usr/lib/*/libnm.so |
96 | 3 | usr/include/libnm/ | 3 | usr/include/libnm/ |
97 | 4 | usr/share/gtk-doc/html/libnm/ | 4 | usr/share/gtk-doc/html/libnm/ |
99 | 5 | usr/share/gir-1.0/NM-1.0.gir | 5 | #usr/share/gir-1.0/NM-1.0.gir |
100 | diff --git a/debian/network-manager.install b/debian/network-manager.install | |||
101 | index c1012ff..950b918 100644 | |||
102 | --- a/debian/network-manager.install | |||
103 | +++ b/debian/network-manager.install | |||
104 | @@ -10,7 +10,7 @@ usr/lib/*/NetworkManager/libnm-settings-plugin-ibft.so | |||
105 | 10 | usr/lib/*/NetworkManager/libnm-settings-plugin-ofono.so | 10 | usr/lib/*/NetworkManager/libnm-settings-plugin-ofono.so |
106 | 11 | usr/lib/*/NetworkManager/libnm-device-plugin-*.so | 11 | usr/lib/*/NetworkManager/libnm-device-plugin-*.so |
107 | 12 | usr/lib/*/NetworkManager/libnm-wwan.so | 12 | usr/lib/*/NetworkManager/libnm-wwan.so |
109 | 13 | usr/lib/pppd/*/*.so | 13 | #usr/lib/pppd/*/*.so |
110 | 14 | usr/share/doc/NetworkManager/examples/ | 14 | usr/share/doc/NetworkManager/examples/ |
111 | 15 | usr/share/locale/ | 15 | usr/share/locale/ |
112 | 16 | usr/share/man/ | 16 | usr/share/man/ |
113 | diff --git a/debian/patches/Add-modem-reconnect-delay-to-policy.patch b/debian/patches/Add-modem-reconnect-delay-to-policy.patch | |||
114 | 17 | new file mode 100644 | 17 | new file mode 100644 |
115 | index 0000000..5bdb503 | |||
116 | --- /dev/null | |||
117 | +++ b/debian/patches/Add-modem-reconnect-delay-to-policy.patch | |||
118 | @@ -0,0 +1,115 @@ | |||
119 | 1 | From: Tony Espy <espy@canonical.com> | ||
120 | 2 | Date: Tue, 24 May 2016 20:59:42 -0400 | ||
121 | 3 | Subject: Add modem reconnect delay to policy | ||
122 | 4 | |||
123 | 5 | This patch introduces a 5s delay between retry activations | ||
124 | 6 | for modem devices. Otherwise, the activation attempts can | ||
125 | 7 | flood the modem all at once, and then trigger the reset_retries | ||
126 | 8 | timeout ( which defaults to 300s ). | ||
127 | 9 | |||
128 | 10 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1461593 | ||
129 | 11 | --- | ||
130 | 12 | src/nm-policy.c | 34 +++++++++++++++++++++++++++------- | ||
131 | 13 | 1 file changed, 27 insertions(+), 7 deletions(-) | ||
132 | 14 | |||
133 | 15 | diff --git a/src/nm-policy.c b/src/nm-policy.c | ||
134 | 16 | index 07bcce8..5c59604 100644 | ||
135 | 17 | --- a/src/nm-policy.c | ||
136 | 18 | +++ b/src/nm-policy.c | ||
137 | 19 | @@ -931,7 +931,7 @@ sleeping_changed (NMManager *manager, GParamSpec *pspec, gpointer user_data) | ||
138 | 20 | } | ||
139 | 21 | |||
140 | 22 | static void | ||
141 | 23 | -schedule_activate_check (NMPolicy *self, NMDevice *device) | ||
142 | 24 | +schedule_activate_check (NMPolicy *self, NMDevice *device, guint delay) | ||
143 | 25 | { | ||
144 | 26 | NMPolicyPrivate *priv = NM_POLICY_GET_PRIVATE (self); | ||
145 | 27 | ActivateData *data; | ||
146 | 28 | @@ -960,7 +960,12 @@ schedule_activate_check (NMPolicy *self, NMDevice *device) | ||
147 | 29 | data = g_slice_new0 (ActivateData); | ||
148 | 30 | data->policy = self; | ||
149 | 31 | data->device = g_object_ref (device); | ||
150 | 32 | - data->autoactivate_id = g_idle_add (auto_activate_device, data); | ||
151 | 33 | + | ||
152 | 34 | + if (delay) | ||
153 | 35 | + data->autoactivate_id = g_timeout_add_seconds (delay, auto_activate_device, data); | ||
154 | 36 | + else | ||
155 | 37 | + data->autoactivate_id = g_idle_add (auto_activate_device, data); | ||
156 | 38 | + | ||
157 | 39 | priv->pending_activation_checks = g_slist_append (priv->pending_activation_checks, data); | ||
158 | 40 | } | ||
159 | 41 | |||
160 | 42 | @@ -1155,6 +1160,7 @@ device_state_changed (NMDevice *device, | ||
161 | 43 | NMIP4Config *ip4_config; | ||
162 | 44 | NMIP6Config *ip6_config; | ||
163 | 45 | NMSettingConnection *s_con = NULL; | ||
164 | 46 | + guint delay = 0; | ||
165 | 47 | |||
166 | 48 | switch (new_state) { | ||
167 | 49 | case NM_DEVICE_STATE_FAILED: | ||
168 | 50 | @@ -1172,7 +1178,7 @@ device_state_changed (NMDevice *device, | ||
169 | 51 | |||
170 | 52 | nm_settings_connection_set_autoconnect_blocked_reason (connection, NM_DEVICE_STATE_REASON_NO_SECRETS); | ||
171 | 53 | } else if (tries > 0) { | ||
172 | 54 | - _LOGD (LOGD_DEVICE, "connection '%s' failed to autoconnect; %d tries left", | ||
173 | 55 | + _LOGI (LOGD_DEVICE, "connection '%s' failed to autoconnect; %d tries left", | ||
174 | 56 | nm_settings_connection_get_id (connection), tries); | ||
175 | 57 | nm_settings_connection_set_autoconnect_retries (connection, tries - 1); | ||
176 | 58 | } | ||
177 | 59 | @@ -1183,6 +1189,10 @@ device_state_changed (NMDevice *device, | ||
178 | 60 | /* Schedule a handler to reset retries count */ | ||
179 | 61 | if (!priv->reset_retries_id) { | ||
180 | 62 | gint32 retry_time = nm_settings_connection_get_autoconnect_retry_time (connection); | ||
181 | 63 | + gint32 actual_time = MAX (0, retry_time - nm_utils_get_monotonic_timestamp_s ()); | ||
182 | 64 | + | ||
183 | 65 | + _LOGI (LOGD_DEVICE, "Disabling autoconnect for connection '%s'; setting retry of %d.", | ||
184 | 66 | + nm_connection_get_id (NM_CONNECTION (connection)), actual_time); | ||
185 | 67 | |||
186 | 68 | g_warn_if_fail (retry_time != 0); | ||
187 | 69 | priv->reset_retries_id = g_timeout_add_seconds (MAX (0, retry_time - nm_utils_get_monotonic_timestamp_s ()), reset_connections_retries, self); | ||
188 | 70 | @@ -1250,7 +1260,17 @@ device_state_changed (NMDevice *device, | ||
189 | 71 | update_routing_and_dns (self, FALSE); | ||
190 | 72 | |||
191 | 73 | /* Device is now available for auto-activation */ | ||
192 | 74 | - schedule_activate_check (self, device); | ||
193 | 75 | + if (nm_device_get_device_type (device) == NM_DEVICE_TYPE_MODEM) | ||
194 | 76 | + delay = 5; | ||
195 | 77 | + | ||
196 | 78 | + if (connection) | ||
197 | 79 | + _LOGI (LOGD_DEVICE, "Connection '%s' disconnected, scheduling activate_check in %u seconds.", | ||
198 | 80 | + nm_connection_get_id (NM_CONNECTION (connection)), delay); | ||
199 | 81 | + else | ||
200 | 82 | + _LOGI (LOGD_DEVICE, "Device '%s' has no connection; scheduling activate_check in %u seconds.", | ||
201 | 83 | + nm_device_get_iface (device), delay); | ||
202 | 84 | + | ||
203 | 85 | + schedule_activate_check (self, device, delay); | ||
204 | 86 | break; | ||
205 | 87 | |||
206 | 88 | case NM_DEVICE_STATE_PREPARE: | ||
207 | 89 | @@ -1363,7 +1383,7 @@ device_autoconnect_changed (NMDevice *device, | ||
208 | 90 | NMPolicy *self = priv->self; | ||
209 | 91 | |||
210 | 92 | if (nm_device_autoconnect_allowed (device)) | ||
211 | 93 | - schedule_activate_check (self, device); | ||
212 | 94 | + schedule_activate_check (self, device, 0); | ||
213 | 95 | } | ||
214 | 96 | |||
215 | 97 | static void | ||
216 | 98 | @@ -1372,7 +1392,7 @@ device_recheck_auto_activate (NMDevice *device, gpointer user_data) | ||
217 | 99 | NMPolicyPrivate *priv = user_data; | ||
218 | 100 | NMPolicy *self = priv->self; | ||
219 | 101 | |||
220 | 102 | - schedule_activate_check (self, device); | ||
221 | 103 | + schedule_activate_check (self, device, 0); | ||
222 | 104 | } | ||
223 | 105 | |||
224 | 106 | static void | ||
225 | 107 | @@ -1586,7 +1606,7 @@ schedule_activate_all (NMPolicy *self) | ||
226 | 108 | const GSList *iter; | ||
227 | 109 | |||
228 | 110 | for (iter = nm_manager_get_devices (priv->manager); iter; iter = g_slist_next (iter)) | ||
229 | 111 | - schedule_activate_check (self, NM_DEVICE (iter->data)); | ||
230 | 112 | + schedule_activate_check (self, NM_DEVICE (iter->data), 0); | ||
231 | 113 | } | ||
232 | 114 | |||
233 | 115 | static void | ||
234 | diff --git a/debian/patches/Add-new-NMSettingsConnection-reset_retries-get-set-m.patch b/debian/patches/Add-new-NMSettingsConnection-reset_retries-get-set-m.patch | |||
235 | index 3fc4826..a10ac51 100644 | |||
236 | --- a/debian/patches/Add-new-NMSettingsConnection-reset_retries-get-set-m.patch | |||
237 | +++ b/debian/patches/Add-new-NMSettingsConnection-reset_retries-get-set-m.patch | |||
238 | @@ -6,7 +6,7 @@ This patch adds get/set methods to NMSettingsConnection for the | |||
239 | 6 | reset_retries_timeout. This allows sub-classes to override the | 6 | reset_retries_timeout. This allows sub-classes to override the |
240 | 7 | default setting ( 300s ). | 7 | default setting ( 300s ). |
241 | 8 | 8 | ||
243 | 9 | Bug: https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/1461593 | 9 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1461593 |
244 | 10 | --- | 10 | --- |
245 | 11 | src/settings/nm-settings-connection.c | 18 +++++++++++++++++- | 11 | src/settings/nm-settings-connection.c | 18 +++++++++++++++++- |
246 | 12 | src/settings/nm-settings-connection.h | 3 +++ | 12 | src/settings/nm-settings-connection.h | 3 +++ |
247 | diff --git a/debian/patches/Add-sudo-policy-to-DBus-conf-for-indicator-network.patch b/debian/patches/Add-sudo-policy-to-DBus-conf-for-indicator-network.patch | |||
248 | 13 | new file mode 100644 | 13 | new file mode 100644 |
249 | index 0000000..814de4b | |||
250 | --- /dev/null | |||
251 | +++ b/debian/patches/Add-sudo-policy-to-DBus-conf-for-indicator-network.patch | |||
252 | @@ -0,0 +1,32 @@ | |||
253 | 1 | From: Tony Espy <espy@canonical.com> | ||
254 | 2 | Date: Tue, 24 May 2016 21:19:06 -0400 | ||
255 | 3 | Subject: Add sudo policy to DBus conf for indicator-network | ||
256 | 4 | |||
257 | 5 | This patch adds a 'sudo' group DBus policy to allow | ||
258 | 6 | indicator-network to interact with the NetworkManager and | ||
259 | 7 | NetworkManager.SecretAgent interfaces. | ||
260 | 8 | |||
261 | 9 | This was previously handled by a dirty hack/hook in the | ||
262 | 10 | livecd-rootfs tool used to build touch images. | ||
263 | 11 | |||
264 | 12 | --- | ||
265 | 13 | src/org.freedesktop.NetworkManager.conf | 5 +++++ | ||
266 | 14 | 1 file changed, 5 insertions(+) | ||
267 | 15 | |||
268 | 16 | diff --git a/src/org.freedesktop.NetworkManager.conf b/src/org.freedesktop.NetworkManager.conf | ||
269 | 17 | index 35ed4e7..58e6c7f 100644 | ||
270 | 18 | --- a/src/org.freedesktop.NetworkManager.conf | ||
271 | 19 | +++ b/src/org.freedesktop.NetworkManager.conf | ||
272 | 20 | @@ -2,6 +2,12 @@ | ||
273 | 21 | "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN" | ||
274 | 22 | "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd"> | ||
275 | 23 | <busconfig> | ||
276 | 24 | + <policy group="sudo"> | ||
277 | 25 | + <allow send_destination="org.freedesktop.NetworkManager" | ||
278 | 26 | + send_interface="org.freedesktop.NetworkManager"/> | ||
279 | 27 | + <allow send_destination="org.freedesktop.NetworkManager" | ||
280 | 28 | + send_interface="org.freedesktop.NetworkManager.SecretAgent"/> | ||
281 | 29 | + </policy> | ||
282 | 30 | <policy user="root"> | ||
283 | 31 | <allow own="org.freedesktop.NetworkManager"/> | ||
284 | 32 | <allow send_destination="org.freedesktop.NetworkManager"/> | ||
285 | diff --git a/debian/patches/Clear-WiFi-requested_scan-if-suppl-exits.patch b/debian/patches/Clear-WiFi-requested_scan-if-suppl-exits.patch | |||
286 | 0 | new file mode 100644 | 33 | new file mode 100644 |
287 | index 0000000..88f9891 | |||
288 | --- /dev/null | |||
289 | +++ b/debian/patches/Clear-WiFi-requested_scan-if-suppl-exits.patch | |||
290 | @@ -0,0 +1,38 @@ | |||
291 | 1 | From: Tony Espy <espy@canonical.com> | ||
292 | 2 | Date: Tue, 24 May 2016 21:36:20 -0400 | ||
293 | 3 | Subject: Clear WiFi requested_scan if suppl exits | ||
294 | 4 | |||
295 | 5 | It's possible for wpa_supplicant to exit with an | ||
296 | 6 | outstanding requested_scan pending. This can lead | ||
297 | 7 | to a stall condition where scanning no longer occurs. | ||
298 | 8 | --- | ||
299 | 9 | src/devices/wifi/nm-device-wifi.c | 9 ++++++++- | ||
300 | 10 | 1 file changed, 8 insertions(+), 1 deletion(-) | ||
301 | 11 | |||
302 | 12 | diff --git a/src/devices/wifi/nm-device-wifi.c b/src/devices/wifi/nm-device-wifi.c | ||
303 | 13 | index f6325a6..b147409 100644 | ||
304 | 14 | --- a/src/devices/wifi/nm-device-wifi.c | ||
305 | 15 | +++ b/src/devices/wifi/nm-device-wifi.c | ||
306 | 16 | @@ -246,6 +246,13 @@ supplicant_interface_release (NMDeviceWifi *self) | ||
307 | 17 | |||
308 | 18 | priv = NM_DEVICE_WIFI_GET_PRIVATE (self); | ||
309 | 19 | |||
310 | 20 | + if (priv->requested_scan) { | ||
311 | 21 | + nm_log_dbg (LOGD_WIFI_SCAN, "(%s): reset requested_scan flag to FALSE", | ||
312 | 22 | + nm_device_get_iface (NM_DEVICE (self))); | ||
313 | 23 | + priv->requested_scan = FALSE; | ||
314 | 24 | + nm_device_remove_pending_action (NM_DEVICE (self), "scan", TRUE); | ||
315 | 25 | + } | ||
316 | 26 | + | ||
317 | 27 | nm_clear_g_source (&priv->pending_scan_id); | ||
318 | 28 | |||
319 | 29 | /* Reset the scan interval to be pretty frequent when disconnected */ | ||
320 | 30 | @@ -1915,7 +1922,7 @@ supplicant_iface_state_cb (NMSupplicantInterface *iface, | ||
321 | 31 | priv->requested_scan = FALSE; | ||
322 | 32 | } | ||
323 | 33 | |||
324 | 34 | - cancel_pending_scan (self); | ||
325 | 35 | + nm_clear_g_source (&priv->pending_scan_id); | ||
326 | 36 | request_wireless_scan (self, NULL); | ||
327 | 37 | } | ||
328 | 38 | default: | ||
329 | diff --git a/debian/patches/Clear-WiFi-requested_scan-if-suppl-goes-INACTIVE.patch b/debian/patches/Clear-WiFi-requested_scan-if-suppl-goes-INACTIVE.patch | |||
330 | 0 | new file mode 100644 | 39 | new file mode 100644 |
331 | index 0000000..d81b534 | |||
332 | --- /dev/null | |||
333 | +++ b/debian/patches/Clear-WiFi-requested_scan-if-suppl-goes-INACTIVE.patch | |||
334 | @@ -0,0 +1,37 @@ | |||
335 | 1 | From: Tony Espy <espy@canonical.com> | ||
336 | 2 | Date: Tue, 24 May 2016 21:22:48 -0400 | ||
337 | 3 | Subject: Clear WiFi requested_scan if suppl goes INACTIVE | ||
338 | 4 | |||
339 | 5 | It's possible for wpa_supplicant to transition to INACTIVE | ||
340 | 6 | state with an outstanding requested_scan pending. This can | ||
341 | 7 | lead to a stall condition where scanning no longer occurs. | ||
342 | 8 | --- | ||
343 | 9 | src/devices/wifi/nm-device-wifi.c | 15 +++++++++++++++ | ||
344 | 10 | 1 file changed, 15 insertions(+) | ||
345 | 11 | |||
346 | 12 | diff --git a/src/devices/wifi/nm-device-wifi.c b/src/devices/wifi/nm-device-wifi.c | ||
347 | 13 | index bacd5e6..f6325a6 100644 | ||
348 | 14 | --- a/src/devices/wifi/nm-device-wifi.c | ||
349 | 15 | +++ b/src/devices/wifi/nm-device-wifi.c | ||
350 | 16 | @@ -1903,6 +1903,21 @@ supplicant_iface_state_cb (NMSupplicantInterface *iface, | ||
351 | 17 | else | ||
352 | 18 | _LOGI (LOGD_DEVICE | LOGD_WIFI, "supplicant interface keeps failing, giving up"); | ||
353 | 19 | break; | ||
354 | 20 | + case NM_SUPPLICANT_INTERFACE_STATE_INACTIVE: | ||
355 | 21 | + if (old_state == NM_SUPPLICANT_INTERFACE_STATE_SCANNING) { | ||
356 | 22 | + nm_log_warn (LOGD_HW | LOGD_WIFI, "(%s): supplicant state: SCANNING -> INACTIVE", | ||
357 | 23 | + nm_device_get_iface (NM_DEVICE (self))); | ||
358 | 24 | + | ||
359 | 25 | + if (priv->requested_scan) { | ||
360 | 26 | + nm_log_dbg (LOGD_WIFI_SCAN, "(%s): clearing requested_scan", | ||
361 | 27 | + nm_device_get_iface (NM_DEVICE (self))); | ||
362 | 28 | + | ||
363 | 29 | + priv->requested_scan = FALSE; | ||
364 | 30 | + } | ||
365 | 31 | + | ||
366 | 32 | + cancel_pending_scan (self); | ||
367 | 33 | + request_wireless_scan (self, NULL); | ||
368 | 34 | + } | ||
369 | 35 | default: | ||
370 | 36 | break; | ||
371 | 37 | } | ||
372 | diff --git a/debian/patches/Filter-DNS-servers-to-add-to-dnsmasq-based-on-availa.patch b/debian/patches/Filter-DNS-servers-to-add-to-dnsmasq-based-on-availa.patch | |||
373 | index fae01f9..648dd6f 100644 | |||
374 | --- a/debian/patches/Filter-DNS-servers-to-add-to-dnsmasq-based-on-availa.patch | |||
375 | +++ b/debian/patches/Filter-DNS-servers-to-add-to-dnsmasq-based-on-availa.patch | |||
376 | @@ -3,6 +3,7 @@ Date: Fri, 13 May 2016 11:00:11 +0800 | |||
377 | 3 | Subject: Filter DNS servers to add to dnsmasq based on availability and VPN | 3 | Subject: Filter DNS servers to add to dnsmasq based on availability and VPN |
378 | 4 | status | 4 | status |
379 | 5 | 5 | ||
380 | 6 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/898224 | ||
381 | 6 | --- | 7 | --- |
382 | 7 | src/dns-manager/nm-dns-dnsmasq.c | 47 +++++++++++++++++++++++++++++++++------- | 8 | src/dns-manager/nm-dns-dnsmasq.c | 47 +++++++++++++++++++++++++++++++++------- |
383 | 8 | 1 file changed, 39 insertions(+), 8 deletions(-) | 9 | 1 file changed, 39 insertions(+), 8 deletions(-) |
384 | diff --git a/debian/patches/Fix-openvpn-by-handling-do_add_route-EEXISTS.patch b/debian/patches/Fix-openvpn-by-handling-do_add_route-EEXISTS.patch | |||
385 | 9 | new file mode 100644 | 10 | new file mode 100644 |
386 | index 0000000..9a538f0 | |||
387 | --- /dev/null | |||
388 | +++ b/debian/patches/Fix-openvpn-by-handling-do_add_route-EEXISTS.patch | |||
389 | @@ -0,0 +1,32 @@ | |||
390 | 1 | From: Tony Espy <espy@canonical.com> | ||
391 | 2 | Date: Tue, 24 May 2016 21:41:18 -0400 | ||
392 | 3 | Subject: Fix openvpn by handling do_add_route EEXISTS | ||
393 | 4 | |||
394 | 5 | This patch fixes issues with the updated Netlink code in | ||
395 | 6 | NMLinuxPlatform and ineroperability with older ( <= 3.10 ) | ||
396 | 7 | kernels. | ||
397 | 8 | |||
398 | 9 | Add EEXIST logic similar to logic found in 0.9.10 to the | ||
399 | 10 | NMLinuxPlatform do_add_addroute(). | ||
400 | 11 | |||
401 | 12 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1579222 | ||
402 | 13 | --- | ||
403 | 14 | src/platform/nm-linux-platform.c | 5 +++++ | ||
404 | 15 | 1 file changed, 5 insertions(+) | ||
405 | 16 | |||
406 | 17 | diff --git a/src/platform/nm-linux-platform.c b/src/platform/nm-linux-platform.c | ||
407 | 18 | index c504550..f453b6e 100644 | ||
408 | 19 | --- a/src/platform/nm-linux-platform.c | ||
409 | 20 | +++ b/src/platform/nm-linux-platform.c | ||
410 | 21 | @@ -3915,6 +3915,11 @@ do_add_addrroute (NMPlatform *platform, const NMPObject *obj_id, struct nl_msg * | ||
411 | 22 | obj = nmp_cache_lookup_obj (priv->cache, obj_id); | ||
412 | 23 | } | ||
413 | 24 | |||
414 | 25 | + if (seq_result == -EEXIST) { | ||
415 | 26 | + _LOGI ("do_add_addroute: seq_restul == -EEXISTS; treating as OK"); | ||
416 | 27 | + seq_result = WAIT_FOR_NL_RESPONSE_RESULT_RESPONSE_OK; | ||
417 | 28 | + } | ||
418 | 29 | + | ||
419 | 30 | /* Adding is only successful, if kernel reported success *and* we have the | ||
420 | 31 | * expected object in cache afterwards. */ | ||
421 | 32 | return obj && seq_result == WAIT_FOR_NL_RESPONSE_RESULT_RESPONSE_OK; | ||
422 | diff --git a/debian/patches/Ignore-p2p-wifi-devices-from-android.patch b/debian/patches/Ignore-p2p-wifi-devices-from-android.patch | |||
423 | 0 | new file mode 100644 | 33 | new file mode 100644 |
424 | index 0000000..c09e7d3 | |||
425 | --- /dev/null | |||
426 | +++ b/debian/patches/Ignore-p2p-wifi-devices-from-android.patch | |||
427 | @@ -0,0 +1,34 @@ | |||
428 | 1 | From: Tony Espy <espy@canonical.com> | ||
429 | 2 | Date: Fri, 3 Jun 2016 15:50:53 -0400 | ||
430 | 3 | Subject: Ignore p2p wifi devices from android | ||
431 | 4 | |||
432 | 5 | This patch causes NMManager to ignore any p2p WiFi | ||
433 | 6 | devices exposed by Android WiFi drivers. | ||
434 | 7 | |||
435 | 8 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1099983 | ||
436 | 9 | --- | ||
437 | 10 | src/nm-manager.c | 11 +++++++++++ | ||
438 | 11 | 1 file changed, 11 insertions(+) | ||
439 | 12 | |||
440 | 13 | diff --git a/src/nm-manager.c b/src/nm-manager.c | ||
441 | 14 | index c2ed1da..8cf70c7 100644 | ||
442 | 15 | --- a/src/nm-manager.c | ||
443 | 16 | +++ b/src/nm-manager.c | ||
444 | 17 | @@ -2097,6 +2097,17 @@ platform_link_added (NMManager *self, | ||
445 | 18 | return; | ||
446 | 19 | } | ||
447 | 20 | |||
448 | 21 | + /* | ||
449 | 22 | + * Ubuntu: Explicitly unmanage all p2p Wi-Fi devices which are | ||
450 | 23 | + * managed externally in the case of Wi-Fi Direct. | ||
451 | 24 | + */ | ||
452 | 25 | + NMDeviceType devtype = nm_device_get_device_type (device); | ||
453 | 26 | + if ((plink->type == NM_LINK_TYPE_WIFI) | ||
454 | 27 | + && g_strstr_len (plink->name, NM_STRLEN ("p2p"), "p2p")) { | ||
455 | 28 | + nm_log_info (LOGD_HW, "(%s): ignoring P2P wireless iface", plink->name); | ||
456 | 29 | + return; | ||
457 | 30 | + } | ||
458 | 31 | + | ||
459 | 32 | device = nm_device_factory_create_device (factory, plink->name, plink, NULL, &ignore, &error); | ||
460 | 33 | if (!device) { | ||
461 | 34 | if (!ignore) { | ||
462 | diff --git a/debian/patches/Ignore-p2p0-wifi-devices-from-android.patch b/debian/patches/Ignore-p2p0-wifi-devices-from-android.patch | |||
463 | 0 | deleted file mode 100644 | 35 | deleted file mode 100644 |
464 | index c567c96..0000000 | |||
465 | --- a/debian/patches/Ignore-p2p0-wifi-devices-from-android.patch | |||
466 | +++ /dev/null | |||
467 | @@ -1,29 +0,0 @@ | |||
468 | 1 | From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> | ||
469 | 2 | Date: Fri, 13 May 2016 11:08:30 +0800 | ||
470 | 3 | Subject: Ignore p2p0 wifi devices from android. | ||
471 | 4 | |||
472 | 5 | --- | ||
473 | 6 | src/nm-manager.c | 10 ++++++++++ | ||
474 | 7 | 1 file changed, 10 insertions(+) | ||
475 | 8 | |||
476 | 9 | diff --git a/src/nm-manager.c b/src/nm-manager.c | ||
477 | 10 | index 769662c..b770139 100644 | ||
478 | 11 | --- a/src/nm-manager.c | ||
479 | 12 | +++ b/src/nm-manager.c | ||
480 | 13 | @@ -2105,6 +2105,16 @@ platform_link_added (NMManager *self, | ||
481 | 14 | !strncmp (plink->name, "ccmni", NM_STRLEN ("ccmni"))) | ||
482 | 15 | return; | ||
483 | 16 | |||
484 | 17 | + /* | ||
485 | 18 | + * Ubuntu: Explicitly unmanage p2p Wi-Fi devices exposed by Android JB Wi-Fi drivers. | ||
486 | 19 | + */ | ||
487 | 20 | + NMDeviceType devtype = nm_device_get_device_type (device); | ||
488 | 21 | + if ((plink->type == NM_LINK_TYPE_WIFI) | ||
489 | 22 | + && !strncmp (plink->name, "p2p0", NM_STRLEN ("p2p0"))) { | ||
490 | 23 | + nm_log_info (LOGD_HW, "(%s): ignoring P2P wireless iface", plink->name); | ||
491 | 24 | + return; | ||
492 | 25 | + } | ||
493 | 26 | + | ||
494 | 27 | if (device == NULL) { | ||
495 | 28 | switch (plink->type) { | ||
496 | 29 | case NM_LINK_TYPE_WWAN_ETHERNET: | ||
497 | diff --git a/debian/patches/Ignore-rild-modem-devices.patch b/debian/patches/Ignore-rild-modem-devices.patch | |||
498 | 30 | new file mode 100644 | 0 | new file mode 100644 |
499 | index 0000000..c0cc6ae | |||
500 | --- /dev/null | |||
501 | +++ b/debian/patches/Ignore-rild-modem-devices.patch | |||
502 | @@ -0,0 +1,27 @@ | |||
503 | 1 | From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> | ||
504 | 2 | Date: Fri, 13 May 2016 11:08:17 +0800 | ||
505 | 3 | Subject: Ignore rild modem devices. | ||
506 | 4 | |||
507 | 5 | --- | ||
508 | 6 | src/nm-manager.c | 8 ++++++++ | ||
509 | 7 | 1 file changed, 8 insertions(+) | ||
510 | 8 | |||
511 | 9 | diff --git a/src/nm-manager.c b/src/nm-manager.c | ||
512 | 10 | index 10aa3d7..c2ed1da 100644 | ||
513 | 11 | --- a/src/nm-manager.c | ||
514 | 12 | +++ b/src/nm-manager.c | ||
515 | 13 | @@ -2089,6 +2089,14 @@ platform_link_added (NMManager *self, | ||
516 | 14 | gboolean ignore = FALSE; | ||
517 | 15 | gs_free_error GError *error = NULL; | ||
518 | 16 | |||
519 | 17 | + /* Ignore rild modem devices, which will be handled by their modem parent */ | ||
520 | 18 | + if (g_strstr_len (plink->name, NM_STRLEN ("rmnet"), "rmnet") || | ||
521 | 19 | + g_strstr_len (plink->name, NM_STRLEN ("rev_rmnet"), "rev_rmnet") || | ||
522 | 20 | + g_strstr_len (plink->name, NM_STRLEN ("ccmni"), "ccmni")) { | ||
523 | 21 | + _LOGW (LOGD_HW, "Ignoring rild modem device: %s", plink->name); | ||
524 | 22 | + return; | ||
525 | 23 | + } | ||
526 | 24 | + | ||
527 | 25 | device = nm_device_factory_create_device (factory, plink->name, plink, NULL, &ignore, &error); | ||
528 | 26 | if (!device) { | ||
529 | 27 | if (!ignore) { | ||
530 | diff --git a/debian/patches/Ignore-rmnet_usbX-devices.patch b/debian/patches/Ignore-rmnet_usbX-devices.patch | |||
531 | 0 | deleted file mode 100644 | 28 | deleted file mode 100644 |
532 | index f973a5f..0000000 | |||
533 | --- a/debian/patches/Ignore-rmnet_usbX-devices.patch | |||
534 | +++ /dev/null | |||
535 | @@ -1,25 +0,0 @@ | |||
536 | 1 | From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> | ||
537 | 2 | Date: Fri, 13 May 2016 11:08:17 +0800 | ||
538 | 3 | Subject: Ignore rmnet_usbX devices. | ||
539 | 4 | |||
540 | 5 | --- | ||
541 | 6 | src/nm-manager.c | 6 ++++++ | ||
542 | 7 | 1 file changed, 6 insertions(+) | ||
543 | 8 | |||
544 | 9 | diff --git a/src/nm-manager.c b/src/nm-manager.c | ||
545 | 10 | index 10aa3d7..769662c 100644 | ||
546 | 11 | --- a/src/nm-manager.c | ||
547 | 12 | +++ b/src/nm-manager.c | ||
548 | 13 | @@ -2099,6 +2099,12 @@ platform_link_added (NMManager *self, | ||
549 | 14 | } | ||
550 | 15 | } | ||
551 | 16 | |||
552 | 17 | + /* Ignore rmnet_usb devices, which will be handled by their modem parent | ||
553 | 18 | + */ | ||
554 | 19 | + if (!strncmp (plink->name, "rmnet_usb", NM_STRLEN ("rmnet_usb")) || | ||
555 | 20 | + !strncmp (plink->name, "ccmni", NM_STRLEN ("ccmni"))) | ||
556 | 21 | + return; | ||
557 | 22 | + | ||
558 | 23 | if (device == NULL) { | ||
559 | 24 | switch (plink->type) { | ||
560 | 25 | case NM_LINK_TYPE_WWAN_ETHERNET: | ||
561 | diff --git a/debian/patches/Modify-NMDeviceModem-s-available-logic.patch b/debian/patches/Modify-NMDeviceModem-s-available-logic.patch | |||
562 | index 1630362..6f5a018 100644 | |||
563 | --- a/debian/patches/Modify-NMDeviceModem-s-available-logic.patch | |||
564 | +++ b/debian/patches/Modify-NMDeviceModem-s-available-logic.patch | |||
565 | @@ -9,16 +9,16 @@ meaning the device is in such a state that it can be activated. | |||
566 | 9 | This change prevents NM from trying to activate a modem which | 9 | This change prevents NM from trying to activate a modem which |
567 | 10 | is not yet ready to be activated. | 10 | is not yet ready to be activated. |
568 | 11 | 11 | ||
570 | 12 | Bug: https://bugs.launchpad.net/ubuntu/+source/network-manager/+bug/1445080 | 12 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1445080 |
571 | 13 | --- | 13 | --- |
572 | 14 | src/devices/wwan/nm-device-modem.c | 7 ++++--- | 14 | src/devices/wwan/nm-device-modem.c | 7 ++++--- |
573 | 15 | 1 file changed, 4 insertions(+), 3 deletions(-) | 15 | 1 file changed, 4 insertions(+), 3 deletions(-) |
574 | 16 | 16 | ||
575 | 17 | diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c | 17 | diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c |
577 | 18 | index a7523f5..774fd24 100644 | 18 | index 39a34db..3bbd170 100644 |
578 | 19 | --- a/src/devices/wwan/nm-device-modem.c | 19 | --- a/src/devices/wwan/nm-device-modem.c |
579 | 20 | +++ b/src/devices/wwan/nm-device-modem.c | 20 | +++ b/src/devices/wwan/nm-device-modem.c |
581 | 21 | @@ -428,14 +428,15 @@ check_connection_available (NMDevice *device, | 21 | @@ -410,14 +410,15 @@ check_connection_available (NMDevice *device, |
582 | 22 | return FALSE; | 22 | return FALSE; |
583 | 23 | 23 | ||
584 | 24 | state = nm_modem_get_state (priv->modem); | 24 | state = nm_modem_get_state (priv->modem); |
585 | @@ -36,7 +36,7 @@ index a7523f5..774fd24 100644 | |||
586 | 36 | return TRUE; | 36 | return TRUE; |
587 | 37 | } | 37 | } |
588 | 38 | 38 | ||
590 | 39 | @@ -616,7 +617,7 @@ is_available (NMDevice *device, NMDeviceCheckDevAvailableFlags flags) | 39 | @@ -598,7 +599,7 @@ is_available (NMDevice *device, NMDeviceCheckDevAvailableFlags flags) |
591 | 40 | 40 | ||
592 | 41 | g_assert (priv->modem); | 41 | g_assert (priv->modem); |
593 | 42 | modem_state = nm_modem_get_state (priv->modem); | 42 | modem_state = nm_modem_get_state (priv->modem); |
594 | diff --git a/debian/patches/Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch b/debian/patches/Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch | |||
595 | index 83d8940..0d67e33 100644 | |||
596 | --- a/debian/patches/Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch | |||
597 | +++ b/debian/patches/Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch | |||
598 | @@ -13,6 +13,8 @@ This is a very simple implementation of such re-ordering, just add the IPv6 | |||
599 | 13 | nameservers first when building the list of IP configurations (which will | 13 | nameservers first when building the list of IP configurations (which will |
600 | 14 | include nameservers, search domains, etc.), the IPv4 data will be appended | 14 | include nameservers, search domains, etc.), the IPv4 data will be appended |
601 | 15 | right after. | 15 | right after. |
602 | 16 | |||
603 | 17 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/936712 | ||
604 | 16 | --- | 18 | --- |
605 | 17 | src/dns-manager/nm-dns-manager.c | 8 ++++---- | 19 | src/dns-manager/nm-dns-manager.c | 8 ++++---- |
606 | 18 | 1 file changed, 4 insertions(+), 4 deletions(-) | 20 | 1 file changed, 4 insertions(+), 4 deletions(-) |
607 | diff --git a/debian/patches/Set-the-default-powersave-value-to-enabled.patch b/debian/patches/Set-the-default-powersave-value-to-enabled.patch | |||
608 | 19 | deleted file mode 100644 | 21 | deleted file mode 100644 |
609 | index 7449719..0000000 | |||
610 | --- a/debian/patches/Set-the-default-powersave-value-to-enabled.patch | |||
611 | +++ /dev/null | |||
612 | @@ -1,51 +0,0 @@ | |||
613 | 1 | From: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> | ||
614 | 2 | Date: Fri, 13 May 2016 11:08:10 +0800 | ||
615 | 3 | Subject: Set the default powersave value to enabled | ||
616 | 4 | |||
617 | 5 | This is an Ubuntu-specific patch to enable wireless powersave by default. | ||
618 | 6 | |||
619 | 7 | Should it not work for you for some reason, you can safely add: | ||
620 | 8 | |||
621 | 9 | powersave=0 | ||
622 | 10 | |||
623 | 11 | to the section: | ||
624 | 12 | [802-11-wireless] | ||
625 | 13 | |||
626 | 14 | In the configuration file for your connection under | ||
627 | 15 | /etc/NetworkManager/system-connections/. | ||
628 | 16 | --- | ||
629 | 17 | libnm-util/nm-setting-wireless.c | 7 +++++-- | ||
630 | 18 | 1 file changed, 5 insertions(+), 2 deletions(-) | ||
631 | 19 | |||
632 | 20 | diff --git a/libnm-util/nm-setting-wireless.c b/libnm-util/nm-setting-wireless.c | ||
633 | 21 | index 234d7ba..613539d 100644 | ||
634 | 22 | --- a/libnm-util/nm-setting-wireless.c | ||
635 | 23 | +++ b/libnm-util/nm-setting-wireless.c | ||
636 | 24 | @@ -675,7 +675,7 @@ nm_setting_wireless_get_hidden (NMSettingWireless *setting) | ||
637 | 25 | guint32 | ||
638 | 26 | nm_setting_wireless_get_powersave (NMSettingWireless *setting) | ||
639 | 27 | { | ||
640 | 28 | - g_return_val_if_fail (NM_IS_SETTING_WIRELESS (setting), 0); | ||
641 | 29 | + g_return_val_if_fail (NM_IS_SETTING_WIRELESS (setting), 1); | ||
642 | 30 | |||
643 | 31 | return NM_SETTING_WIRELESS_GET_PRIVATE (setting)->powersave; | ||
644 | 32 | } | ||
645 | 33 | @@ -885,6 +885,9 @@ verify (NMSetting *setting, GSList *all_settings, GError **error) | ||
646 | 34 | static void | ||
647 | 35 | nm_setting_wireless_init (NMSettingWireless *setting) | ||
648 | 36 | { | ||
649 | 37 | + NMSettingWirelessPrivate *priv = NM_SETTING_WIRELESS_GET_PRIVATE (setting); | ||
650 | 38 | + | ||
651 | 39 | + priv->powersave = 1; | ||
652 | 40 | } | ||
653 | 41 | |||
654 | 42 | static void | ||
655 | 43 | @@ -1283,7 +1286,7 @@ nm_setting_wireless_class_init (NMSettingWirelessClass *setting_class) | ||
656 | 44 | g_object_class_install_property | ||
657 | 45 | (object_class, PROP_POWERSAVE, | ||
658 | 46 | g_param_spec_uint (NM_SETTING_WIRELESS_POWERSAVE, "", "", | ||
659 | 47 | - 0, G_MAXUINT32, 0, | ||
660 | 48 | + 0, G_MAXUINT32, 1, | ||
661 | 49 | G_PARAM_READWRITE | | ||
662 | 50 | G_PARAM_STATIC_STRINGS)); | ||
663 | 51 | } | ||
664 | diff --git a/debian/patches/Track-killswitch-change-signals-from-urfkill.patch b/debian/patches/Track-killswitch-change-signals-from-urfkill.patch | |||
665 | index 45b668e..f96673b 100644 | |||
666 | --- a/debian/patches/Track-killswitch-change-signals-from-urfkill.patch | |||
667 | +++ b/debian/patches/Track-killswitch-change-signals-from-urfkill.patch | |||
668 | @@ -79,7 +79,7 @@ index 2495bbc..49028f1 100644 | |||
669 | 79 | if SUSPEND_RESUME_UPOWER | 79 | if SUSPEND_RESUME_UPOWER |
670 | 80 | libNetworkManager_la_SOURCES += nm-sleep-monitor-upower.c | 80 | libNetworkManager_la_SOURCES += nm-sleep-monitor-upower.c |
671 | 81 | diff --git a/src/nm-manager.c b/src/nm-manager.c | 81 | diff --git a/src/nm-manager.c b/src/nm-manager.c |
673 | 82 | index b770139..04b0a43 100644 | 82 | index 8cf70c7..8f45b0f 100644 |
674 | 83 | --- a/src/nm-manager.c | 83 | --- a/src/nm-manager.c |
675 | 84 | +++ b/src/nm-manager.c | 84 | +++ b/src/nm-manager.c |
676 | 85 | @@ -34,6 +34,7 @@ | 85 | @@ -34,6 +34,7 @@ |
677 | @@ -108,7 +108,7 @@ index b770139..04b0a43 100644 | |||
678 | 108 | 108 | ||
679 | 109 | gboolean startup; | 109 | gboolean startup; |
680 | 110 | gboolean devices_inited; | 110 | gboolean devices_inited; |
682 | 111 | @@ -5210,6 +5215,49 @@ dbus_connection_changed_cb (NMBusManager *dbus_mgr, | 111 | @@ -5213,6 +5218,49 @@ dbus_connection_changed_cb (NMBusManager *dbus_mgr, |
683 | 112 | 112 | ||
684 | 113 | /**********************************************************************/ | 113 | /**********************************************************************/ |
685 | 114 | 114 | ||
686 | @@ -158,7 +158,7 @@ index b770139..04b0a43 100644 | |||
687 | 158 | NM_DEFINE_SINGLETON_REGISTER (NMManager); | 158 | NM_DEFINE_SINGLETON_REGISTER (NMManager); |
688 | 159 | 159 | ||
689 | 160 | NMManager * | 160 | NMManager * |
691 | 161 | @@ -5231,6 +5279,44 @@ nm_connection_provider_get (void) | 161 | @@ -5234,6 +5282,44 @@ nm_connection_provider_get (void) |
692 | 162 | return p; | 162 | return p; |
693 | 163 | } | 163 | } |
694 | 164 | 164 | ||
695 | @@ -203,7 +203,7 @@ index b770139..04b0a43 100644 | |||
696 | 203 | NMManager * | 203 | NMManager * |
697 | 204 | nm_manager_setup (const char *state_file, | 204 | nm_manager_setup (const char *state_file, |
698 | 205 | gboolean initial_net_enabled, | 205 | gboolean initial_net_enabled, |
700 | 206 | @@ -5311,16 +5397,38 @@ constructed (GObject *object) | 206 | @@ -5314,16 +5400,38 @@ constructed (GObject *object) |
701 | 207 | "rfkill-changed", | 207 | "rfkill-changed", |
702 | 208 | G_CALLBACK (rfkill_manager_rfkill_changed_cb), | 208 | G_CALLBACK (rfkill_manager_rfkill_changed_cb), |
703 | 209 | self); | 209 | self); |
704 | diff --git a/debian/patches/Update-dnsmasq-parameters.patch b/debian/patches/Update-dnsmasq-parameters.patch | |||
705 | index 20d8f91..3b83b82 100644 | |||
706 | --- a/debian/patches/Update-dnsmasq-parameters.patch | |||
707 | +++ b/debian/patches/Update-dnsmasq-parameters.patch | |||
708 | @@ -6,7 +6,7 @@ Disable caching since it's a potential security issue (local dns cache poisoning | |||
709 | 6 | 6 | ||
710 | 7 | See also: https://blueprints.launchpad.net/ubuntu/+spec/foundations-p-dns-resolving | 7 | See also: https://blueprints.launchpad.net/ubuntu/+spec/foundations-p-dns-resolving |
711 | 8 | 8 | ||
713 | 9 | === modified file 'src/dns-manager/nm-dns-dnsmasq.c' | 9 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/903854 |
714 | 10 | --- | 10 | --- |
715 | 11 | src/dns-manager/nm-dns-dnsmasq.c | 4 ++-- | 11 | src/dns-manager/nm-dns-dnsmasq.c | 4 ++-- |
716 | 12 | src/dns-manager/nm-dns-manager.c | 6 +++--- | 12 | src/dns-manager/nm-dns-manager.c | 6 +++--- |
717 | diff --git a/debian/patches/series b/debian/patches/series | |||
718 | index f0a8f73..421ffe9 100644 | |||
719 | --- a/debian/patches/series | |||
720 | +++ b/debian/patches/series | |||
721 | @@ -12,13 +12,18 @@ Order-IPv6-nameservers-before-IPv4-for-dns-plugins-d.patch | |||
722 | 12 | Revert-wifi-disable-Ad-Hoc-WPA-connections-lp-905748.patch | 12 | Revert-wifi-disable-Ad-Hoc-WPA-connections-lp-905748.patch |
723 | 13 | Replace-Ad-Hoc-WPA-None-support-with-IBSS-RSN-PSK.patch | 13 | Replace-Ad-Hoc-WPA-None-support-with-IBSS-RSN-PSK.patch |
724 | 14 | wifi-Signal-on-the-wifi-device-when-its-supplicant-i.patch | 14 | wifi-Signal-on-the-wifi-device-when-its-supplicant-i.patch |
728 | 15 | Set-the-default-powersave-value-to-enabled.patch | 15 | Ignore-rild-modem-devices.patch |
729 | 16 | Ignore-rmnet_usbX-devices.patch | 16 | Ignore-p2p-wifi-devices-from-android.patch |
727 | 17 | Ignore-p2p0-wifi-devices-from-android.patch | ||
730 | 18 | wwan-add-support-for-using-oFono-as-a-modem-manager.patch | 17 | wwan-add-support-for-using-oFono-as-a-modem-manager.patch |
731 | 19 | Add-new-NMSettingsConnection-reset_retries-get-set-m.patch | 18 | Add-new-NMSettingsConnection-reset_retries-get-set-m.patch |
732 | 20 | Let-NetworkManager-read-oFono-settings-file-and-crea.patch | 19 | Let-NetworkManager-read-oFono-settings-file-and-crea.patch |
733 | 20 | Add-modem-reconnect-delay-to-policy.patch | ||
734 | 21 | Modify-NMDeviceModem-s-available-logic.patch | 21 | Modify-NMDeviceModem-s-available-logic.patch |
735 | 22 | Track-killswitch-change-signals-from-urfkill.patch | 22 | Track-killswitch-change-signals-from-urfkill.patch |
736 | 23 | Only-test-team-devices-if-we-built-support-for-them.patch | 23 | Only-test-team-devices-if-we-built-support-for-them.patch |
737 | 24 | Disable-general-with-expect-which-tends-to-fail-on-p.patch | 24 | Disable-general-with-expect-which-tends-to-fail-on-p.patch |
738 | 25 | Add-sudo-policy-to-DBus-conf-for-indicator-network.patch | ||
739 | 26 | Clear-WiFi-requested_scan-if-suppl-goes-INACTIVE.patch | ||
740 | 27 | Clear-WiFi-requested_scan-if-suppl-exits.patch | ||
741 | 28 | Fix-openvpn-by-handling-do_add_route-EEXISTS.patch | ||
742 | 29 | wwan-fix-ofono-connection-problems.patch | ||
743 | diff --git a/debian/patches/wwan-add-support-for-using-oFono-as-a-modem-manager.patch b/debian/patches/wwan-add-support-for-using-oFono-as-a-modem-manager.patch | |||
744 | index cd18c65..377ec85 100644 | |||
745 | --- a/debian/patches/wwan-add-support-for-using-oFono-as-a-modem-manager.patch | |||
746 | +++ b/debian/patches/wwan-add-support-for-using-oFono-as-a-modem-manager.patch | |||
747 | @@ -8,13 +8,13 @@ Signed-off-by: Mathieu Trudel-Lapierre <mathieu.trudel-lapierre@canonical.com> | |||
748 | 8 | --- | 8 | --- |
749 | 9 | configure.ac | 9 + | 9 | configure.ac | 9 + |
750 | 10 | src/devices/wwan/Makefile.am | 7 + | 10 | src/devices/wwan/Makefile.am | 7 + |
754 | 11 | src/devices/wwan/nm-device-modem.c | 20 + | 11 | src/devices/wwan/nm-device-modem.c | 2 + |
755 | 12 | src/devices/wwan/nm-modem-manager.c | 220 +++++- | 12 | src/devices/wwan/nm-modem-manager.c | 241 +++++- |
756 | 13 | src/devices/wwan/nm-modem-ofono.c | 1449 +++++++++++++++++++++++++++++++++++ | 13 | src/devices/wwan/nm-modem-ofono.c | 1436 +++++++++++++++++++++++++++++++++++ |
757 | 14 | src/devices/wwan/nm-modem-ofono.h | 64 ++ | 14 | src/devices/wwan/nm-modem-ofono.h | 64 ++ |
758 | 15 | src/devices/wwan/nm-modem.c | 8 +- | 15 | src/devices/wwan/nm-modem.c | 8 +- |
759 | 16 | src/nm-core-utils.c | 20 +- | 16 | src/nm-core-utils.c | 20 +- |
761 | 17 | 8 files changed, 1787 insertions(+), 10 deletions(-) | 17 | 8 files changed, 1766 insertions(+), 21 deletions(-) |
762 | 18 | create mode 100644 src/devices/wwan/nm-modem-ofono.c | 18 | create mode 100644 src/devices/wwan/nm-modem-ofono.c |
763 | 19 | create mode 100644 src/devices/wwan/nm-modem-ofono.h | 19 | create mode 100644 src/devices/wwan/nm-modem-ofono.h |
764 | 20 | 20 | ||
765 | @@ -57,7 +57,7 @@ index 1777eb3..65d9952 100644 | |||
766 | 57 | 57 | ||
767 | 58 | libnm_wwan_la_LDFLAGS = \ | 58 | libnm_wwan_la_LDFLAGS = \ |
768 | 59 | diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c | 59 | diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c |
770 | 60 | index a8361c4..a7523f5 100644 | 60 | index a8361c4..39a34db 100644 |
771 | 61 | --- a/src/devices/wwan/nm-device-modem.c | 61 | --- a/src/devices/wwan/nm-device-modem.c |
772 | 62 | +++ b/src/devices/wwan/nm-device-modem.c | 62 | +++ b/src/devices/wwan/nm-device-modem.c |
773 | 63 | @@ -100,6 +100,7 @@ modem_prepare_result (NMModem *modem, | 63 | @@ -100,6 +100,7 @@ modem_prepare_result (NMModem *modem, |
774 | @@ -68,39 +68,7 @@ index a8361c4..a7523f5 100644 | |||
775 | 68 | if (reason == NM_DEVICE_STATE_REASON_SIM_PIN_INCORRECT) { | 68 | if (reason == NM_DEVICE_STATE_REASON_SIM_PIN_INCORRECT) { |
776 | 69 | /* If the connect failed because the SIM PIN was wrong don't allow | 69 | /* If the connect failed because the SIM PIN was wrong don't allow |
777 | 70 | * the device to be auto-activated anymore, which would risk locking | 70 | * the device to be auto-activated anymore, which would risk locking |
811 | 71 | @@ -282,6 +283,16 @@ modem_state_cb (NMModem *modem, | 71 | @@ -545,6 +546,7 @@ get_ip_iface_identifier (NMDevice *device, NMUtilsIPv6IfaceId *out_iid) |
779 | 72 | } | ||
780 | 73 | } | ||
781 | 74 | |||
782 | 75 | + if (dev_state >= NM_DEVICE_STATE_DISCONNECTED && | ||
783 | 76 | + new_state == NM_MODEM_STATE_REGISTERED && old_state < NM_MODEM_STATE_REGISTERED) { | ||
784 | 77 | + | ||
785 | 78 | + nm_log_info (LOGD_MB, "(%s): modem re-registered; re-checking autoconnect", | ||
786 | 79 | + nm_device_get_iface (device)); | ||
787 | 80 | + | ||
788 | 81 | + g_object_set (G_OBJECT (device), NM_DEVICE_AUTOCONNECT, TRUE, NULL); | ||
789 | 82 | + nm_device_emit_recheck_auto_activate (device); | ||
790 | 83 | + } | ||
791 | 84 | + | ||
792 | 85 | if (new_state < NM_MODEM_STATE_CONNECTING && | ||
793 | 86 | old_state >= NM_MODEM_STATE_CONNECTING && | ||
794 | 87 | dev_state >= NM_DEVICE_STATE_NEED_AUTH && | ||
795 | 88 | @@ -345,6 +356,14 @@ device_state_changed (NMDevice *device, | ||
796 | 89 | nm_modem_state_to_string (nm_modem_get_state (priv->modem))); | ||
797 | 90 | } | ||
798 | 91 | |||
799 | 92 | + /* Block autoconnect until the modem is registered again */ | ||
800 | 93 | + if (new_state == NM_DEVICE_STATE_FAILED && nm_modem_get_state (priv->modem) == NM_MODEM_STATE_SEARCHING) { | ||
801 | 94 | + nm_log_info (LOGD_MB, "(%s): modem searching; disabling autoconnect", | ||
802 | 95 | + nm_device_get_iface (device)); | ||
803 | 96 | + | ||
804 | 97 | + g_object_set (G_OBJECT (device), NM_DEVICE_AUTOCONNECT, FALSE, NULL); | ||
805 | 98 | + } | ||
806 | 99 | + | ||
807 | 100 | nm_modem_device_state_changed (priv->modem, new_state, old_state, reason); | ||
808 | 101 | |||
809 | 102 | switch (reason) { | ||
810 | 103 | @@ -545,6 +564,7 @@ get_ip_iface_identifier (NMDevice *device, NMUtilsIPv6IfaceId *out_iid) | ||
812 | 104 | 72 | ||
813 | 105 | g_return_val_if_fail (priv->modem, FALSE); | 73 | g_return_val_if_fail (priv->modem, FALSE); |
814 | 106 | success = nm_modem_get_iid (priv->modem, out_iid); | 74 | success = nm_modem_get_iid (priv->modem, out_iid); |
815 | @@ -109,7 +77,7 @@ index a8361c4..a7523f5 100644 | |||
816 | 109 | success = NM_DEVICE_CLASS (nm_device_modem_parent_class)->get_ip_iface_identifier (device, out_iid); | 77 | success = NM_DEVICE_CLASS (nm_device_modem_parent_class)->get_ip_iface_identifier (device, out_iid); |
817 | 110 | return success; | 78 | return success; |
818 | 111 | diff --git a/src/devices/wwan/nm-modem-manager.c b/src/devices/wwan/nm-modem-manager.c | 79 | diff --git a/src/devices/wwan/nm-modem-manager.c b/src/devices/wwan/nm-modem-manager.c |
820 | 112 | index 9e9bc13..0d1ec78 100644 | 80 | index 9e9bc13..cd97b87 100644 |
821 | 113 | --- a/src/devices/wwan/nm-modem-manager.c | 81 | --- a/src/devices/wwan/nm-modem-manager.c |
822 | 114 | +++ b/src/devices/wwan/nm-modem-manager.c | 82 | +++ b/src/devices/wwan/nm-modem-manager.c |
823 | 115 | @@ -17,7 +17,7 @@ | 83 | @@ -17,7 +17,7 @@ |
824 | @@ -251,7 +219,7 @@ index 9e9bc13..0d1ec78 100644 | |||
825 | 251 | +{ | 219 | +{ |
826 | 252 | + gchar *name_owner; | 220 | + gchar *name_owner; |
827 | 253 | + | 221 | + |
829 | 254 | + name_owner = g_dbus_object_manager_client_get_name_owner (G_DBUS_OBJECT_MANAGER_CLIENT (self->priv->ofono_proxy)); | 222 | + name_owner = g_dbus_proxy_get_name_owner (G_DBUS_PROXY (self->priv->ofono_proxy)); |
830 | 255 | + if (name_owner) { | 223 | + if (name_owner) { |
831 | 256 | + /* Available! */ | 224 | + /* Available! */ |
832 | 257 | + ofono_appeared (self); | 225 | + ofono_appeared (self); |
833 | @@ -324,7 +292,37 @@ index 9e9bc13..0d1ec78 100644 | |||
834 | 324 | 292 | ||
835 | 325 | static void | 293 | static void |
836 | 326 | modem_manager_poke_cb (GDBusConnection *connection, | 294 | modem_manager_poke_cb (GDBusConnection *connection, |
838 | 327 | @@ -336,22 +518,44 @@ manager_new_ready (GObject *source, | 295 | @@ -233,19 +415,18 @@ modem_manager_poke_cb (GDBusConnection *connection, |
839 | 296 | |||
840 | 297 | result = g_dbus_connection_call_finish (connection, res, &error); | ||
841 | 298 | if (error) { | ||
842 | 299 | - /* Ignore common errors when MM is not installed and such */ | ||
843 | 300 | - if ( !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SERVICE_UNKNOWN) | ||
844 | 301 | - && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SPAWN_EXEC_FAILED) | ||
845 | 302 | - && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SPAWN_FORK_FAILED) | ||
846 | 303 | - && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SPAWN_FAILED) | ||
847 | 304 | - && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_TIMEOUT) | ||
848 | 305 | - && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SPAWN_SERVICE_NOT_FOUND)) { | ||
849 | 306 | - nm_log_dbg (LOGD_MB, "error poking ModemManager: %s", error->message); | ||
850 | 307 | + nm_log_warn (LOGD_MB, "error poking ModemManager: %s", | ||
851 | 308 | + error ? error->message : ""); | ||
852 | 309 | + | ||
853 | 310 | + /* Don't reschedule poke is MM service doesn't exist. */ | ||
854 | 311 | + if (!g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SERVICE_UNKNOWN) | ||
855 | 312 | + && !g_error_matches (error, G_DBUS_ERROR, G_DBUS_ERROR_SPAWN_SERVICE_NOT_FOUND)) { | ||
856 | 313 | + | ||
857 | 314 | + /* Setup timeout to relaunch */ | ||
858 | 315 | + schedule_modem_manager_relaunch (self, MODEM_POKE_INTERVAL); | ||
859 | 316 | } | ||
860 | 317 | - g_error_free (error); | ||
861 | 318 | |||
862 | 319 | - /* Setup timeout to relaunch */ | ||
863 | 320 | - schedule_modem_manager_relaunch (self, MODEM_POKE_INTERVAL); | ||
864 | 321 | + g_error_free (error); | ||
865 | 322 | } else | ||
866 | 323 | g_variant_unref (result); | ||
867 | 324 | |||
868 | 325 | @@ -336,22 +517,44 @@ manager_new_ready (GObject *source, | ||
869 | 328 | static void | 326 | static void |
870 | 329 | ensure_client (NMModemManager *self) | 327 | ensure_client (NMModemManager *self) |
871 | 330 | { | 328 | { |
872 | @@ -373,7 +371,7 @@ index 9e9bc13..0d1ec78 100644 | |||
873 | 373 | } | 371 | } |
874 | 374 | 372 | ||
875 | 375 | static void | 373 | static void |
877 | 376 | @@ -430,6 +634,12 @@ dispose (GObject *object) | 374 | @@ -430,6 +633,12 @@ dispose (GObject *object) |
878 | 377 | 375 | ||
879 | 378 | modem_manager_clear_signals (self); | 376 | modem_manager_clear_signals (self); |
880 | 379 | g_clear_object (&self->priv->modem_manager); | 377 | g_clear_object (&self->priv->modem_manager); |
881 | @@ -388,10 +386,10 @@ index 9e9bc13..0d1ec78 100644 | |||
882 | 388 | if (self->priv->modems) { | 386 | if (self->priv->modems) { |
883 | 389 | diff --git a/src/devices/wwan/nm-modem-ofono.c b/src/devices/wwan/nm-modem-ofono.c | 387 | diff --git a/src/devices/wwan/nm-modem-ofono.c b/src/devices/wwan/nm-modem-ofono.c |
884 | 390 | new file mode 100644 | 388 | new file mode 100644 |
886 | 391 | index 0000000..162b88d | 389 | index 0000000..4566be0 |
887 | 392 | --- /dev/null | 390 | --- /dev/null |
888 | 393 | +++ b/src/devices/wwan/nm-modem-ofono.c | 391 | +++ b/src/devices/wwan/nm-modem-ofono.c |
890 | 394 | @@ -0,0 +1,1449 @@ | 392 | @@ -0,0 +1,1436 @@ |
891 | 395 | +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */ | 393 | +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */ |
892 | 396 | +/* NetworkManager -- Network link manager | 394 | +/* NetworkManager -- Network link manager |
893 | 397 | + * | 395 | + * |
894 | @@ -604,12 +602,7 @@ index 0000000..162b88d | |||
895 | 604 | + nm_log_dbg (LOGD_MB, "(%s): modem disconnected", | 602 | + nm_log_dbg (LOGD_MB, "(%s): modem disconnected", |
896 | 605 | + nm_modem_get_uid (NM_MODEM (self))); | 603 | + nm_modem_get_uid (NM_MODEM (self))); |
897 | 606 | + | 604 | + |
904 | 607 | + /* NOTES(1.2): This doesn't accomplish anything as none of the attributes that | 605 | + update_modem_state (self); |
899 | 608 | + * are checked by update_modem_state are changed by this function! | ||
900 | 609 | + * | ||
901 | 610 | + * update_modem_state (self); | ||
902 | 611 | + */ | ||
903 | 612 | + | ||
905 | 613 | + disconnect_context_complete (ctx); | 606 | + disconnect_context_complete (ctx); |
906 | 614 | +} | 607 | +} |
907 | 615 | + | 608 | + |
908 | @@ -784,7 +777,7 @@ index 0000000..162b88d | |||
909 | 784 | + &error); | 777 | + &error); |
910 | 785 | + if (!v_properties) { | 778 | + if (!v_properties) { |
911 | 786 | + g_dbus_error_strip_remote_error (error); | 779 | + g_dbus_error_strip_remote_error (error); |
913 | 787 | + nm_log_warn (LOGD_BT, "(%s) error getting sim properties: %s", | 780 | + nm_log_warn (LOGD_MB, "(%s) error getting sim properties: %s", |
914 | 788 | + nm_modem_get_uid (NM_MODEM (self)), | 781 | + nm_modem_get_uid (NM_MODEM (self)), |
915 | 789 | + error->message); | 782 | + error->message); |
916 | 790 | + g_error_free (error); | 783 | + g_error_free (error); |
917 | @@ -795,7 +788,7 @@ index 0000000..162b88d | |||
918 | 795 | + | 788 | + |
919 | 796 | + v_dict = g_variant_get_child_value (v_properties, 0); | 789 | + v_dict = g_variant_get_child_value (v_properties, 0); |
920 | 797 | + if (!v_dict) { | 790 | + if (!v_dict) { |
922 | 798 | + nm_log_warn (LOGD_BT, "(%s) error getting sim properties: no v_dict", | 791 | + nm_log_warn (LOGD_MB, "(%s) error getting sim properties: no v_dict", |
923 | 799 | + nm_modem_get_uid (NM_MODEM (self))); | 792 | + nm_modem_get_uid (NM_MODEM (self))); |
924 | 800 | + return; | 793 | + return; |
925 | 801 | + } | 794 | + } |
926 | @@ -897,7 +890,7 @@ index 0000000..162b88d | |||
927 | 897 | + gboolean attached = g_variant_get_boolean (v); | 890 | + gboolean attached = g_variant_get_boolean (v); |
928 | 898 | + | 891 | + |
929 | 899 | + nm_log_dbg (LOGD_MB, "(%s): Attached: %s", | 892 | + nm_log_dbg (LOGD_MB, "(%s): Attached: %s", |
931 | 900 | + nm_modem_get_uid (NM_MODEM (self)), property ? "True" : "False"); | 893 | + nm_modem_get_uid (NM_MODEM (self)), attached ? "True" : "False"); |
932 | 901 | + | 894 | + |
933 | 902 | + if (priv->gprs_attached != attached) { | 895 | + if (priv->gprs_attached != attached) { |
934 | 903 | + priv->gprs_attached = attached; | 896 | + priv->gprs_attached = attached; |
935 | @@ -941,7 +934,7 @@ index 0000000..162b88d | |||
936 | 941 | + &error); | 934 | + &error); |
937 | 942 | + if (!v_properties) { | 935 | + if (!v_properties) { |
938 | 943 | + g_dbus_error_strip_remote_error (error); | 936 | + g_dbus_error_strip_remote_error (error); |
940 | 944 | + nm_log_warn (LOGD_BT, "(%s) error getting connman properties: %s", | 937 | + nm_log_warn (LOGD_MB, "(%s) error getting connman properties: %s", |
941 | 945 | + nm_modem_get_uid (NM_MODEM (self)), | 938 | + nm_modem_get_uid (NM_MODEM (self)), |
942 | 946 | + error->message); | 939 | + error->message); |
943 | 947 | + g_error_free (error); | 940 | + g_error_free (error); |
944 | @@ -1121,7 +1114,7 @@ index 0000000..162b88d | |||
945 | 1121 | + &error); | 1114 | + &error); |
946 | 1122 | + if (!v_properties) { | 1115 | + if (!v_properties) { |
947 | 1123 | + g_dbus_error_strip_remote_error (error); | 1116 | + g_dbus_error_strip_remote_error (error); |
949 | 1124 | + nm_log_warn (LOGD_BT, "(%s) error getting modem properties: %s", | 1117 | + nm_log_warn (LOGD_MB, "(%s) error getting modem properties: %s", |
950 | 1125 | + nm_modem_get_uid (NM_MODEM (self)), | 1118 | + nm_modem_get_uid (NM_MODEM (self)), |
951 | 1126 | + error->message); | 1119 | + error->message); |
952 | 1127 | + g_error_free (error); | 1120 | + g_error_free (error); |
953 | @@ -1130,7 +1123,7 @@ index 0000000..162b88d | |||
954 | 1130 | + | 1123 | + |
955 | 1131 | + v_dict = g_variant_get_child_value (v_properties, 0); | 1124 | + v_dict = g_variant_get_child_value (v_properties, 0); |
956 | 1132 | + if (!v_dict) { | 1125 | + if (!v_dict) { |
958 | 1133 | + nm_log_warn (LOGD_BT, "(%s) error getting modem properties: no v_dict", | 1126 | + nm_log_warn (LOGD_MB, "(%s) error getting modem properties: no v_dict", |
959 | 1134 | + nm_modem_get_uid (NM_MODEM (self))); | 1127 | + nm_modem_get_uid (NM_MODEM (self))); |
960 | 1135 | + return; | 1128 | + return; |
961 | 1136 | + } | 1129 | + } |
962 | @@ -1226,14 +1219,6 @@ index 0000000..162b88d | |||
963 | 1226 | + nm_log_dbg (LOGD_MB, "PropertyChanged: %s", property); | 1219 | + nm_log_dbg (LOGD_MB, "PropertyChanged: %s", property); |
964 | 1227 | + | 1220 | + |
965 | 1228 | + /* | 1221 | + /* |
966 | 1229 | + * 0.9.10.x: | ||
967 | 1230 | + * | ||
968 | 1231 | + * The old code got PropertyChanged for Settings, and then immediately | ||
969 | 1232 | + * called 'GetProperties' to get the current values of 'Settings'. | ||
970 | 1233 | + * | ||
971 | 1234 | + * There's no need to do this, as the PropertyChanged has the value of | ||
972 | 1235 | + * 'Settings' as its payload!!! | ||
973 | 1236 | + * | ||
974 | 1237 | + * TODO: might be a good idea and re-factor this to mimic bluez-device, | 1222 | + * TODO: might be a good idea and re-factor this to mimic bluez-device, |
975 | 1238 | + * ie. have this function just check the key, and call a sub-func to | 1223 | + * ie. have this function just check the key, and call a sub-func to |
976 | 1239 | + * handle the action. | 1224 | + * handle the action. |
977 | @@ -1242,24 +1227,14 @@ index 0000000..162b88d | |||
978 | 1242 | + if (g_strcmp0 (property, "Settings") != 0) | 1227 | + if (g_strcmp0 (property, "Settings") != 0) |
979 | 1243 | + return; | 1228 | + return; |
980 | 1244 | + | 1229 | + |
981 | 1245 | + nm_log_dbg (LOGD_MB, "found 'Settings' DICTIONARY property"); | ||
982 | 1246 | + | ||
983 | 1247 | + if (nm_modem_get_state (NM_MODEM (self)) == NM_MODEM_STATE_CONNECTED && g_variant_n_children (v) <= 0) { | ||
984 | 1248 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings empty", nm_modem_get_uid (NM_MODEM (self))); | ||
985 | 1249 | + | ||
986 | 1250 | + goto out; | ||
987 | 1251 | + } | ||
988 | 1252 | + | ||
989 | 1253 | + nm_log_info (LOGD_MB, "ofono: (%s): IPv4 static configuration:", nm_modem_get_uid (NM_MODEM (self))); | ||
990 | 1254 | + | ||
991 | 1255 | + v_dict = g_variant_get_child_value (v, 0); | 1230 | + v_dict = g_variant_get_child_value (v, 0); |
992 | 1256 | + if (!v_dict) { | 1231 | + if (!v_dict) { |
994 | 1257 | + nm_log_warn (LOGD_BT, "ofono: (%s): error getting IPv4 Settings: no v_dict", | 1232 | + nm_log_warn (LOGD_MB, "ofono: (%s): error getting IPv4 Settings", |
995 | 1258 | + nm_modem_get_uid (NM_MODEM (self))); | 1233 | + nm_modem_get_uid (NM_MODEM (self))); |
997 | 1259 | + return; | 1234 | + goto out; |
998 | 1260 | + } | 1235 | + } |
999 | 1261 | + | 1236 | + |
1001 | 1262 | + /* NOTE - 0.9.10x code didn't fail if 'Interface' missing */ | 1237 | + nm_log_info (LOGD_MB, "ofono: (%s): IPv4 static Settings:", nm_modem_get_uid (NM_MODEM (self))); |
1002 | 1263 | + | 1238 | + |
1003 | 1264 | + if (g_variant_lookup (v_dict, "Interface", "&s", &s)) { | 1239 | + if (g_variant_lookup (v_dict, "Interface", "&s", &s)) { |
1004 | 1265 | + | 1240 | + |
1005 | @@ -1271,7 +1246,7 @@ index 0000000..162b88d | |||
1006 | 1271 | + NM_MODEM_IP4_METHOD, NM_MODEM_IP_METHOD_STATIC, | 1246 | + NM_MODEM_IP4_METHOD, NM_MODEM_IP_METHOD_STATIC, |
1007 | 1272 | + NULL); | 1247 | + NULL); |
1008 | 1273 | + } else { | 1248 | + } else { |
1010 | 1274 | + nm_log_warn (LOGD_BT, "ofono: (%s): Settings 'Interface'; empty", | 1249 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings 'Interface'; empty", |
1011 | 1275 | + nm_modem_get_uid (NM_MODEM (self))); | 1250 | + nm_modem_get_uid (NM_MODEM (self))); |
1012 | 1276 | + goto out; | 1251 | + goto out; |
1013 | 1277 | + } | 1252 | + } |
1014 | @@ -1323,6 +1298,7 @@ index 0000000..162b88d | |||
1015 | 1323 | + } else { | 1298 | + } else { |
1016 | 1324 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings 'Address' missing", | 1299 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings 'Address' missing", |
1017 | 1325 | + nm_modem_get_uid (NM_MODEM (self))); | 1300 | + nm_modem_get_uid (NM_MODEM (self))); |
1018 | 1301 | + goto out; | ||
1019 | 1326 | + } | 1302 | + } |
1020 | 1327 | + | 1303 | + |
1021 | 1328 | + if (g_variant_lookup (v_dict, "Netmask", "&s", &s)) { | 1304 | + if (g_variant_lookup (v_dict, "Netmask", "&s", &s)) { |
1022 | @@ -1345,7 +1321,9 @@ index 0000000..162b88d | |||
1023 | 1345 | + goto out; | 1321 | + goto out; |
1024 | 1346 | + } | 1322 | + } |
1025 | 1347 | + | 1323 | + |
1027 | 1348 | + nm_log_info (LOGD_MB, " address %s/%d", addr_s, prefix); | 1324 | + nm_log_info (LOGD_MB, "ofono (%s) Address: %s/%d", |
1028 | 1325 | + nm_modem_get_uid (NM_MODEM (self)), addr_s, prefix); | ||
1029 | 1326 | + | ||
1030 | 1349 | + nm_ip4_config_add_address (priv->ip4_config, &addr); | 1327 | + nm_ip4_config_add_address (priv->ip4_config, &addr); |
1031 | 1350 | + | 1328 | + |
1032 | 1351 | + if (g_variant_lookup (v_dict, "Gateway", "&s", &s)) { | 1329 | + if (g_variant_lookup (v_dict, "Gateway", "&s", &s)) { |
1033 | @@ -1372,7 +1350,7 @@ index 0000000..162b88d | |||
1034 | 1372 | + | 1350 | + |
1035 | 1373 | + while (*iter) { | 1351 | + while (*iter) { |
1036 | 1374 | + if (ip_string_to_network_address (*iter, &address_network) && address_network > 0) { | 1352 | + if (ip_string_to_network_address (*iter, &address_network) && address_network > 0) { |
1038 | 1375 | + nm_log_info (LOGD_MB, "ofono: (%s): DNS %s", | 1353 | + nm_log_info (LOGD_MB, "ofono: (%s): DNS: %s", |
1039 | 1376 | + nm_modem_get_uid (NM_MODEM (self)), *iter); | 1354 | + nm_modem_get_uid (NM_MODEM (self)), *iter); |
1040 | 1377 | + | 1355 | + |
1041 | 1378 | + nm_ip4_config_add_nameserver (priv->ip4_config, address_network); | 1356 | + nm_ip4_config_add_nameserver (priv->ip4_config, address_network); |
1042 | @@ -1384,13 +1362,15 @@ index 0000000..162b88d | |||
1043 | 1384 | + *iter++; | 1362 | + *iter++; |
1044 | 1385 | + } | 1363 | + } |
1045 | 1386 | + | 1364 | + |
1047 | 1387 | + /* TOOD: check for minimum NameServers >= 1? */ | 1365 | + if (iter == array) { |
1048 | 1366 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings: 'DomainNameServers': none specified", | ||
1049 | 1367 | + nm_modem_get_uid (NM_MODEM (self))); | ||
1050 | 1368 | + g_free (array); | ||
1051 | 1369 | + goto out; | ||
1052 | 1370 | + } | ||
1053 | 1388 | + | 1371 | + |
1054 | 1389 | + g_free (array); | 1372 | + g_free (array); |
1055 | 1390 | + } else { | 1373 | + } else { |
1056 | 1391 | + | ||
1057 | 1392 | + /* NOTE - 0.9.10.x would not throw an error in this case!!! */ | ||
1058 | 1393 | + | ||
1059 | 1394 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings 'DomainNameServers' missing", | 1374 | + nm_log_warn (LOGD_MB, "ofono: (%s): Settings 'DomainNameServers' missing", |
1060 | 1395 | + nm_modem_get_uid (NM_MODEM (self))); | 1375 | + nm_modem_get_uid (NM_MODEM (self))); |
1061 | 1396 | + goto out; | 1376 | + goto out; |
1062 | @@ -1419,14 +1399,19 @@ index 0000000..162b88d | |||
1063 | 1419 | + ret = TRUE; | 1399 | + ret = TRUE; |
1064 | 1420 | + | 1400 | + |
1065 | 1421 | +out: | 1401 | +out: |
1068 | 1422 | + if (!ret) | 1402 | + if (nm_modem_get_state (NM_MODEM (self)) != NM_MODEM_STATE_CONNECTED) { |
1069 | 1423 | + reason = NM_DEVICE_STATE_REASON_IP_CONFIG_UNAVAILABLE; | 1403 | + nm_log_info (LOGD_MB, "ofono: (%s): emitting PREPARE_RESULT: %s", |
1070 | 1404 | + nm_modem_get_uid (NM_MODEM (self)), ret ? "TRUE" : "FALSE"); | ||
1071 | 1424 | + | 1405 | + |
1074 | 1425 | + nm_log_dbg (LOGD_MB, "(%s): DONE w/Settings; ret: %s", | 1406 | + if (!ret) |
1075 | 1426 | + nm_modem_get_uid (NM_MODEM (self)), ret ? "TRUE" : "FALSE"); | 1407 | + reason = NM_DEVICE_STATE_REASON_IP_CONFIG_UNAVAILABLE; |
1076 | 1427 | + | 1408 | + |
1077 | 1428 | + if (nm_modem_get_state (NM_MODEM (self)) != NM_MODEM_STATE_CONNECTED) | ||
1078 | 1429 | + g_signal_emit_by_name (self, NM_MODEM_PREPARE_RESULT, ret, reason); | 1409 | + g_signal_emit_by_name (self, NM_MODEM_PREPARE_RESULT, ret, reason); |
1079 | 1410 | + } else { | ||
1080 | 1411 | + nm_log_warn (LOGD_MB, "ofono: (%s): MODEM_PPP_FAILED", nm_modem_get_uid (NM_MODEM (self))); | ||
1081 | 1412 | + | ||
1082 | 1413 | + g_signal_emit_by_name (self, NM_MODEM_PPP_FAILED, NM_DEVICE_STATE_REASON_PPP_FAILED); | ||
1083 | 1414 | + } | ||
1084 | 1430 | +} | 1415 | +} |
1085 | 1431 | + | 1416 | + |
1086 | 1432 | +static NMActStageReturn | 1417 | +static NMActStageReturn |
1087 | diff --git a/debian/patches/wwan-fix-ofono-connection-problems.patch b/debian/patches/wwan-fix-ofono-connection-problems.patch | |||
1088 | 1433 | new file mode 100644 | 1418 | new file mode 100644 |
1089 | index 0000000..bff500d | |||
1090 | --- /dev/null | |||
1091 | +++ b/debian/patches/wwan-fix-ofono-connection-problems.patch | |||
1092 | @@ -0,0 +1,343 @@ | |||
1093 | 1 | From: Tony Espy <espy@canonical.com> | ||
1094 | 2 | Date: Fri, 3 Jun 2016 18:03:32 -0400 | ||
1095 | 3 | Subject: Fix ofono connection problems | ||
1096 | 4 | |||
1097 | 5 | This patch fixes three (re) connection problems with | ||
1098 | 6 | the ofono plugin: | ||
1099 | 7 | |||
1100 | 8 | 1) If the modem is connected, and registrations drops, | ||
1101 | 9 | and then is restored, the connection isn't re-activated. | ||
1102 | 10 | The fix was simply to change modem_state_cb to not return | ||
1103 | 11 | after setting the state to failed, which allows nm_device_ | ||
1104 | 12 | queue_recheck_available to be called, which queues a state | ||
1105 | 13 | transition to UNAVAILABLE. | ||
1106 | 14 | |||
1107 | 15 | 2) If ofono returns InProgress, don't treat as a PREPARE_FAILURE. | ||
1108 | 16 | |||
1109 | 17 | 3) If the ofono conext is already active, use it's existing | ||
1110 | 18 | 'Settings' property to configure the device. | ||
1111 | 19 | |||
1112 | 20 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1565717 | ||
1113 | 21 | Bug-Ubuntu: https://bugs.launchpad.net/bugs/1579098 | ||
1114 | 22 | --- | ||
1115 | 23 | src/devices/wwan/nm-device-modem.c | 4 +- | ||
1116 | 24 | src/devices/wwan/nm-modem-ofono.c | 193 +++++++++++++++++++++++++++---------- | ||
1117 | 25 | src/devices/wwan/nm-modem-ofono.h | 2 + | ||
1118 | 26 | 3 files changed, 145 insertions(+), 54 deletions(-) | ||
1119 | 27 | |||
1120 | 28 | diff --git a/src/devices/wwan/nm-device-modem.c b/src/devices/wwan/nm-device-modem.c | ||
1121 | 29 | index 3bbd170..22009f8 100644 | ||
1122 | 30 | --- a/src/devices/wwan/nm-device-modem.c | ||
1123 | 31 | +++ b/src/devices/wwan/nm-device-modem.c | ||
1124 | 32 | @@ -286,12 +286,10 @@ modem_state_cb (NMModem *modem, | ||
1125 | 33 | if (new_state < NM_MODEM_STATE_CONNECTING && | ||
1126 | 34 | old_state >= NM_MODEM_STATE_CONNECTING && | ||
1127 | 35 | dev_state >= NM_DEVICE_STATE_NEED_AUTH && | ||
1128 | 36 | - dev_state <= NM_DEVICE_STATE_ACTIVATED) { | ||
1129 | 37 | + dev_state <= NM_DEVICE_STATE_ACTIVATED) | ||
1130 | 38 | /* Fail the device if the modem disconnects unexpectedly while the | ||
1131 | 39 | * device is activating/activated. */ | ||
1132 | 40 | nm_device_state_changed (device, NM_DEVICE_STATE_FAILED, NM_DEVICE_STATE_REASON_MODEM_NO_CARRIER); | ||
1133 | 41 | - return; | ||
1134 | 42 | - } | ||
1135 | 43 | |||
1136 | 44 | if (new_state > NM_MODEM_STATE_LOCKED && old_state == NM_MODEM_STATE_LOCKED) { | ||
1137 | 45 | /* If the modem is now unlocked, enable/disable it according to the | ||
1138 | 46 | diff --git a/src/devices/wwan/nm-modem-ofono.c b/src/devices/wwan/nm-modem-ofono.c | ||
1139 | 47 | index 4566be0..c09cfd5 100644 | ||
1140 | 48 | --- a/src/devices/wwan/nm-modem-ofono.c | ||
1141 | 49 | +++ b/src/devices/wwan/nm-modem-ofono.c | ||
1142 | 50 | @@ -789,42 +789,35 @@ stage1_prepare_done (GDBusProxy *proxy, GAsyncResult *result, gpointer user_data | ||
1143 | 51 | g_dbus_proxy_call_finish (proxy, result, &error); | ||
1144 | 52 | |||
1145 | 53 | if (error) { | ||
1146 | 54 | - nm_log_warn (LOGD_MB, "ofono: connection failed: (%d) %s", | ||
1147 | 55 | - error ? error->code : -1, | ||
1148 | 56 | - error && error->message ? error->message : "(unknown)"); | ||
1149 | 57 | + if (!g_strstr_len (error->message, NM_STRLEN (OFONO_ERROR_IN_PROGRESS), OFONO_ERROR_IN_PROGRESS)) { | ||
1150 | 58 | + nm_log_warn (LOGD_MB, "ofono: connection failed: (%d) %s", | ||
1151 | 59 | + error ? error->code : -1, | ||
1152 | 60 | + error && error->message ? error->message : "(unknown)"); | ||
1153 | 61 | |||
1154 | 62 | - g_signal_emit_by_name (self, NM_MODEM_PREPARE_RESULT, FALSE, | ||
1155 | 63 | - NM_DEVICE_STATE_REASON_MODEM_BUSY); | ||
1156 | 64 | - /* | ||
1157 | 65 | - * FIXME: add code to check for InProgress so that the | ||
1158 | 66 | - * connection doesn't continue to try and activate, | ||
1159 | 67 | - * leading to the connection being disabled, and a 5m | ||
1160 | 68 | - * timeout... | ||
1161 | 69 | - */ | ||
1162 | 70 | + g_signal_emit_by_name (self, NM_MODEM_PREPARE_RESULT, FALSE, | ||
1163 | 71 | + NM_DEVICE_STATE_REASON_MODEM_BUSY); | ||
1164 | 72 | + } else | ||
1165 | 73 | + nm_log_warn (LOGD_MB, "ofono: connection activation returned Error.InProgress"); | ||
1166 | 74 | |||
1167 | 75 | g_clear_error (&error); | ||
1168 | 76 | } | ||
1169 | 77 | } | ||
1170 | 78 | |||
1171 | 79 | static void | ||
1172 | 80 | -context_property_changed (GDBusProxy *proxy, | ||
1173 | 81 | - const char *property, | ||
1174 | 82 | - GVariant *v, | ||
1175 | 83 | - gpointer user_data) | ||
1176 | 84 | +handle_settings (GVariant *v_dict, gpointer user_data) | ||
1177 | 85 | { | ||
1178 | 86 | NMModemOfono *self = NM_MODEM_OFONO (user_data); | ||
1179 | 87 | NMModemOfonoPrivate *priv = NM_MODEM_OFONO_GET_PRIVATE (self); | ||
1180 | 88 | NMDeviceStateReason reason = NM_DEVICE_STATE_REASON_NONE; | ||
1181 | 89 | NMPlatformIP4Address addr; | ||
1182 | 90 | gboolean ret = FALSE; | ||
1183 | 91 | - GVariant *v_dict; | ||
1184 | 92 | GVariantIter i; | ||
1185 | 93 | const gchar *s, *addr_s; | ||
1186 | 94 | const gchar **array, **iter; | ||
1187 | 95 | guint32 address_network, gateway_network; | ||
1188 | 96 | guint prefix = 0; | ||
1189 | 97 | |||
1190 | 98 | - nm_log_dbg (LOGD_MB, "PropertyChanged: %s", property); | ||
1191 | 99 | + nm_log_info (LOGD_MB, "ofono: (%s): IPv4 static Settings:", nm_modem_get_uid (NM_MODEM (self))); | ||
1192 | 100 | |||
1193 | 101 | /* | ||
1194 | 102 | * TODO: might be a good idea and re-factor this to mimic bluez-device, | ||
1195 | 103 | @@ -832,18 +825,6 @@ context_property_changed (GDBusProxy *proxy, | ||
1196 | 104 | * handle the action. | ||
1197 | 105 | */ | ||
1198 | 106 | |||
1199 | 107 | - if (g_strcmp0 (property, "Settings") != 0) | ||
1200 | 108 | - return; | ||
1201 | 109 | - | ||
1202 | 110 | - v_dict = g_variant_get_child_value (v, 0); | ||
1203 | 111 | - if (!v_dict) { | ||
1204 | 112 | - nm_log_warn (LOGD_MB, "ofono: (%s): error getting IPv4 Settings", | ||
1205 | 113 | - nm_modem_get_uid (NM_MODEM (self))); | ||
1206 | 114 | - goto out; | ||
1207 | 115 | - } | ||
1208 | 116 | - | ||
1209 | 117 | - nm_log_info (LOGD_MB, "ofono: (%s): IPv4 static Settings:", nm_modem_get_uid (NM_MODEM (self))); | ||
1210 | 118 | - | ||
1211 | 119 | if (g_variant_lookup (v_dict, "Interface", "&s", &s)) { | ||
1212 | 120 | |||
1213 | 121 | nm_log_dbg (LOGD_MB, "(%s): Interface: %s", nm_modem_get_uid (NM_MODEM (self)), s); | ||
1214 | 122 | @@ -930,8 +911,7 @@ context_property_changed (GDBusProxy *proxy, | ||
1215 | 123 | } | ||
1216 | 124 | |||
1217 | 125 | nm_log_info (LOGD_MB, "ofono (%s) Address: %s/%d", | ||
1218 | 126 | - nm_modem_get_uid (NM_MODEM (self)), addr_s, prefix); | ||
1219 | 127 | - | ||
1220 | 128 | + nm_modem_get_uid (NM_MODEM (self)), addr_s, prefix); | ||
1221 | 129 | nm_ip4_config_add_address (priv->ip4_config, &addr); | ||
1222 | 130 | |||
1223 | 131 | if (g_variant_lookup (v_dict, "Gateway", "&s", &s)) { | ||
1224 | 132 | @@ -972,7 +952,7 @@ context_property_changed (GDBusProxy *proxy, | ||
1225 | 133 | |||
1226 | 134 | if (iter == array) { | ||
1227 | 135 | nm_log_warn (LOGD_MB, "ofono: (%s): Settings: 'DomainNameServers': none specified", | ||
1228 | 136 | - nm_modem_get_uid (NM_MODEM (self))); | ||
1229 | 137 | + nm_modem_get_uid (NM_MODEM (self))); | ||
1230 | 138 | g_free (array); | ||
1231 | 139 | goto out; | ||
1232 | 140 | } | ||
1233 | 141 | @@ -1009,7 +989,7 @@ context_property_changed (GDBusProxy *proxy, | ||
1234 | 142 | out: | ||
1235 | 143 | if (nm_modem_get_state (NM_MODEM (self)) != NM_MODEM_STATE_CONNECTED) { | ||
1236 | 144 | nm_log_info (LOGD_MB, "ofono: (%s): emitting PREPARE_RESULT: %s", | ||
1237 | 145 | - nm_modem_get_uid (NM_MODEM (self)), ret ? "TRUE" : "FALSE"); | ||
1238 | 146 | + nm_modem_get_uid (NM_MODEM (self)), ret ? "TRUE" : "FALSE"); | ||
1239 | 147 | |||
1240 | 148 | if (!ret) | ||
1241 | 149 | reason = NM_DEVICE_STATE_REASON_IP_CONFIG_UNAVAILABLE; | ||
1242 | 150 | @@ -1022,6 +1002,33 @@ out: | ||
1243 | 151 | } | ||
1244 | 152 | } | ||
1245 | 153 | |||
1246 | 154 | +static void | ||
1247 | 155 | +context_property_changed (GDBusProxy *proxy, | ||
1248 | 156 | + const char *property, | ||
1249 | 157 | + GVariant *v, | ||
1250 | 158 | + gpointer user_data) | ||
1251 | 159 | +{ | ||
1252 | 160 | + NMModemOfono *self = NM_MODEM_OFONO (user_data); | ||
1253 | 161 | + GVariant *v_dict; | ||
1254 | 162 | + | ||
1255 | 163 | + nm_log_dbg (LOGD_MB, "PropertyChanged: %s", property); | ||
1256 | 164 | + | ||
1257 | 165 | + if (g_strcmp0 (property, "Settings") != 0) | ||
1258 | 166 | + return; | ||
1259 | 167 | + | ||
1260 | 168 | + v_dict = g_variant_get_child_value (v, 0); | ||
1261 | 169 | + if (!v_dict) { | ||
1262 | 170 | + nm_log_warn (LOGD_MB, "ofono: (%s): error getting IPv4 Settings", | ||
1263 | 171 | + nm_modem_get_uid (NM_MODEM (self))); | ||
1264 | 172 | + return; | ||
1265 | 173 | + } | ||
1266 | 174 | + | ||
1267 | 175 | + g_assert (g_variant_is_of_type (v_dict, G_VARIANT_TYPE_VARDICT)); | ||
1268 | 176 | + | ||
1269 | 177 | + handle_settings (v_dict, user_data); | ||
1270 | 178 | + g_variant_unref (v_dict); | ||
1271 | 179 | +} | ||
1272 | 180 | + | ||
1273 | 181 | static NMActStageReturn | ||
1274 | 182 | static_stage3_ip4_config_start (NMModem *_self, | ||
1275 | 183 | NMActRequest *req, | ||
1276 | 184 | @@ -1053,11 +1060,100 @@ static_stage3_ip4_config_start (NMModem *_self, | ||
1277 | 185 | } | ||
1278 | 186 | |||
1279 | 187 | static void | ||
1280 | 188 | +context_properties_cb (GDBusProxy *proxy, GAsyncResult *result, gpointer user_data) | ||
1281 | 189 | +{ | ||
1282 | 190 | + NMModemOfono *self = NM_MODEM_OFONO (user_data); | ||
1283 | 191 | + NMModemOfonoPrivate *priv = NM_MODEM_OFONO_GET_PRIVATE (self); | ||
1284 | 192 | + GError *error = NULL; | ||
1285 | 193 | + GVariant *properties, *settings; | ||
1286 | 194 | + GVariant *v_dict = NULL; | ||
1287 | 195 | + gboolean active; | ||
1288 | 196 | + | ||
1289 | 197 | + nm_log_dbg (LOGD_MB, "in %s", __func__); | ||
1290 | 198 | + | ||
1291 | 199 | + properties = g_dbus_proxy_call_finish (proxy, result, &error); | ||
1292 | 200 | + | ||
1293 | 201 | + if (error) { | ||
1294 | 202 | + nm_log_warn (LOGD_MB, "ofono: connection failed; couldn't read context properties (%d) %s", | ||
1295 | 203 | + error ? error->code : -1, | ||
1296 | 204 | + error && error->message ? error->message : "(unknown)"); | ||
1297 | 205 | + | ||
1298 | 206 | + g_clear_error (&error); | ||
1299 | 207 | + goto error; | ||
1300 | 208 | + } | ||
1301 | 209 | + | ||
1302 | 210 | + if (properties == NULL) { | ||
1303 | 211 | + nm_log_warn (LOGD_MB, "ofono: connection failed; no context properties returned"); | ||
1304 | 212 | + goto error; | ||
1305 | 213 | + } | ||
1306 | 214 | + | ||
1307 | 215 | + v_dict = g_variant_get_child_value (properties, 0); | ||
1308 | 216 | + g_assert (v_dict); | ||
1309 | 217 | + g_assert (g_variant_is_of_type (v_dict, G_VARIANT_TYPE_VARDICT)); | ||
1310 | 218 | + | ||
1311 | 219 | + g_variant_unref (properties); | ||
1312 | 220 | + | ||
1313 | 221 | + if (!g_variant_lookup (v_dict, "Active", "b", &active)) { | ||
1314 | 222 | + nm_log_warn (LOGD_MB, "ofono: connection failed; can't read 'Active' property"); | ||
1315 | 223 | + goto error; | ||
1316 | 224 | + } | ||
1317 | 225 | + | ||
1318 | 226 | + /* Watch for custom ofono PropertyChanged signals */ | ||
1319 | 227 | + _nm_dbus_signal_connect (priv->context_proxy, | ||
1320 | 228 | + "PropertyChanged", | ||
1321 | 229 | + G_VARIANT_TYPE ("(sv)"), | ||
1322 | 230 | + G_CALLBACK (context_property_changed), | ||
1323 | 231 | + self); | ||
1324 | 232 | + | ||
1325 | 233 | + if (active) { | ||
1326 | 234 | + nm_log_dbg (LOGD_MB, "connection is already Active"); | ||
1327 | 235 | + | ||
1328 | 236 | + settings = g_variant_lookup_value (v_dict, "Settings", G_VARIANT_TYPE_VARDICT); | ||
1329 | 237 | + if (settings == NULL) { | ||
1330 | 238 | + nm_log_warn (LOGD_MB, "ofono: connection failed; can't read 'Settings' property"); | ||
1331 | 239 | + goto error; | ||
1332 | 240 | + } | ||
1333 | 241 | + | ||
1334 | 242 | + handle_settings (settings, user_data); | ||
1335 | 243 | + g_variant_unref (settings); | ||
1336 | 244 | + | ||
1337 | 245 | + } else | ||
1338 | 246 | + g_dbus_proxy_call (priv->context_proxy, | ||
1339 | 247 | + "SetProperty", | ||
1340 | 248 | + g_variant_new ("(sv)", | ||
1341 | 249 | + "Active", | ||
1342 | 250 | + g_variant_new ("b", TRUE)), | ||
1343 | 251 | + G_DBUS_CALL_FLAGS_NONE, | ||
1344 | 252 | + 20000, | ||
1345 | 253 | + NULL, | ||
1346 | 254 | + (GAsyncReadyCallback) stage1_prepare_done, | ||
1347 | 255 | + g_object_ref (self)); | ||
1348 | 256 | + | ||
1349 | 257 | + g_variant_unref (v_dict); | ||
1350 | 258 | + | ||
1351 | 259 | + return; | ||
1352 | 260 | + | ||
1353 | 261 | +error: | ||
1354 | 262 | + if (properties) | ||
1355 | 263 | + g_variant_unref (properties); | ||
1356 | 264 | + | ||
1357 | 265 | + if (v_dict) | ||
1358 | 266 | + g_variant_unref (v_dict); | ||
1359 | 267 | + | ||
1360 | 268 | + g_signal_emit_by_name (self, NM_MODEM_PREPARE_RESULT, FALSE, | ||
1361 | 269 | + NM_DEVICE_STATE_REASON_MODEM_BUSY); | ||
1362 | 270 | +} | ||
1363 | 271 | + | ||
1364 | 272 | +static void | ||
1365 | 273 | context_proxy_new_cb (GDBusProxy *proxy, GAsyncResult *result, gpointer user_data) | ||
1366 | 274 | { | ||
1367 | 275 | NMModemOfono *self = NM_MODEM_OFONO (user_data); | ||
1368 | 276 | NMModemOfonoPrivate *priv = NM_MODEM_OFONO_GET_PRIVATE (self); | ||
1369 | 277 | + gboolean context_active; | ||
1370 | 278 | GError *error = NULL; | ||
1371 | 279 | + GVariant *v_dict; | ||
1372 | 280 | + GVariant *active_property; | ||
1373 | 281 | + GVariant *settings_property; | ||
1374 | 282 | |||
1375 | 283 | nm_log_dbg (LOGD_MB, "%s:", __func__); | ||
1376 | 284 | |||
1377 | 285 | @@ -1087,23 +1183,18 @@ context_proxy_new_cb (GDBusProxy *proxy, GAsyncResult *result, gpointer user_dat | ||
1378 | 286 | if (priv->ip4_config) | ||
1379 | 287 | g_clear_object (&priv->ip4_config); | ||
1380 | 288 | |||
1381 | 289 | - /* Watch for custom ofono PropertyChanged signals */ | ||
1382 | 290 | - _nm_dbus_signal_connect (priv->context_proxy, | ||
1383 | 291 | - "PropertyChanged", | ||
1384 | 292 | - G_VARIANT_TYPE ("(sv)"), | ||
1385 | 293 | - G_CALLBACK (context_property_changed), | ||
1386 | 294 | - self); | ||
1387 | 295 | - | ||
1388 | 296 | + /* As ofono doesn't properly implement DBus.Properties, we need to | ||
1389 | 297 | + * query the ConnectionContextinteface directly to get the current | ||
1390 | 298 | + * property values vs. using g_dbus_proxy_get_cached_property. | ||
1391 | 299 | + */ | ||
1392 | 300 | g_dbus_proxy_call (priv->context_proxy, | ||
1393 | 301 | - "SetProperty", | ||
1394 | 302 | - g_variant_new ("(sv)", | ||
1395 | 303 | - "Active", | ||
1396 | 304 | - g_variant_new ("b", TRUE)), | ||
1397 | 305 | - G_DBUS_CALL_FLAGS_NONE, | ||
1398 | 306 | - 20000, | ||
1399 | 307 | - NULL, | ||
1400 | 308 | - (GAsyncReadyCallback) stage1_prepare_done, | ||
1401 | 309 | - g_object_ref (self)); | ||
1402 | 310 | + "GetProperties", | ||
1403 | 311 | + NULL, | ||
1404 | 312 | + G_DBUS_CALL_FLAGS_NONE, | ||
1405 | 313 | + 20000, | ||
1406 | 314 | + NULL, | ||
1407 | 315 | + (GAsyncReadyCallback) context_properties_cb, | ||
1408 | 316 | + g_object_ref (self)); | ||
1409 | 317 | } | ||
1410 | 318 | |||
1411 | 319 | static void | ||
1412 | 320 | @@ -1112,8 +1203,8 @@ do_context_activate (NMModemOfono *self) | ||
1413 | 321 | NMModemOfonoPrivate *priv = NM_MODEM_OFONO_GET_PRIVATE (self); | ||
1414 | 322 | GValue value = G_VALUE_INIT; | ||
1415 | 323 | |||
1416 | 324 | - g_return_val_if_fail (self != NULL, FALSE); | ||
1417 | 325 | - g_return_val_if_fail (NM_IS_MODEM_OFONO (self), FALSE); | ||
1418 | 326 | + g_assert (self != NULL); | ||
1419 | 327 | + g_assert (NM_IS_MODEM_OFONO (self)); | ||
1420 | 328 | |||
1421 | 329 | nm_log_dbg (LOGD_MB, "in %s", __func__); | ||
1422 | 330 | |||
1423 | 331 | diff --git a/src/devices/wwan/nm-modem-ofono.h b/src/devices/wwan/nm-modem-ofono.h | ||
1424 | 332 | index fa79e15..02eca11 100644 | ||
1425 | 333 | --- a/src/devices/wwan/nm-modem-ofono.h | ||
1426 | 334 | +++ b/src/devices/wwan/nm-modem-ofono.h | ||
1427 | 335 | @@ -41,6 +41,8 @@ G_BEGIN_DECLS | ||
1428 | 336 | #define OFONO_DBUS_INTERFACE_CONNECTION_CONTEXT "org.ofono.ConnectionContext" | ||
1429 | 337 | #define OFONO_DBUS_INTERFACE_SIM_MANAGER "org.ofono.SimManager" | ||
1430 | 338 | |||
1431 | 339 | +#define OFONO_ERROR_IN_PROGRESS "org.ofono.Error.InProgress" | ||
1432 | 340 | + | ||
1433 | 341 | typedef enum { | ||
1434 | 342 | NM_OFONO_ERROR_CONNECTION_NOT_OFONO = 0, /*< nick=ConnectionNotOfono >*/ | ||
1435 | 343 | NM_OFONO_ERROR_CONNECTION_INVALID, /*< nick=ConnectionInvalid >*/ | ||
1436 | diff --git a/debian/rules b/debian/rules | |||
1437 | index 2e449a4..801508c 100755 | |||
1438 | --- a/debian/rules | |||
1439 | +++ b/debian/rules | |||
1440 | @@ -2,11 +2,24 @@ | |||
1441 | 2 | 2 | ||
1442 | 3 | include /usr/share/dpkg/architecture.mk | 3 | include /usr/share/dpkg/architecture.mk |
1443 | 4 | 4 | ||
1445 | 5 | PPPD_PLUGIN_DIR := $(shell dh_ppp --plugin-dir) | 5 | # The following line is used by 1.2x desktop, but doesn't |
1446 | 6 | # work on vivid or wily, preventing a source package from | ||
1447 | 7 | # being built on this releases. This is because ppp 2.4.6-3* | ||
1448 | 8 | # doesn't include dh_ppp. | ||
1449 | 9 | # | ||
1450 | 10 | # PPPD_PLUGIN_DIR := $(shell dh_ppp --plugin-dir) | ||
1451 | 6 | DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) | 11 | DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) |
1452 | 7 | 12 | ||
1453 | 8 | %: | 13 | %: |
1455 | 9 | dh $@ --with gir,systemd,autoreconf,ppp --parallel | 14 | # This is from the 1.2x desktop branch; ppp fails due to lack of |
1456 | 15 | # dh_ppp ( see above ). This is a no-op until we fix pptp VPN | ||
1457 | 16 | # on the phone. gir fails when building the binary packages with | ||
1458 | 17 | # the error: | ||
1459 | 18 | # | ||
1460 | 19 | # dh_girepository: Could not find gir file for NM-1.0.typelib | ||
1461 | 20 | # | ||
1462 | 21 | # dh $@ --with gir,systemd,autoreconf,ppp --parallel | ||
1463 | 22 | dh $@ --with systemd,autoreconf --parallel | ||
1464 | 10 | 23 | ||
1465 | 11 | autoreconf: | 24 | autoreconf: |
1466 | 12 | gtkdocize --copy | 25 | gtkdocize --copy |
1467 | @@ -19,14 +32,13 @@ override_dh_autoreconf: | |||
1468 | 19 | override_dh_auto_configure: | 32 | override_dh_auto_configure: |
1469 | 20 | dh_auto_configure -- \ | 33 | dh_auto_configure -- \ |
1470 | 21 | --libexecdir=/usr/lib/NetworkManager \ | 34 | --libexecdir=/usr/lib/NetworkManager \ |
1471 | 22 | --with-pppd-plugin-dir=$(PPPD_PLUGIN_DIR) \ | ||
1472 | 23 | --with-pppd=/usr/sbin/pppd \ | ||
1473 | 24 | --with-resolvconf=/sbin/resolvconf \ | 35 | --with-resolvconf=/sbin/resolvconf \ |
1474 | 25 | --with-dhclient=/sbin/dhclient \ | 36 | --with-dhclient=/sbin/dhclient \ |
1475 | 26 | --with-iptables=/sbin/iptables \ | 37 | --with-iptables=/sbin/iptables \ |
1476 | 27 | --with-dnsmasq=/usr/sbin/dnsmasq \ | 38 | --with-dnsmasq=/usr/sbin/dnsmasq \ |
1477 | 28 | --with-dnssec-trigger=/usr/lib/dnssec-trigger/dnssec-trigger-script \ | 39 | --with-dnssec-trigger=/usr/lib/dnssec-trigger/dnssec-trigger-script \ |
1478 | 29 | --with-systemdsystemunitdir=/lib/systemd/system \ | 40 | --with-systemdsystemunitdir=/lib/systemd/system \ |
1479 | 41 | --with-systemd-journal=no \ | ||
1480 | 30 | --with-udev-dir=/lib/udev \ | 42 | --with-udev-dir=/lib/udev \ |
1481 | 31 | --with-crypto=gnutls \ | 43 | --with-crypto=gnutls \ |
1482 | 32 | --with-session-tracking=systemd \ | 44 | --with-session-tracking=systemd \ |
1483 | @@ -36,9 +48,9 @@ override_dh_auto_configure: | |||
1484 | 36 | --with-nmcli \ | 48 | --with-nmcli \ |
1485 | 37 | --disable-more-warnings \ | 49 | --disable-more-warnings \ |
1486 | 38 | --disable-modify-system \ | 50 | --disable-modify-system \ |
1487 | 51 | --disable-bluez5 \ | ||
1488 | 39 | --enable-polkit \ | 52 | --enable-polkit \ |
1489 | 40 | --enable-polkit-agent \ | 53 | --enable-polkit-agent \ |
1490 | 41 | --enable-ppp \ | ||
1491 | 42 | --enable-ifupdown \ | 54 | --enable-ifupdown \ |
1492 | 43 | --enable-config-plugin-ibft \ | 55 | --enable-config-plugin-ibft \ |
1493 | 44 | --enable-introspection \ | 56 | --enable-introspection \ |
1494 | @@ -46,8 +58,7 @@ override_dh_auto_configure: | |||
1495 | 46 | --enable-concheck \ | 58 | --enable-concheck \ |
1496 | 47 | --enable-teamdctl=no \ | 59 | --enable-teamdctl=no \ |
1497 | 48 | --enable-vala \ | 60 | --enable-vala \ |
1500 | 49 | --with-tests \ | 61 | --with-tests |
1499 | 50 | --enable-bluez5-dun | ||
1501 | 51 | 62 | ||
1502 | 52 | override_dh_install: | 63 | override_dh_install: |
1503 | 53 | rm -vf $(CURDIR)/debian/tmp/etc/init.d/NetworkManager | 64 | rm -vf $(CURDIR)/debian/tmp/etc/init.d/NetworkManager |
1504 | @@ -60,6 +71,15 @@ override_dh_install: | |||
1505 | 60 | mkdir -p debian/network-manager/etc/dnsmasq.d | 71 | mkdir -p debian/network-manager/etc/dnsmasq.d |
1506 | 61 | cp debian/network-manager.dnsmasq debian/network-manager/etc/dnsmasq.d/network-manager | 72 | cp debian/network-manager.dnsmasq debian/network-manager/etc/dnsmasq.d/network-manager |
1507 | 62 | 73 | ||
1508 | 74 | # copy indicator-network polkit configuration | ||
1509 | 75 | mkdir -p debian/network-manager/etc/polkit-1/localauthority/50-local.d | ||
1510 | 76 | cp debian/indicator-network.pkla \ | ||
1511 | 77 | debian/network-manager/etc/polkit-1/localauthority/50-local.d/org.freedesktop.NetworkManager.pkla | ||
1512 | 78 | |||
1513 | 79 | # copy powersave configuration | ||
1514 | 80 | mkdir -p debian/network-manager/etc/NetworkManager/conf.d | ||
1515 | 81 | cp debian/default-wifi-powersave-on.conf debian/network-manager/etc/NetworkManager/conf.d/ | ||
1516 | 82 | |||
1517 | 63 | override_dh_installinit: | 83 | override_dh_installinit: |
1518 | 64 | dh_installinit --noscripts | 84 | dh_installinit --noscripts |
1519 | 65 | 85 | ||
1520 | @@ -67,7 +87,7 @@ override_dh_makeshlibs: | |||
1521 | 67 | dh_makeshlibs -X/usr/lib/$(DEB_HOST_MULTIARCH)/NetworkManager/ -X/usr/lib/pppd/ | 87 | dh_makeshlibs -X/usr/lib/$(DEB_HOST_MULTIARCH)/NetworkManager/ -X/usr/lib/pppd/ |
1522 | 68 | 88 | ||
1523 | 69 | override_dh_strip: | 89 | override_dh_strip: |
1525 | 70 | dh_strip --dbgsym-migration='network-manager-dbg (<< 1.1.91-2~)' | 90 | dh_strip --dbg-package=network-manager-dbg |
1526 | 71 | 91 | ||
1527 | 72 | override_dh_systemd_start: | 92 | override_dh_systemd_start: |
1528 | 73 | dh_link lib/systemd/system/NetworkManager.service \ | 93 | dh_link lib/systemd/system/NetworkManager.service \ |
1529 | @@ -76,9 +96,6 @@ override_dh_systemd_start: | |||
1530 | 76 | dh_systemd_start -pnetwork-manager --no-start NetworkManager-wait-online.service | 96 | dh_systemd_start -pnetwork-manager --no-start NetworkManager-wait-online.service |
1531 | 77 | dh_systemd_start -pnetwork-manager --restart-after-upgrade NetworkManager.service | 97 | dh_systemd_start -pnetwork-manager --restart-after-upgrade NetworkManager.service |
1532 | 78 | 98 | ||
1533 | 79 | override_dh_ppp: | ||
1534 | 80 | dh_ppp --breaks | ||
1535 | 81 | |||
1536 | 82 | override_dh_auto_test: | 99 | override_dh_auto_test: |
1537 | 83 | ifeq (, $(filter nocheck, $(DEB_BUILD_OPTIONS))) | 100 | ifeq (, $(filter nocheck, $(DEB_BUILD_OPTIONS))) |
1538 | 84 | make check || ( find . -name test-suite.log -exec cat {} \;; exit 1; ) | 101 | make check || ( find . -name test-suite.log -exec cat {} \;; exit 1; ) |
LGTM