Commit graph android_packages_modules_Co.../core/java/android
Message SHA1
Merge "Expose MacAddress methods to public API" am: c54645390f am: 623f385dc8 am: d3ace8c221
am: d60dd6fc63

Change-Id: Ie117595096175ddb0affaa36d5f287a533e99eb5

Aaron Huang   authored and   android-build-merger   commited 2019-10-17 21:20:51 -07:00
4fa3e60988
Expose MacAddress methods to public API
To support mainline modules, adding the methods which
are used by wifi.

Bug: 139268426
Bug: 135998869
Bug: 138306002
Test: atest android.net.cts
      atest android.net.wifi.cts
      atest FrameworksNetTests
      atest NetworkStackTests
      ./frameworks/opt/net/wifi/tests/wifitests/runtests.sh

Change-Id: I49856863c15b6b3b59aa867a77b0f137003149ef

Aaron Huang   commited 2019-10-15 17:33:05 +08:00
fd39026749
Merge "Improve documentation for NetworkCallbacks." am: f34bdd0f74 am: a6916097ee am: ef2b0b9f0a
am: c6433e73c6

Change-Id: I9a6eb4841c29e6e6944e3bb6eeb036f8026db4cf

Chalard Jean   authored and   android-build-merger   commited 2019-10-09 23:34:18 -07:00
46d230b03e
Merge "Improve documentation for NetworkCallbacks."
Chalard Jean   authored and   Gerrit Code Review   commited 2019-10-10 05:56:59 +00:00
f34bdd0f74
Improve documentation for NetworkCallbacks.
Bug: 139570489
Test: m doc-comment-check-docs
Change-Id: I9e13057b7e46908863156986429ff2ce93d4be78

Chalard Jean   commited 2019-10-09 18:33:09 +09:00
7f3a8746c3
resolve merge conflicts of 395a0a5e69 to master
Test: I solemnly swear I tested this conflict resolution.
Bug: None
Change-Id: Ia9db1400207d9196012362c480ede059e94184af

Valentin Iftime   commited 2019-10-08 22:21:44 +02:00
e942babfef
API to detect which network interfaces support wake-on-lan
Add a new method in LinkProperties, isWakeOnLanEnabled() which returns
true if network interface is defined in config_wakeonlan_enabled_interfaces
string-array (config.xml)

Bug: 132705025
Test: atest LinkPropertiesTest & atest ConnectivityServiceTest
Change-Id: I3f7803aafd2f8eaf8aa18419b21339e15d4b7a0b

Valentin Iftime   commited 2019-10-08 13:03:30 +02:00
a039e57ead
Merge "Followup to CL 1103896" am: e4713e7f18 am: f59fb89406 am: 08eb639ef6
am: c204fb1f40

Change-Id: I9aec9d7481722e2533200dcab9bc9066142496a1

Oscar Shu   authored and   android-build-merger   commited 2019-09-24 16:06:25 -07:00
089bfd550d
Merge "Followup to CL 1103896"
Oscar Shu   authored and   Gerrit Code Review   commited 2019-09-24 22:06:27 +00:00
e4713e7f18
Followup to CL 1103896
Optimizes the logic that ensures the default randomized MAC is not
returned.

Bug: 137796328
Test: atest MacAddressTest
Change-Id: Ie95d7a020bfac8850b8a67e4d396de77db22e1db

xshu   commited 2019-09-20 16:56:54 -07:00
6aa877983e
Merge "Add missing nullability annotations." into stage-aosp-master
Aurimas Liutikas   authored and   Android (Google) Code Review   commited 2019-08-30 15:19:45 +00:00
7958bb6ac8
Merge "Add missing nullability annotations."
Aurimas Liutikas   authored and   Android (Google) Code Review   commited 2019-08-30 15:14:37 +00:00
772ad4867f
Merge "Run callbacks on ConnectivityService thread" am: 1ef61592b8 am: ab507d4e34 am: bb5e40bc49 am: 49d314a21d
am: 6fb7791309

Change-Id: I382db90c318495244a42a2d4af6e5ebf54f05750

Remi NGUYEN VAN   authored and   android-build-merger   commited 2019-08-30 04:17:08 -07:00
b3899a384d
Merge "Run callbacks on ConnectivityService thread"
am: 1ef61592b8

Change-Id: I7a8d035ec7453c5351eb2646c631c19964cb0f88

