565859 Commits

Author SHA1 Message Date
Remi NGUYEN VAN
f6ecb0017c Merge "Remove usage of networkAttributes" 2021-03-17 11:24:28 +00:00
paulhu
62dc76edf0 Remove Settings.Global.TCP_DEFAULT_INIT_RWND on CS
TCP_DEFAULT_INIT_RWND setting has never been set before, CS
always read the tcp receive window size from
net.tcp.default_init_rwnd then set to net.tcp_def_init_rwnd.
Thus, remove the unnecessary setting from CS, and the property
doesn't need to set either. Because aosp/1639922 migrate the
properties, the default value has been set to kernel already.

Bug: 182538166
Test: atest FrameworksNetTests
Change-Id: I13e175ab4dea72446af7df4a25e307e5934fa813
2021-03-17 11:14:35 +00:00
lucaslin
e4ea3d4c84 Expose VPN_UID
ConnectivityService will be a part of mainline module, so it
cannot access hidden API. Expose VPN_UID for ConnectivityService
to access.

Bug: 170598012
Test: m
Change-Id: I9f74fb97ba27e5feacf1820cf75e28ad73516d7d
2021-03-17 19:04:01 +08:00
Remi NGUYEN VAN
94b26e8bb4 Remove extra comment
This fixes a merge conflict with downstream branches due to an
incomplete cherry-pick.

Bug: 171540887
Test: m

Change-Id: I27a8f20f1a1d83b472700648f3f5a68413a76ac3
Merged-In: I7432fe4c87cd3cab04dcb6185c9a4f3f84376549
2021-03-17 10:58:08 +00:00
paulhu
f6f331d56b Add ConnectivitySettingsManager
This class is used to manager the connectivity module related
settings.

Bug: 182538166
Test: make
Change-Id: I5e02e719ce0d305d7c8a45fefb850d7b981f07eb
2021-03-17 18:24:16 +08:00
Chalard Jean
0d2b748aea Check for FEATURE_TELEPHONY instead of CM
The ConnectivityManager#isNetworkSupported has been
deprecated a long time ago and can no longer be called
from the system server as it's moving to a mainline
module. Instead of checking for support of a MOBILE
network, ask for FEATURE_TELEPHONY.

Note that this might not be 100% behavior-neutral, as
the old ConnectivityManager#isNetworkSupported would
return based on an OEM-configured resource, while the
new one is based on whether the device supports the
feature ; in particular, devices with phone call
support but without data support have the feature,
but may not have had the resource configuration. The
contention is that the new behavior is better, because
Airplane mode should depend on whether there is a
telephony radio on the device, not on whether that
radio supports data transfers.

Bug: 172183305
Test: FrameworksServicesTests
Change-Id: Ifb5ba537cb029b3aeebf74407002d873ec614f8d
2021-03-17 07:58:53 +00:00
Jack He
b67cbe2631 Merge "Bluetooth: Wait for provisioning after init flag change" 2021-03-17 07:18:08 +00:00
lucaslin
a7809e8ed9 Modify the comment of getPrivateDnsMode
Bug: 172183305
Test: m
Change-Id: I2f1b44cf2a362b42f052ea5d34a5cec03d46e661
2021-03-17 14:53:35 +08:00
Zoey Chen
dd68ace7e0 Merge "[Telephony] Exposed PhysicalChannelConfigListener as public API instead of system" 2021-03-17 06:46:27 +00:00
Lucas Lin
0aa487570c Merge "Change the parameter type from ContentResolver to Context" 2021-03-17 06:35:21 +00:00
lucaslin
d1deef1c8b Expose systemReady for SystemServer
SystemServer cannot call the hidden API of ConnectivityManager
after it becomes a part of mainline module. So expose the hidden
API for SystemServer.

Bug: 182963354
Test: m services
Change-Id: I9c1dc8eb1401dbdc069d5c9fc3992f4c7939b70e
2021-03-17 14:16:55 +08:00
Chalard Jean
7a38a3a2b7 Move constants to MODULE_LIB
These constants are used by a MODULE_LIBRARIES API, they should
have the same visibility.

