Commit Graph

2499 Commits

Author SHA1 Message Date
Robert Greenwalt
39e1340649 am 33868dab: am 4dcacef5: Merge "Fix timing between bcast and net setup." into lmp-mr1-dev
automerge: 8ed2ad1

* commit '8ed2ad1c504137f045ba2d9c7172441dff346b79':
  Fix timing between bcast and net setup.
2014-12-26 20:36:43 +00:00
Robert Greenwalt
8ed2ad1c50 am 33868dab: am 4dcacef5: Merge "Fix timing between bcast and net setup." into lmp-mr1-dev
* commit '33868dab9af09d61634f1f7ab3a8c704aacd0de0':
  Fix timing between bcast and net setup.
2014-12-26 20:30:32 +00:00
The Android Automerger
0a38542bca merge in master-release history after reset to master 2014-12-20 05:52:06 -08:00
Robert Greenwalt
70116ce13c Fix timing between bcast and net setup.
A legacy network type request would generate a bcast before the network
notification was sent - the legacy startUsingNetworkFeature API requires
the notification so it can bind your dns queries to the new network.
Fast-moving clients could try to use the network before it was ready.

bug:18792871
Change-Id: I24c46ef15c249c50bfc321f62756d1f66dc3a6a9
2014-12-19 11:54:27 -08:00
Lorenzo Colitti
dcbc8811af am 7e81cdef: am 5f82daec: Add a lastValidated bit and use it when reporting capabilities.
automerge: 71860bbb

* commit '71860bbba756c618e0c8e19191b6d829e51d7f0a':
  Add a lastValidated bit and use it when reporting capabilities.
2014-12-19 10:51:18 +00:00
Lorenzo Colitti
5b4d1d0332 am b069e434: am a8de5ca5: Rename validated to everValidated.
automerge: aa48e8f

* commit 'aa48e8f77e24346afa0d8212e7fed91d4c8710c4':
  Rename validated to everValidated.
2014-12-19 10:49:24 +00:00
Lorenzo Colitti
71860bbba7 am 7e81cdef: am 5f82daec: Add a lastValidated bit and use it when reporting capabilities.
* commit '7e81cdef3625b52642969dd226a1446745e633e8':
  Add a lastValidated bit and use it when reporting capabilities.
2014-12-19 10:47:26 +00:00
Lorenzo Colitti
aa48e8f77e am b069e434: am a8de5ca5: Rename validated to everValidated.
* commit 'b069e434cba6dd8f949c3ebe44507da32aef3496':
  Rename validated to everValidated.
2014-12-19 10:47:20 +00:00
Lorenzo Colitti
5f82daecad Add a lastValidated bit and use it when reporting capabilities.
When we switched the way the status bar determines if a
connection is validated from using INET_CONDITION_ACTION
broadcasts to calling getDefaultNetworkCapabilitiesForUser(),
the statusbar stopped displaying ! when a network stopped having
working Internet connectivity. This is because the validated bit
is never set to false once a network is validated.

Fix this, hopefully temporarily, by introducing a new validated
bit that does go back to being false when a network no longer
has working connectivity, and use that bit in
getDefaultNetworkCapabilitiesForUser().

Bug: 18777225
Change-Id: I991c068be50252391d0e64c647fcf2e053dc82f9
2014-12-19 19:10:42 +09:00
Lorenzo Colitti
a8de5ca5cc Rename validated to everValidated.
This is a straight rename and thus a complete no-op from a
functionality perspective.

Bug: 18777225
Change-Id: I140d7640f1460c869a311294873772819a7a7059
2014-12-19 19:10:42 +09:00
The Android Automerger
2a0ff61095 merge in master-release history after reset to master 2014-12-18 05:54:06 -08:00
Paul Jensen
9edd2acd0a am 32b6f2aa: am 24594794: am b0575a24: Merge "Fix race between CONNECTIVITY_ACTION and setting default network." into lmp-mr1-dev
* commit '32b6f2aa5f2ac1a0bf1e360cd3006e745ccdca92':
  Fix race between CONNECTIVITY_ACTION and setting default network.
2014-12-17 13:11:21 +00:00
Paul Jensen
32b6f2aa5f am 24594794: am b0575a24: Merge "Fix race between CONNECTIVITY_ACTION and setting default network." into lmp-mr1-dev
* commit '24594794cbb9bf6bb9c8b57e4427c88efee82304':
  Fix race between CONNECTIVITY_ACTION and setting default network.