Remi NGUYEN VAN   authored and   android-build-merger   commited 2019-08-30 03:36:26 -07:00
ab507d4e34
Add missing nullability annotations.
To prepare for enabling MissingNullability Metalava check this CL
works on adding missing nullability issues that metalava flags if
we tell it to flag new things since API 29.

This is not a complete CL, mostly addresses public api and
toString/equals for @SystemApi

Exempt-From-Owner-Approval: Large scale nullability clean up
Bug: 124515653
Test: make -j checkapi
Change-Id: I109260842cfc25f06e40694997fcbb4afa02c867

Aurimas Liutikas   commited 2019-08-29 17:15:44 -07:00
449a5f69c7
Add missing nullability annotations.
To prepare for enabling MissingNullability Metalava check this CL
works on adding missing nullability issues that metalava flags if
we tell it to flag new things since API 29.

This is not a complete CL, mostly addresses public api and
toString/equals for @SystemApi

Exempt-From-Owner-Approval: Large scale nullability clean up
Bug: 124515653
Test: make -j checkapi
Merged-In: I109260842cfc25f06e40694997fcbb4afa02c867
Change-Id: I109260842cfc25f06e40694997fcbb4afa02c867

Aurimas Liutikas   commited 2019-08-30 00:14:44 +00:00
9242b6de9c
Run callbacks on ConnectivityService thread
Run MultinetworkPolicyTracker and DataConnectionStats callbacks on the
ConnectivityService handler thread.

Previously the callbacks would be using the SystemServer foreground
thread (Looper.myLooper()), or the broadcast thread for the
MultinetworkPolicyTracker BroadcastReceiver. This is error-prone, can
cause threading issues and makes it difficult to test the components.

Test: atest FrameworksNetTests
Change-Id: I189213dd363004abed294659165bf5430d153bba

Remi NGUYEN VAN   commited 2019-08-28 10:10:04 +09:00
6f7ef3f258
Merge "avoid generating reserved local MACs" am: da8955aa2a am: 0ea945e919 am: 4f05f46f13 am: f30d01c91b
am: 83de8f4348

Change-Id: If0fdc7bd46f711714986440a9a905f2ccb154830

Oscar Shu   authored and   android-build-merger   commited 2019-08-24 01:33:53 -07:00
e686dcfd8f
Merge "avoid generating reserved local MACs"
am: da8955aa2a

Change-Id: Ia6d0eb0c5e8101d9c4b4bc63de79157f7d1c2284

Oscar Shu   authored and   android-build-merger   commited 2019-08-23 02:24:15 -07:00
0ea945e919
Merge "avoid generating reserved local MACs"
Oscar Shu   authored and   Gerrit Code Review   commited 2019-08-21 17:45:00 +00:00
da8955aa2a
avoid generating reserved local MACs
Avoid generating WifiInfo.DEFAULT_MAC_ADDRESS as a randomized MAC
address since it's being used for another purpose.

Bug: 137796328
Test: atest MacAddressTest
Change-Id: Ia7beef0d0af5d7b39845e662cd343d81aef97702

xshu   commited 2019-08-16 10:20:22 -07:00
f6ff8b31f0
Merge "Get resource based on subId for multi-SIM" am: 55752cf8d4 am: a784eb71ef am: 2b7f2fbb5b am: 879358bcf2
am: 953f3a62ce

Change-Id: Ief32e4d6376062ba6e86472e39d84681f562980a

Chiachang Wang   authored and   android-build-merger   commited 2019-08-14 05:21:30 -07:00
a3e4f5c790
Merge "Get resource based on subId for multi-SIM"
am: 55752cf8d4

Change-Id: I020c2546fa4432d05cf27b20fdb1943508aac671

Chiachang Wang   authored and   android-build-merger   commited 2019-08-14 04:30:57 -07:00
a784eb71ef
Get resource based on subId for multi-SIM
The resource loading is done based on the last SIM to come up
which is not a deterministic design. Thus, update the way to get
the resource based on the subId.

Test: atest FrameworksNetTests
Test: manually test with avoid bad wifi feature supported sim
Bug: 138956509
Change-Id: Ib5b085d97103889600773d269e03b939c29ca47d

Chiachang Wang   commited 2019-08-14 13:56:37 +08:00
113d65976b
Add @UnsupportedAppUsage annotations for max-p.
See go/UnsupportedAppUsage for more details.

These have already been greylisted, however due to bugs/omissions in the tooling have been kept in go/greylist-txt instead of being annotated in the code.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 137350495
Test: m
Change-Id: I5aa29a49b193db47aaee4d3a756c17f48cc9f0b1