Test: ConnectivityServiceTest
Change-Id: I14cb189d949fe552f463cae3002801fd8cf8230c
2021-03-17 14:59:24 +09:00
Chalard Jean
3ee9b7f251 Merge changes I335e82e2,I84ba363d,I8f18083b,I854a952d,I00e23441
* changes:
  Remove per-user preference when the user is removed
  Expose the enterprise per-profile networking API.
  Implement setNetworkPreferenceForUser.
  Public API for per-profile network preference.
  Add tests for setNetworkPreferenceForUser
2021-03-17 05:48:18 +00:00
Jiyong Park
147c20f115 Reset min_sdk_version of libmedia_jni
libmedia_jni is the non-updatable part of the platform. However, it has
been built with `min_sdk_version: "29"` inherited from
libcodec2-internal-defaults and then again from libcodec2-impl-defaults.
The setting is for the codec2 cc_* modules that are part of the media
APEX.

So far, this however, hasn't caused a problem because the build system
ignored min_sdk_version for the platform variants. This will change
starting from I88f64c5a35f1b5276c3350e177b116932011a940. Then
libmedia_jni will actually be built with min_sdk_verison: 29, and it
will be enforced that any APIs above the API level 29 should be guarded
with __builtin_available.

Adding the guards will not only be cumbersome, but also wouldn't give
any benefit because libmedia_jni is tied to the platform. The check will
always be true.

Instead, this change resets the min_sdk_version of libmedia_jni, so that
it can keep the existing behavior.

Bug: N/A
Test: m libmedia_jni
Change-Id: Ie963d71f60cbfe849b5400a5ecf2d52119078554
2021-03-17 14:20:54 +09:00
Hai Shalom
88d7e789a2 CaptivePortalData: use CharSequence in VenueFriendlyName API
Following up on feedback from API council, change the String type
to CharSequence in the get and set Venue friendly name API.

Bug: 179163405
Test: atest ConnectivityServiceTest CtsNetTestCasesLatestSdk:CaptivePortalDataTest
Test: atest NetworkNotificationManagerTest NetworkMonitorTest
Change-Id: Ia63974cd2ff5975bde410eb93731d4b1def36d19
2021-03-16 20:59:42 -07:00
Martin Brabham
3af765a863 Fix CTS Failure
Bug: 182849735
Test: atest CtsSystemApiAnnotationTestCases:android.signature.cts.api.AnnotationTest#testAnnotation -- --abi x86_64
Change-Id: I1b9e77b05cd23299bf179c854e136fa341c81566
2021-03-16 20:11:05 -07:00
Martin Brabham
96e6e4a0b3 Bluetooth: Modify and append to the Out-of-Band API
- Modify createOutOfBand to be a SystemApi, and accept p192 and p256 data objects.
 - Modify OobData to become a SystemApi and to provide a Builder pattern for creation.

CTS-Coverage-Bug: 182420103
Bug: 178007935
Test: compiles and runs
Tag: #feature
Change-Id: I46aec8c2cb64a8da8957d01d32b879d60df7a31c
Merged-In: I46aec8c2cb64a8da8957d01d32b879d60df7a31c
2021-03-16 20:10:56 -07:00
Janis Danisevskis
665844b1e2 Merge "Keystore 2.0: Remove hidden Keystore API from locksettings tests." 2021-03-17 03:01:24 +00:00
Howard Chen
811ad79636 Merge changes from topic "cow_pdb"
* changes:
  Support copy-on-write persistent data block when running a DSU
  Support PersistentDataBlockService in DSU
2021-03-17 02:07:03 +00:00
Chalard Jean
db9e849986 Merge "Annotate NSM heavy methods with @WorkerThread" 2021-03-17 02:03:22 +00:00
Remi NGUYEN VAN
1c6f87bd48 Move trimV4AddrZeros to libs/net
The utility is @UnsupportedAppUsage, and also used by internal classes
like WifiTrackerLib or Mms, so it needs to be in a shared location.