2014-12-17 13:05:39 +00:00
Paul Jensen
0353fe5d99 Fix race between CONNECTIVITY_ACTION and setting default network.
Now that the delay between connectivity changes and CONNECTIVITY_ACTION
has been removed (ag/599650) races between CONNECTIVITY_ACTION and
the setting of the default network become more evident.
In http://crbug.com/441818 Chrome is calling getaddrinfo()
immediately after a device goes from no connectivity to cellular
connectivity, and Chrome is erroneously getting back EAI_NODATA
because netd hasn't yet set the default network for DNS resolutions.

bug:18757162
Change-Id: Ib607dcb3697403272a8c838713a9cb602e9c6820
2014-12-15 15:20:30 -05:00
The Android Automerger
463ae8d360 merge in master-release history after reset to master 2014-12-11 05:56:35 -08:00
Paul Jensen
62911488e9 am 7a0d9799: Merge "Fix several HTTP proxy issues with multinetworking." into lmp-mr1-dev automerge: d9d48cc
automerge: d6524c4

* commit 'd6524c4eb5034187bf03bf04e453499df32e3b08':
  Fix several HTTP proxy issues with multinetworking.
2014-12-11 10:25:47 +00:00
Paul Jensen
d6524c4eb5 am 7a0d9799: Merge "Fix several HTTP proxy issues with multinetworking." into lmp-mr1-dev
automerge: d9d48cc

* commit 'd9d48cc9c7ab0d1590918e199917968eafc48288':
  Fix several HTTP proxy issues with multinetworking.
2014-12-11 05:49:18 +00:00
Paul Jensen
7a0d9799c8 Merge "Fix several HTTP proxy issues with multinetworking." into lmp-mr1-dev 2014-12-11 04:51:16 +00:00
Qiwen Zhao
54e0c99fe8 Initial empty repository 2014-12-10 14:10:18 -08:00
Erik Kline
334d819b68 am e1bf37a8: am 63aba09c: Merge "Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions." into lmp-mr1-dev automerge: 56d2e8f
* commit 'e1bf37a85ee954c269bee2253b8e2a70fbd8e03e':
  Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions.
2014-12-10 21:58:42 +00:00
Paul Jensen
c0618a69f1 Fix several HTTP proxy issues with multinetworking.
1. Send PROXY_CHANGE_ACTION broadcast when any network's proxy changes,
   not just the default network.
2. When a process is bound to a particular Network, update the proxy
   system properties to those for the bound Network, and keep them
   updated when PROXY_CHANGE_ACTION broadcasts are received.
3. Make Network.openConnection() use the proxy for the Network.

bug:17905627
bug:17420465
bug:18144582