Artur Satayev   commited 2019-08-01 19:46:29 +01:00
4510ea5101
Return NonNull and other imports
Change-Id: Ia38b13209b45d8228ac02f06663e4dc12be9de60

Fedor Kudasov   commited 2019-07-09 14:19:04 +00:00
12ab343b65
Merge changes from topic "fix_master_build"
am: 2e5319117a

Change-Id: If49999e7ce6149e847a678b03ccf8b4549f8365b

Fedor Kudasov   authored and   android-build-merger   commited 2019-07-09 06:10:01 -07:00
2a8415d137
Revert "Cherry-pick the relevant parts of master change"
This reverts commit 667af45299.

Reason for revert: multiple build breakages b/137069068

Change-Id: If48bfa2d2cab0877a053743b3ec53820d0c4ed6b

Fedor Kudasov   authored and   Chalard Jean   commited 2019-07-09 09:29:17 +00:00
5f462af5fa
Revert "Remove providesRoutesToMostDestinations."
This reverts commit 7d1213dd5d.

Reason for revert: multiple build breakages b/137069068

Change-Id: I60a4f71e13fe82f970b177a07c0b58439cbc64ff

Fedor Kudasov   commited 2019-07-09 09:23:25 +00:00
20a09d85cf
Merge changes Ia43f8811,I7de4f672
am: 3ef04b8e3c

Change-Id: Ifcacd81d343a29b17fdb79f4c8b54c89a293a2b8

Chalard Jean   authored and   android-build-merger   commited 2019-07-09 00:56:57 -07:00
9b762d747f
Remove providesRoutesToMostDestinations.
This function is not used any more.

Test: FrameworksNetTests
Change-Id: Ia43f8811cb9d575e16735b0f4b76d91e7cd42ebc

Chalard Jean   commited 2019-07-08 20:36:33 +09:00
7d1213dd5d
Cherry-pick the relevant parts of master change
I566437e4fe10e1346858149120c50b3c20ca073f to avoid a conflict

Test: atest FrameworksNetTests
Change-Id: I7de4f67234bf97d58bddffa22272c7670398f56d

Chalard Jean   commited 2019-07-08 20:25:45 +09:00
667af45299
Merge "Unit tests for new explicitlySelected behaviour." am: d1379a4a80
am: 10c1a704c0

Change-Id: Id77a5d6a58e7ab4fdaa0b7c15b824270863b83fd

Lorenzo Colitti   authored and   android-build-merger   commited 2019-06-29 02:01:55 -07:00
95e816823c
Unit tests for new explicitlySelected behaviour.
ag/7905088 added the ability to pass in acceptUnvalidated without
passing in explicitlySelected. Add unit tests for that code.

While I'm at it, convert a couple of "== 1"s to toBool(), and
update the comments in NetworkAgent.

Bug: 130766237
Test: atest FrameworksNetTests
Change-Id: I6b550bd621e3596975f83464c7b4b8a14269120b

Lorenzo Colitti   commited 2019-06-28 23:57:22 +09:00
d8b7696d4a
Merge "Move the test of minimum supported keepalive slots to CTS" am: 18e3198519
am: 6ff00fee75

Change-Id: Ib9b06d3458782a648a2f5b8fd5a9ca1d34bd11f9

Junyu Lai   authored and   android-build-merger   commited 2019-06-19 07:29:11 -07:00
301bafa22e
Merge "Correct value of supported keepalive count for cellular" am: d20d6e9f1e
am: 056eeae27c

Change-Id: If833b813ba00eeff913160598f1ea9c74e6e35d8

Junyu Lai   authored and   android-build-merger   commited 2019-06-19 07:28:53 -07:00
fca2e7c85c
Merge "Move the test of minimum supported keepalive slots to CTS"
Junyu Lai   authored and   Gerrit Code Review   commited 2019-06-19 14:08:31 +00:00
18e3198519
Merge "Correct value of supported keepalive count for cellular"
Junyu Lai   authored and   Gerrit Code Review   commited 2019-06-19 14:08:31 +00:00
d20d6e9f1e
Move the test of minimum supported keepalive slots to CTS
This change also enables log when keepalive is started.

Bug: 134352656
Test: 1. atest android.net.cts.ConnectivityManagerTest#testSocketKeepaliveLimitTelephony
      2. atest FrameworksNetTests
Change-Id: I408750fa0bceb0c1c26afb5fead4e44fb824fbc1