Bug: 182859030
Test: m
Change-Id: I25cb374f4743a5869e9da5b01d3a543a9a165c0e
2021-03-17 10:30:58 +09:00
Remi NGUYEN VAN
0255ab4694 Merge "Remove MessageUtils usage in VpnTransportInfo" 2021-03-17 00:14:10 +00:00
Remi NGUYEN VAN
a89a2ae676 Merge "Move LocationPermissionChecker to libs/net" 2021-03-17 00:13:21 +00:00
Junyu Lai
29908cf3c4 Merge "[VCN14] Expose registerBestMatchingNetworkCallback" 2021-03-16 23:31:29 +00:00
Hall Liu
2ab1cc0fac Merge "Add carrier config keys for RTT-VT compat" 2021-03-16 23:21:34 +00:00
Jack He
4d74f94897 Bluetooth: Wait for provisioning after init flag change
* Wait for device provisioning to be completed before restart stack
  after an init flag change

Bug: 181226310
Test: make, setup wizard
Change-Id: I1128d9ef25b7703da31cfe55a812aaa745ab5f41
2021-03-16 16:16:39 -07:00
Christian Wailes
98432e96b0 Merge "Adds tests for Install Scenarios to DexManagerTests" 2021-03-16 23:02:39 +00:00
Andy Hung
0f8c08544a Merge "SoundPool: Improve single stream SoundPool handling" 2021-03-16 22:24:05 +00:00
Andy Hung
43da3d54c4 SoundPool: Improve single stream SoundPool handling
By design, the StreamManager ramps down volume
on a Stream stop to prevent pops and glitches.
When the SoundPool is configured only with a single stream,
there may be a short period of unavailability of that stream
while stop is called by the worker thread; an immediate
play after a stop may return 0 (failure).

To allow immediate play after stop for a *single* Stream configured
SoundPool, we lock the StreamManager worker thread so that the
stop call is processed and the stream is visible to the client for use.

We prefer not to keep this lock for the multiple Stream case as it
prevents concurrent initiation of sounds from multiple StreamManager
worker threads and such blocking is not appropriate for games.

Test: SoundPoolAacTest SoundPoolHapticTest
Test: SoundPoolMidiTest SoundPoolOggTest
Bug: 175097719
Bug: 177287876
Merged-In: Iec777d6319d5ed76000d4c5b12336b106dacede4
Change-Id: Iec777d6319d5ed76000d4c5b12336b106dacede4
2021-03-16 21:01:05 +00:00
Peter Collingbourne
314afa1191 Support MTE and GWP-ASan features in proto tombstones.
Proto tombstones were missing tagged fault addresses, tagged_addr_ctrl,
tags in memory dumps and Scudo and GWP-ASan error reports. Since text
tombstones now go via protos, all of these features broke when we
switched to text tombstones generated from protos by default. Fix
the features by adding support for them to the proto format,
tombstone_proto and tombstone_proto_to_text.

Bug: 135772972
Bug: 182489365
Change-Id: I3ca854546c38755b1f6410a1f6198a44d25ed1c5
2021-03-16 10:59:39 -07:00
Yan Wang
59437812ad Merge "Rename enum in ArtDexMetadataType with appropriate prefix." 2021-03-16 17:34:51 +00:00
Henry Fang
e42498a501 Merge "Tuner FW: clean up Dvr/Filter message-queue resources upon close" 2021-03-16 17:18:48 +00:00
Treehugger Robot
62d82e0b33 Merge "Use ro.boot.qemu to check if the device is an emulator" 2021-03-16 16:31:57 +00:00
Junyu Lai
f98037abb3 Merge "[VCN13] Implement tracking best matching network" 2021-03-16 15:59:52 +00:00
Pierre Couillaud
ee14d5ea42 Tuner FW: clean up Dvr/Filter message-queue resources upon close
Bug: 182546718
Signed-off-by: Pierre Couillaud <pierre@broadcom.com>
Change-Id: I89374a334e86dd934a972989c318b5222f4ce769
Merged-In: Iea28f07a0800cbab88a1348fa7ae21ac17e1cfd8
2021-03-16 15:45:45 +00:00
Nader Jawad
0ebddf5fdc Merge "Update owners for EdgeEffect" 2021-03-16 15:28:24 +00:00
Michele Berionne
11773facb7 Merge "Clarification for PREPARE_UNATTENDED_REBOOT_ERROR" 2021-03-16 14:55:58 +00:00
junyulai
1eda2f6689 [VCN14] Expose registerBestMatchingNetworkCallback
Test: m -j doc-comment-check-docs
Bug: 175662146
Change-Id: Ie67dd2f4f8d973de37bc64a03908d7cbb7c2b7ad
2021-03-16 21:30:56 +08:00
junyulai
dbf52a2834 [VCN13] Implement tracking best matching network
This is done by:
  1. In requestNetwork, provide a basic permission check.
  2. rematchNetworksAndRequests: no change, since non listen
     requests will be automatically processed to track
     best satisfying network.
  3. applyNetworkReassignment: no change, since non-request
     will not be sent to factories.