(cherry-pick of https://android-review.googlesource.com/#/c/115170)

Change-Id: Ia2819985e6108a8c121e74c683a5646becfd0a97
2014-12-10 15:22:12 -05:00
Erik Kline
e1bf37a85e am 63aba09c: Merge "Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions." into lmp-mr1-dev
automerge: 56d2e8f

* commit '56d2e8fb7b2ab6e32efea59604eb0cd72745df1b':
  Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions.
2014-12-10 19:06:50 +00:00
The Android Automerger
0f228ee833 merge in master-release history after reset to master 2014-12-10 05:55:41 -08:00
Erik Kline
63aba09c17 Merge "Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions." into lmp-mr1-dev 2014-12-10 07:29:47 +00:00
Wink Saville
e135d0f2a2 am 4d9749fd: am 2f5cb843: am 6490d869: Merge "Add subId as parameter for get/setDataEnabled." into lmp-mr1-dev
* commit '4d9749fd5d2852bb17c7c3b19df03a8c9e061593':
  Add subId as parameter for get/setDataEnabled.
2014-12-09 23:47:19 +00:00
Jeff Sharkey
06abd9c5cb am 86af3b60: am 2f1e953f: am 4df65bf1: Merge "Direct notification of network interface changes." into lmp-mr1-dev
* commit '86af3b6061b8a8f08a449cc126c5d181bfe2de0b':
  Direct notification of network interface changes.
2014-12-09 23:20:26 +00:00
Jeff Sharkey
e273f27053 am 3c18de21: am 5b41696c: am a8fb5803: Merge "Offer to "merge" subscribers for data usage." into lmp-mr1-dev
* commit '3c18de21c76197ad7f16723806d2ce5cf6e30bb8':
  Offer to "merge" subscribers for data usage.
2014-12-09 22:23:19 +00:00
Wink Saville
4d9749fd5d am 2f5cb843: am 6490d869: Merge "Add subId as parameter for get/setDataEnabled." into lmp-mr1-dev
* commit '2f5cb843553a596d314596c2bb776541db864d63':
  Add subId as parameter for get/setDataEnabled.
2014-12-09 18:06:03 +00:00
Wink Saville
6490d8694a Merge "Add subId as parameter for get/setDataEnabled." into lmp-mr1-dev 2014-12-09 17:52:27 +00:00
Jeremy Joslin
f31ad13b77 am a0922b09: am c4b2ec1a: am 6e39f696: Merge "Don\'t send the same PendingIntent more than once." into lmp-mr1-dev
* commit 'a0922b09ee4e6eff12d3b980f2af509d72e9ade3':
  Don't send the same PendingIntent more than once.
2014-12-09 01:00:09 +00:00
Paul Jensen
d1e080eea8 am 8ee62819: am a4afe13a: am 26c6a232: Merge "Reap unvalidated networks that have no chance of becoming highest scoring." into lmp-mr1-dev
* commit '8ee62819bb456d255adcadd16e745804988b4ae1':
  Reap unvalidated networks that have no chance of becoming highest scoring.
2014-12-09 01:00:00 +00:00
Dianne Hackborn
1201a2569c am cfe01d29: am e52a2ea0: am f91526ce: Merge "Fix issue #17323751: Additional items in aggregated battery stats" into lmp-mr1-dev
* commit 'cfe01d29913836d14dc762f0a8d1193b7626010e':
  Fix issue #17323751: Additional items in aggregated battery stats
2014-12-09 00:59:01 +00:00
Pavel Zhamaitsiak
9dc0babd8d am d7d4a9c8: am d89f0d3d: am b81ce34a: Merge "Revert "Merge "Remove CONNECTIVITY_CHANGE_DELAY and friends." into lmp-mr1-dev"" into lmp-mr1-dev
* commit 'd7d4a9c81199dbdcfc0dc036d07aea0c3e810096':
  Revert "Merge "Remove CONNECTIVITY_CHANGE_DELAY and friends." into lmp-mr1-dev"
2014-12-09 00:18:39 +00:00
Jeff Sharkey
86af3b6061 am 2f1e953f: am 4df65bf1: Merge "Direct notification of network interface changes." into lmp-mr1-dev
* commit '2f1e953f8fd6d7ee32c00a680f887607f1005f62':
  Direct notification of network interface changes.
2014-12-09 00:18:01 +00:00
Jeff Sharkey
aa6ff6c7b0 Direct notification of network interface changes.
Connectivity broadcasts recently changed and are no longer sent for
certain types of network changes.  For example, when stacked network
interfaces change for a mobile network.  To ensure that we pick up
all these details, directly wire the two services together.

Also remove some unused code for split network types.

Bug: 18666753
Change-Id: I0467bd5b330c0e0cb51af2306d821b41ad16337a
2014-12-08 14:50:14 -08:00
Jeff Sharkey
3c18de21c7 am 5b41696c: am a8fb5803: Merge "Offer to "merge" subscribers for data usage." into lmp-mr1-dev
* commit '5b41696c56c124124d48168227a83b63bd55aea7':
  Offer to "merge" subscribers for data usage.
2014-12-08 19:44:27 +00:00
Jeremy Joslin
a0922b09ee am c4b2ec1a: am 6e39f696: Merge "Don\'t send the same PendingIntent more than once." into lmp-mr1-dev
* commit 'c4b2ec1a3a808c2dae0894e5f0cfd43d6ec1d5a2':
  Don't send the same PendingIntent more than once.
2014-12-08 19:36:27 +00:00
Paul Jensen
8ee62819bb am a4afe13a: am 26c6a232: Merge "Reap unvalidated networks that have no chance of becoming highest scoring." into lmp-mr1-dev
* commit 'a4afe13af38c03ae6abb76d2cf36ae0672328fd8':
  Reap unvalidated networks that have no chance of becoming highest scoring.
2014-12-08 19:36:08 +00:00
Dianne Hackborn
cfe01d2991 am e52a2ea0: am f91526ce: Merge "Fix issue #17323751: Additional items in aggregated battery stats" into lmp-mr1-dev
* commit 'e52a2ea03bd7b8ed2f3680c5198e00fb7ad5c34c':
  Fix issue #17323751: Additional items in aggregated battery stats
2014-12-08 19:33:49 +00:00
Pavel Zhamaitsiak
d7d4a9c811 am d89f0d3d: am b81ce34a: Merge "Revert "Merge "Remove CONNECTIVITY_CHANGE_DELAY and friends." into lmp-mr1-dev"" into lmp-mr1-dev
* commit 'd89f0d3d54dec1662b1cfed6c8e574ffcc8032d9':
  Revert "Merge "Remove CONNECTIVITY_CHANGE_DELAY and friends." into lmp-mr1-dev"
2014-12-08 19:16:43 +00:00
Jeff Sharkey
fffa983fe4 Offer to "merge" subscribers for data usage.
There are some cases where multiple subscriber identities (IMSI)
should be treated as "merged together" from a data usage
perspective.  This is done by extending the template used for
matching purposes to support multiple subscribers.

Then, when we query historical usage or set network policies, we
normalize the matching template to merge to any other identities
that should be included.  When normalizing, the "lowest" identity
is always used for equality and storage purposes, which allows
identities to come and go over time.

This change also fixes data usage recording for multi-SIM devices
by passing along the concrete subscriber identity for each network
interface.  Also correctly create default policies for multi-SIM
devices.  This change also drops setPolicyDataEnable() until it can
be wired up to the right underlying NetworkAgent.  (This means we
still bring up the network, and then rely on iptables rules to block
traffic when over the limit, instead of proactively disabling the
connection.)

Bug: 18012787
Change-Id: If6acf32009fdfea2b836f5aff8e2f3e5e0248b4a
2014-12-08 08:42:59 -08:00
Erik Kline
b883659514 Re-remove CONNECTIVITY_CHANGE_DELAY and supporting functions.
Since optimistic addresses are useable upon kernel notification
there is no need for this extra connectivity delay.

---

This functionality was originally submitted in ag/572619.  Owing
to issues with bind()ing to optimistic addresses (see b/18609055)
this was reverted in ag/598673.

This reverts the revert.  :-)