junyulai   commited 2019-06-19 16:25:19 +08:00
c7fc2f7745
Merge "Remove the <= P restriction for WIFI_P2P" am: ea24a290bd
am: bb754c9c8d

Change-Id: I14f5865249740587d550ac31b59883f4a87fd4a1

Chalard Jean   authored and   android-build-merger   commited 2019-06-17 08:20:18 -07:00
0d00b3cfd2
Remove the <= P restriction for WIFI_P2P
This is still sent in an intent.

Bug: 975059
Change-Id: I56c86b0c1912064d5a642991df32d2cefb6a8d5b

Chalard Jean   commited 2019-06-17 19:46:34 +09:00
6eb4a5893b
Merge "Fix race condition caused by fd reused for DnsResolver" am: ece3a7471c
am: f8a2c15ca1

Change-Id: I93e0d4a8664a16f2814763346ff00e6c874efd02

Luke Huang   authored and   android-build-merger   commited 2019-06-11 08:52:18 -07:00
ac5024452d
Correct value of supported keepalive count for cellular
Cellular only supports 1 keepalive connection so correct the default
supported value to 1.

Bug: 134037217
Test: - atest FrameworksNetTests
      - atest android.net.cts.ConnectivityManagerTest \
        #testSocketKeepaliveLimitTelephony

Change-Id: Ia3761f2e78d54866bb2e156d58004396bbc8adc3

Aaron Huang   commited 2019-06-11 22:04:34 +08:00
59fc443325
Fix race condition caused by fd reused for DnsResolver
There might be a gap between fd close and fd event listener unregister.
If fd is reused for another query during that gap, it might cause the
query failed with no response since addOnFileDescriptorEventListener
method failed. To fix this problem, we must ensure that fd event
listener is unregistered before fd closing.

Bug: 134310704
Test: atest DnsResolverTest
Change-Id: Ifb6bd34dc54dcf1c61fe8b87785124df4bc0f410

Luke Huang   commited 2019-06-11 15:18:28 +08:00
17a68ce4f8
Merge "Allow passing in acceptUnvalidated without explicitlySelected"
Lorenzo Colitti   authored and   Gerrit Code Review   commited 2019-06-05 05:00:14 +00:00
219512edd0
Allow passing in acceptUnvalidated without explicitlySelected
This will allow wifi to tell ConnectivityService that partial
connectivity is acceptable even if the network is not explicitly
selected.

This is needed when the user selects a partial connectivity
network and tells the system to connect to the network, and never
to ask again. In such cases, the system must switch to the
network even if it is not explicitly selected.

Bug: 130766237
Test: atest FrameworksNetTests
Test: unit tests in an upcoming CL
Change-Id: I13465090b7b1c0bf5dc83362387a5428d77b7e1d
Merged-In: I13465090b7b1c0bf5dc83362387a5428d77b7e1d
(cherry picked from commit 9a79a6d41e)

Lorenzo Colitti   commited 2019-06-05 11:12:18 +09:00
72792e2f8f
Merge "Allow passing in acceptUnvalidated without explicitlySelected" into qt-dev
am: f09098bacb

Change-Id: Ifd9dbc9c83e426e66417247cbf1fa594193e000f

Lorenzo Colitti   authored and   android-build-merger   commited 2019-06-04 18:29:51 -07:00
27c3d9c177
Merge "Allow passing in acceptUnvalidated without explicitlySelected" into qt-dev
TreeHugger Robot   authored and   Android (Google) Code Review   commited 2019-06-04 18:00:31 +00:00
f09098bacb
Merge "Fix cannot create Nat-T keepalive on mobile data" into qt-dev
am: eabafd5ceb

Change-Id: I580b4dd2e493430e8420ca0907f9cf7d1d5a8773

junyulai   authored and   android-build-merger   commited 2019-06-04 08:48:21 -07:00
0b8e9b043e
Allow passing in acceptUnvalidated without explicitlySelected
This will allow wifi to tell ConnectivityService that partial
connectivity is acceptable even if the network is not explicitly
selected.

This is needed when the user selects a partial connectivity
network and tells the system to connect to the network, and never
to ask again. In such cases, the system must switch to the
network even if it is not explicitly selected.

Bug: 130766237
Test: atest FrameworksNetTests
Test: unit tests in an upcoming CL
Change-Id: I13465090b7b1c0bf5dc83362387a5428d77b7e1d

Lorenzo Colitti   commited 2019-06-04 14:35:22 +00:00
9a79a6d41e