Test: atest ConnectivityServiceTest#testRegisterBestMatchingNetworkCallback_noIssueToFactory
Test: atest ConnectivityServiceTest#testRegisterBestMatchingNetworkCallback_trackBestNetwork
Bug: 175662146
Change-Id: I8cf4ab334df6812d84cdda160e9b72b6f54062af
2021-03-16 21:30:55 +08:00
Paul Hu
96a89d8f43 Merge "Replace interal okhttp APIs" 2021-03-16 12:18:49 +00:00
Chalard Jean
d1343a21e9 Remove per-user preference when the user is removed
Test: new test for this
Change-Id: I335e82e29ec8f4c8da9def8b40153858cfd5bacb
2021-03-16 12:14:12 +00:00
Chalard Jean
0176e89052 Expose the enterprise per-profile networking API.
Also unify the listener for Oem settings, which have
never been released as public API (it is slated to be
released in S).

Test: FrameworksNetTests
Change-Id: I84ba363dd0ec03871c37b1c3a31e5557d9aa12e7
2021-03-16 12:14:00 +00:00
Chalard Jean
67bfec2027 Implement setNetworkPreferenceForUser.
Test: FrameworksNetTests
Change-Id: I8f18083b5857289892fe8adea5f5ea3f5dbe0809
2021-03-16 12:13:46 +00:00
Chalard Jean
b1cd4d7b9d Public API for per-profile network preference.
This patch defines the API, but does not make it public
yet as there is no implementation yet.

Test: none so far
Change-Id: I854a952dfe35cc80847eb62f522b1667b8e9b8a0
2021-03-16 12:13:27 +00:00
Chalard Jean
0bd0dc2c83 Add tests for setNetworkPreferenceForUser
Test: this
Change-Id: I00e2344118408da307439a0a993eb67cb17bf777
2021-03-16 12:11:27 +00:00
Lucas Lin
7044a8f3c7 Merge "Remove NETWORK_STACK_UID check" 2021-03-16 11:26:24 +00:00
Chienyuan
f757d2fa69 Le Scan: Add ambient discovery mode (1/2)
Bug: 177466875
Test: manual
Change-Id: I4a5c8a0768903ef0838dcf55cf5cfba9a0a18eef
2021-03-16 17:53:19 +08:00
lucaslin
7384af3e6b Change the parameter type from ContentResolver to Context
Context is more useful than ContentResolver, it can provide more
information if we want to change the behavior in the future.

Bug: 172183305
Test: atest FrameworksNetTests
Change-Id: I5702c7d74b862a76558b94f1abe2c6df9eb7f097
Merged-In: I5702c7d74b862a76558b94f1abe2c6df9eb7f097
2021-03-16 09:26:57 +00:00
lucaslin
5c29439697 Remove NETWORK_STACK_UID check
NETWORK_STACK_UID check was introduced by aosp/1134635, and it
assumed that wifi factories/agents will be running on the network
stack process, but it didn't eventually. It runs in the system
server instead. So remove this check.

Bug: 170598012
Test: atest FrameworksNetTests
Change-Id: Ie11268738e364e252f18876f7a4a0dc064ca8b9c
2021-03-16 09:16:38 +00:00
Lucas Lin
5b30e438de Merge "Add comments to describe the value of converting hex to decimal" 2021-03-16 08:31:10 +00:00