Bug: 17769720
Change-Id: Ibee490b2af72050693b6bd748193f51e312ca527
2014-12-08 16:25:20 +09:00
The Android Automerger
74c78a3aa0 merge in master-release history after reset to master 2014-12-06 05:53:44 -08:00
Jeremy Joslin
6e39f696b7 Merge "Don't send the same PendingIntent more than once." into lmp-mr1-dev 2014-12-06 02:05:22 +00:00
Paul Jensen
26c6a232bb Merge "Reap unvalidated networks that have no chance of becoming highest scoring." into lmp-mr1-dev 2014-12-06 01:23:56 +00:00
Jeremy Joslin
1d3acf930f Don't send the same PendingIntent more than once.
Fixing a bug where a NetworkRequest's PendingIntent can be sent more
than once when networks are rematched before the intent completes.

Added a small delay before removing the request to give the receiving
client an opportunity to put in its own request. The delay value is
configurable via Settings.Secure.

Bug: 18614074
Change-Id: Iac7c5e5a04f42f2b6794e9e22349cc631bebeab7
2014-12-05 14:58:04 -08:00
Dianne Hackborn
f91526cec0 Merge "Fix issue #17323751: Additional items in aggregated battery stats" into lmp-mr1-dev 2014-12-05 22:54:08 +00:00
Dianne Hackborn
37e2d0e068 Fix issue #17323751: Additional items in aggregated battery stats
- Now aggregate number of times each process has crashed and ANRed.
- Now aggregate total number of connectivity changes.
- Now record connectivity changes in the history.

Crash and ANR counts are new entries at the end of "pr" in checkin.

Connectivity change counts is a new entry at the end of "m" in checkin.

Connectivity changes in the history checkin are Ecn and include the
type of connection and its state.

Change-Id: I0c01186446034cf6c3fb97d45f5e3b5c69a0438a
2014-12-05 13:54:24 -08:00
Paul Jensen
ff1d0b7938 am f43033a6: am 461e7367: am 1f4d121b: Merge "Remember to cancel lingering when a network again satsifies a NetworkRequest." into lmp-mr1-dev
* commit 'f43033a63edf0828ad987c3e276ed6ed189d3069':
  Remember to cancel lingering when a network again satsifies a NetworkRequest.
2014-12-05 21:19:57 +00:00
Paul Jensen
f43033a63e am 461e7367: am 1f4d121b: Merge "Remember to cancel lingering when a network again satsifies a NetworkRequest." into lmp-mr1-dev
* commit '461e73677d208e4e97356cbc781ce490b90e2027':
  Remember to cancel lingering when a network again satsifies a NetworkRequest.
2014-12-05 20:18:45 +00:00