OSDN Git Service

android-x86/frameworks-base.git
5 years agoMerge "[IPMS] Implement regular maintenance"
Paul Hu [Tue, 2 Apr 2019 01:39:38 +0000 (01:39 +0000)]
Merge "[IPMS] Implement regular maintenance"

5 years agoMerge "Fix IpPrefixTest#testContainsInetAddress fail."
Paul Hu [Tue, 2 Apr 2019 01:33:02 +0000 (01:33 +0000)]
Merge "Fix IpPrefixTest#testContainsInetAddress fail."

5 years agoMerge "Rename NetworkStackPermissionStub"
Remi NGUYEN VAN [Tue, 2 Apr 2019 01:31:51 +0000 (01:31 +0000)]
Merge "Rename NetworkStackPermissionStub"

5 years agoRename NetworkStackPermissionStub
Remi NGUYEN VAN [Tue, 26 Mar 2019 08:24:48 +0000 (17:24 +0900)]
Rename NetworkStackPermissionStub

Use NetworkStackPermissionConfig instead.

Bug: 129317412
Test: Flashed, booted, WiFi working
Merged-In: I7bdc058dddfa483823074055ad5c9d7d2efd37b9
Change-Id: I45299c12598cd3b33bfd78ae8698d98b77b18dc0

5 years agoMerge "Cleanup SystemReady in the network stack"
Chalard Jean [Mon, 1 Apr 2019 23:28:47 +0000 (23:28 +0000)]
Merge "Cleanup SystemReady in the network stack"

5 years agoMerge "Add a new carrier config to show the WFC location privacy policy UI"
Hall Liu [Mon, 1 Apr 2019 22:55:51 +0000 (22:55 +0000)]
Merge "Add a new carrier config to show the WFC location privacy policy UI"

5 years agoMerge "BluetoothHealth: hide auto-created default constructors"
Treehugger Robot [Mon, 1 Apr 2019 22:37:43 +0000 (22:37 +0000)]
Merge "BluetoothHealth: hide auto-created default constructors"

5 years agoMerge "Pass debug.allocTracker.stackDepth to runtime if it exists"
Mathieu Chartier [Mon, 1 Apr 2019 22:29:07 +0000 (22:29 +0000)]
Merge "Pass debug.allocTracker.stackDepth to runtime if it exists"

5 years agoMerge "Remove clearDefaultsForInactiveSubIds."
Xiangyu/Malcolm Chen [Mon, 1 Apr 2019 20:51:54 +0000 (20:51 +0000)]
Merge "Remove clearDefaultsForInactiveSubIds."

5 years agoMerge changes from topics "nw-scan-cts", "nw-scan-changes"
Hall Liu [Mon, 1 Apr 2019 20:31:10 +0000 (20:31 +0000)]
Merge changes from topics "nw-scan-cts", "nw-scan-changes"

* changes:
  Add shell permissions for CTS testing
  Allow requestNetworkScan to return sanitized info

5 years agoBluetoothHealth: hide auto-created default constructors
Jack He [Fri, 29 Mar 2019 00:42:26 +0000 (17:42 -0700)]
BluetoothHealth: hide auto-created default constructors

Fixes: 123926561
Test: make
Change-Id: I388472c82eaca245285b5ecf2959c415508d7e69

5 years agoPass debug.allocTracker.stackDepth to runtime if it exists
Mathieu Chartier [Fri, 29 Mar 2019 20:49:35 +0000 (13:49 -0700)]
Pass debug.allocTracker.stackDepth to runtime if it exists

Since this is no longer called in ART, pass it down in bind application.

Bug: 37291459
Test: test-art-host

Change-Id: I23623e9b8e9ca6261d90cc1ae1c5d8c24cc4eba5

5 years agoFix IpPrefixTest#testContainsInetAddress fail.
paulhu [Mon, 1 Apr 2019 16:49:00 +0000 (00:49 +0800)]
Fix IpPrefixTest#testContainsInetAddress fail.

The argument of IpPreFix#contains() has been marked as @NonNull.
So the IpPrefixTest#testContainsInetAddress should not test
contains() method wiht null object.

Bug: None
Test: atest FrameworksNetTests
      atest IpPrefixTest#testContainsInetAddress

Change-Id: I2f6bee19514dc47702f64d2a2bbf02d8b7b1b407

5 years agoMerge "Track public android.system API changes in libcore"
Neil Fuller [Mon, 1 Apr 2019 16:41:11 +0000 (16:41 +0000)]
Merge "Track public android.system API changes in libcore"

5 years ago[IPMS] Implement regular maintenance
paulhu [Mon, 25 Mar 2019 17:39:10 +0000 (01:39 +0800)]
[IPMS] Implement regular maintenance

Implement regular maintenance of IpMemoryStoreService. Regular
maintenance is scheduled for when the device is idle with access
power and a minimum interval of one day.

Bug: 113554482
Test: atest NetworkStackTests
Change-Id: Id3985e30d12307fc2e9fcbe782caaf97a627cef3

5 years agoMerge "Unhide ICMP echo constants."
Lorenzo Colitti [Mon, 1 Apr 2019 15:08:44 +0000 (15:08 +0000)]
Merge "Unhide ICMP echo constants."

5 years agoMerge "Add comment for NetworkStack permissions"
Treehugger Robot [Mon, 1 Apr 2019 14:45:18 +0000 (14:45 +0000)]
Merge "Add comment for NetworkStack permissions"

5 years agoMerge "Mark PROCESS_OUTGOING_CALLS permission as deprecated."
Tyler Gunn [Mon, 1 Apr 2019 14:13:50 +0000 (14:13 +0000)]
Merge "Mark PROCESS_OUTGOING_CALLS permission as deprecated."

5 years agoMerge "Add DHCP address lease expiry in IpMemoryStore."
Xiao Ma [Mon, 1 Apr 2019 12:59:20 +0000 (12:59 +0000)]
Merge "Add DHCP address lease expiry in IpMemoryStore."

5 years agoMerge "Fix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues."
Paul Hu [Mon, 1 Apr 2019 07:20:53 +0000 (07:20 +0000)]
Merge "Fix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues."

5 years agoMerge "Provide link to android experimental flags API"
Chiachang Wang [Mon, 1 Apr 2019 04:49:33 +0000 (04:49 +0000)]
Merge "Provide link to android experimental flags API"

5 years agoCleanup SystemReady in the network stack
Chalard Jean [Mon, 1 Apr 2019 04:04:07 +0000 (13:04 +0900)]
Cleanup SystemReady in the network stack

The system server (in SystemServer.java) defines the boot
sequence, during which an event called SystemReady happens.
This corresponds to a time when critical system services
that are depended upon by other components in the system
server are ready to handle requests from their dependencies.
Some system services are listening to this event to defer
initializations that depend on the critical services.

Because the network stack is only started after SystemReady,
there is no way any NetworkMonitor may be started before
SystemReady. Remove the associated mechanism.

Fix: 129376083
Test: FrameworksNetTests
Change-Id: I071eeb10d0b7c4f71af6653d322c7b442b2cc7ee

5 years agoAdd comment for NetworkStack permissions
Remi NGUYEN VAN [Mon, 1 Apr 2019 01:56:05 +0000 (10:56 +0900)]
Add comment for NetworkStack permissions

Clarify that permissions must not be in the base package to avoid
crashes on devices using a network stack running in the system server
process.

Test: m
Change-Id: Ib13df84a43e960d01217c208d1c6775d1f81edc4

5 years agoMerge "Move permissions from base to standard manifest"
Remi NGUYEN VAN [Mon, 1 Apr 2019 04:20:41 +0000 (04:20 +0000)]
Merge "Move permissions from base to standard manifest"

5 years agoMerge "Fix race when starting NetworkMonitor"
Remi NGUYEN VAN [Mon, 1 Apr 2019 03:54:03 +0000 (03:54 +0000)]
Merge "Fix race when starting NetworkMonitor"

5 years agoMerge "Refine Bluetooth silence mode API"
Treehugger Robot [Mon, 1 Apr 2019 03:12:31 +0000 (03:12 +0000)]
Merge "Refine Bluetooth silence mode API"

5 years agoFix race when starting NetworkMonitor
Remi NGUYEN VAN [Wed, 27 Mar 2019 06:42:53 +0000 (15:42 +0900)]
Fix race when starting NetworkMonitor

NetworkMonitor obtained LinkProperties and NetworkCapabilities via
synchronous calls to ConnectivityManager after receiving an asynchronous
notification, which is prone to races: the network could be gone before
the LinkProperties/NetworkCapabilities can be fetched.

Fix the race by passing LinkProperties/NetworkCapabilities directly to
NetworkMonitor in the asynchronous notifications.

Test: atest FrameworksNetTests NetworkStackTests
Test: booted, WiFi works
Bug: 129375892
Change-Id: I200ac7ca6ff79590b11c9be705f650c92fd3cb63

5 years agoFix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues.
paulhu [Wed, 27 Mar 2019 14:26:37 +0000 (22:26 +0800)]
Fix ApfCapabilities, LinkAddress, RouteInfo, IpPrefix API issues.

Fix: 129362082
Fix: 129361362
Fix: 129360330
Fix: 129362379
Test: atest FrameworksNetTests NetworkStackTests
Change-Id: I05fbc6f98207d5cf002e3cbc5829040af7d6be52

5 years agoProvide link to android experimental flags API
Chiachang Wang [Mon, 1 Apr 2019 01:56:05 +0000 (09:56 +0800)]
Provide link to android experimental flags API

Add function to link to android experiemental flags API

Bug: 120013793
Test: Build and atest NetworkStackTests
Change-Id: I14b9a6f06f841a9d63e8c1954907447a9e7eb8a5

5 years agoMove permissions from base to standard manifest
Remi NGUYEN VAN [Fri, 29 Mar 2019 05:56:34 +0000 (14:56 +0900)]
Move permissions from base to standard manifest

Permissions defined in AndroidManifest_Base.xml would be inherited in
AndroidManifest_InProcess.xml and cause issues on svelte builds, since
privileged permissions are not whitelisted for
com.android.networkstack.inprocess.

The network stack running in the system_server process does not need
these permissions anyway since it has system_server permissions.

(clean cherry-pick from Ica63ce586e701b1f2415a97f63ba27cc25e4830a)

Test: flashed, booted crosshatch_svelte-eng, WiFi works
Test: flashed, booted blueline-eng, WiFi works
Fixes: 129485310
Merged-In: Ica63ce586e701b1f2415a97f63ba27cc25e4830a
Change-Id: Ib4b478fb39f43a2fd4221c7d1f1ea51de04e0fba

5 years agoMark PROCESS_OUTGOING_CALLS permission as deprecated.
Tyler Gunn [Fri, 29 Mar 2019 23:38:29 +0000 (16:38 -0700)]
Mark PROCESS_OUTGOING_CALLS permission as deprecated.

We deprecated the NEW_OUTGOING_CALL broadcast which uses this, so we
should also deprecate the permission to make it more clear to the
developers.

Test: Build / make api
Bug: 129531123
Bug: 129572090
Change-Id: Iac4979ffe29c33eb2ed8ffe4a7799e7caa794951

5 years agoMerge "Revert "Change Values for Opportunistic Entry & Exit Thresholds""
Treehugger Robot [Sat, 30 Mar 2019 00:53:23 +0000 (00:53 +0000)]
Merge "Revert "Change Values for Opportunistic Entry & Exit Thresholds""

5 years agoRevert "Change Values for Opportunistic Entry & Exit Thresholds"
Sooraj Sasindran [Fri, 29 Mar 2019 23:14:23 +0000 (23:14 +0000)]
Revert "Change Values for Opportunistic Entry & Exit Thresholds"

This reverts commit f0c8f19325a83374b52f49d6b66fcf05466c1c54.

Reason for revert: From further test, we see sharp decline in data throughput

Change-Id: I0fb031a8adf15d3a0149651bcc51ee1d7318a42e

5 years agoMerge "Do not show SMS SIM pick UI for Cell Broadcast Config change"
Treehugger Robot [Fri, 29 Mar 2019 22:52:00 +0000 (22:52 +0000)]
Merge "Do not show SMS SIM pick UI for Cell Broadcast Config change"

5 years agoMerge changes from topics "128455935", "123661746"
Xiangyu/Malcolm Chen [Fri, 29 Mar 2019 21:48:10 +0000 (21:48 +0000)]
Merge changes from topics "128455935", "123661746"

* changes:
  Better description and parameter name of setPreferredDataSubscriptionId
  Remove SubscriptionManager#setMetered API.

5 years agoRemove clearDefaultsForInactiveSubIds.
Malcolm Chen [Fri, 15 Mar 2019 03:56:00 +0000 (20:56 -0700)]
Remove clearDefaultsForInactiveSubIds.

clearDefaultsForInactiveSubIds is no longer needed as Telephony
has internal logic to clear or update default settings automatically.

Bug: 128645056
Test: manual
Change-Id: Ib7bc0ae6dba6f10e3a052df1644cc77dd30121a9
Merged-In: Ib7bc0ae6dba6f10e3a052df1644cc77dd30121a9

5 years agoMerge "Add missing checkThread"
Treehugger Robot [Fri, 29 Mar 2019 21:18:10 +0000 (21:18 +0000)]
Merge "Add missing checkThread"

5 years agoDo not show SMS SIM pick UI for Cell Broadcast Config change
Brad Ebinger [Thu, 28 Mar 2019 22:46:50 +0000 (15:46 -0700)]
Do not show SMS SIM pick UI for Cell Broadcast Config change

If the user did not pick their default SIM subscription for
SMS, we were showing many dialogs to the user whenever
SmsManager#getSubscriptionId was called for cell broadcast
related APIs.

Instead, if we instantiate the SmsManager using
SmsManager.getDefault() and the user has not set a default,
use the default Phone and do not show SIM picker activity
(consistent with legacy implementation).

Bug: 129315610
Test: set up DSDS, disable eSIM operator in settings
Change-Id: I3cc4839632eede75c8943836432b07978d0efda0

5 years agoTrack public android.system API changes in libcore
Neil Fuller [Fri, 29 Mar 2019 13:33:47 +0000 (13:33 +0000)]
Track public android.system API changes in libcore

Track public android.system API changes in libcore associated with
Os.setSockOptTimeval() / Os.getSockOptTimeVal().

Test: See associated libcore change
Bug: 129251251
Bug: 117867568
Bug: 129433363
Change-Id: Ic7c179aebbf29115dea4e09fbc68f515d13bcc3f

5 years agoMerge "Check permissions and carrier privilege in notifyActiveDataSubIdChanged"
Shuo Qian [Fri, 29 Mar 2019 20:13:09 +0000 (20:13 +0000)]
Merge "Check permissions and carrier privilege in notifyActiveDataSubIdChanged"

5 years agoMerge "Fix getWifiManager exception if phone is encrypted"
Treehugger Robot [Fri, 29 Mar 2019 19:55:57 +0000 (19:55 +0000)]
Merge "Fix getWifiManager exception if phone is encrypted"

5 years agoCheck permissions and carrier privilege in notifyActiveDataSubIdChanged
sqian [Fri, 29 Mar 2019 18:35:29 +0000 (11:35 -0700)]
Check permissions and carrier privilege in notifyActiveDataSubIdChanged

Bug: 127978132
Test: Treehugger
Merged-In: I1d9c5d1b242953a2af3e56718ef82761941d8d9c
(cherry picked from commit 9e9ed18772087cf96571847dc3fbfb235d620f43)

Change-Id: Ia25472063d6f42c36f429e725d364ecf4f16fec1

5 years agoMerge "Change ProvisioningManager API as per review"
Brad Ebinger [Fri, 29 Mar 2019 18:23:35 +0000 (18:23 +0000)]
Merge "Change ProvisioningManager API as per review"

5 years agoMerge "Minor change for async DNS API"
Treehugger Robot [Fri, 29 Mar 2019 18:22:12 +0000 (18:22 +0000)]
Merge "Minor change for async DNS API"

5 years agoMerge "Emergency Number format"
Shuo Qian [Fri, 29 Mar 2019 18:11:26 +0000 (18:11 +0000)]
Merge "Emergency Number format"

5 years agoAdd missing checkThread
John Reck [Fri, 29 Mar 2019 17:26:01 +0000 (10:26 -0700)]
Add missing checkThread

Fixes: 129362490
Test: none
Change-Id: I9429b48291908db7021ad10a18ef3180c7e83bf9

5 years agoMerge "Update documentation for updateAvailableNetworks"
Sooraj Sasindran [Fri, 29 Mar 2019 17:21:54 +0000 (17:21 +0000)]
Merge "Update documentation for updateAvailableNetworks"

5 years agoUnhide ICMP echo constants.
Lorenzo Colitti [Fri, 29 Mar 2019 13:14:28 +0000 (22:14 +0900)]
Unhide ICMP echo constants.

Bug: 129251251
Test: atest android.net.ipv6.cts.PingTest com.android.cts.net.hostside.VpnTest com.android.cts.deviceandprofileowner.AlwaysOnVpnTest
Change-Id: I5dc8fce0ac47aa622c8d6763b8fa443a7a0570c8

5 years agoAdd shell permissions for CTS testing
Hall Liu [Thu, 28 Feb 2019 23:29:19 +0000 (15:29 -0800)]
Add shell permissions for CTS testing

Add NETWORK_SCAN to shell permissions to enable CTS testing of the
network scan changes

Bug: 126779616
Test: CTS
Change-Id: I1f75c9005620b3b0e06f066677cba6190f1d266c
Merged-In: I1f75c9005620b3b0e06f066677cba6190f1d266c

5 years agoMerge "Unremove DnsResolver#query method used by external developers"
Lorenzo Colitti [Fri, 29 Mar 2019 14:46:11 +0000 (14:46 +0000)]
Merge "Unremove DnsResolver#query method used by external developers"

5 years agoMerge "Fixed NPE in RankingHelper.writeXml. Make sure that mRecords is operated with...
Treehugger Robot [Fri, 29 Mar 2019 14:04:27 +0000 (14:04 +0000)]
Merge "Fixed NPE in RankingHelper.writeXml. Make sure that mRecords is operated with the object lock."

5 years agoFixed NPE in RankingHelper.writeXml.
Ethan_Hu [Tue, 5 Mar 2019 06:58:32 +0000 (14:58 +0800)]
Fixed NPE in RankingHelper.writeXml.
Make sure that mRecords is operated with the object lock.

Bug:127290258
Test: Repeat to upgrade the App targetversion from less than O to a later version
Change-Id: I70e61c0fcd3071f32a430d45441ffe1376147a5d
Signed-off-by: Ethan_Hu <huyuxin3818@gmail.com>
Merged-In: Ic7f676499425fe54453384d7c03de5d95c03a713

5 years agoMerge "apf: Documentation improvements and code optimizations for keepalive filters"
Aaron Huang [Fri, 29 Mar 2019 13:03:20 +0000 (13:03 +0000)]
Merge "apf: Documentation improvements and code optimizations for keepalive filters"

5 years agoMinor change for async DNS API
Luke Huang [Fri, 29 Mar 2019 10:01:11 +0000 (18:01 +0800)]
Minor change for async DNS API

do the minor changes to address comments before

Bug: 129395490
Test: atest DnsResolverTest
Change-Id: I56e2e5bc4352ff5c979579247a333a41950079da

5 years agoUnremove DnsResolver#query method used by external developers
Luke Huang [Thu, 28 Mar 2019 05:56:31 +0000 (13:56 +0800)]
Unremove DnsResolver#query method used by external developers

This method was removed as part of addressing API council feedback in b/129261432
Add back previous DnsResolver#query which is already being used by developers.

Bug: 129395490
Test: atest DnsResolverTest

Change-Id: Ic956db204f3940d39d42e1b11dda39e57d356fad

5 years agoMerge "Add version attribute"
Treehugger Robot [Fri, 29 Mar 2019 09:18:31 +0000 (09:18 +0000)]
Merge "Add version attribute"

5 years agoMerge changes from topic "default_permissions"
Treehugger Robot [Fri, 29 Mar 2019 09:18:13 +0000 (09:18 +0000)]
Merge changes from topic "default_permissions"

* changes:
  Change the package name
  Add maxOccurs

5 years agoMerge "Use IDnsResolver instead of INetd for resolver related binder commands"
Luke Huang [Fri, 29 Mar 2019 08:45:19 +0000 (08:45 +0000)]
Merge "Use IDnsResolver instead of INetd for resolver related binder commands"

5 years agoAdd DHCP address lease expiry in IpMemoryStore.
Xiao Ma [Fri, 1 Mar 2019 03:25:36 +0000 (12:25 +0900)]
Add DHCP address lease expiry in IpMemoryStore.

Bug:122710829
Test: atest FrameworksNetTests
Change-Id: I643fe1231edcd18923514ab66c64a6cf83e69443

5 years agoFix getWifiManager exception if phone is encrypted
Ye Jiao [Mon, 28 Jan 2019 04:54:22 +0000 (12:54 +0800)]
Fix getWifiManager exception if phone is encrypted

[Issue Details]
NetworkPolicyManagerService may invoke
dispatchRestrictBackgroundChanged after reboot if settings changed, and
invokes untetherAll in turn, which triggers ServiceNotFoundException
indirectly if the device is under encryption. The cause is that
WifiService is not running if the device is still locked.

[Solution]
In order to avoid ServiceNotFoundException in setWifiTethering, we add
check on return value of getWifiManager. Moreover, check of UsbManager
is also added to prevent potential similar issues of USB tethering.

Bug: 123504004
Test: FrameworksNetTests
  adb shell am instrument -w com.android.frameworks.tests.net
Test: CTS - CtsNetTestCases
  ANDROID_BUILD_droid-cts/tools/cts-tradefed run cts -m CtsNetTestCases
Test: CTS - CtsNetTestCasesLegacyApi22
  ANDROID_BUILD_droid-cts/tools/cts-tradefed run cts -m
  CtsNetTestCasesLegacyApi22
Test: CTS - CtsNetTestCasesLegacyPermission22
  ANDROID_BUILD_droid-cts/tools/cts-tradefed run cts -m
  CtsNetTestCasesLegacyPermission22

Change-Id: I2643188b51900f97ba58c8614c66cb55ebfaa2f6

5 years agoMerge "[KA09] add keepalive offload permission to shell"
Mark Chien [Fri, 29 Mar 2019 06:15:11 +0000 (06:15 +0000)]
Merge "[KA09] add keepalive offload permission to shell"

5 years agoMerge "Fix cancellation race problem for aysnc DNS API"
Luke Huang [Fri, 29 Mar 2019 03:15:32 +0000 (03:15 +0000)]
Merge "Fix cancellation race problem for aysnc DNS API"

5 years agoEmergency Number format
sqian [Fri, 15 Mar 2019 02:42:38 +0000 (19:42 -0700)]
Emergency Number format

Use PhoneNumberUtils#isDialable to check each character.

Bug: 123241078
Test: Treehugger
Change-Id: Icc9083ed4d6cdae22c3ede9433433ac8eeec4918
Merged-In: Icc9083ed4d6cdae22c3ede9433433ac8eeec4918
(cherry picked from commit 0197a96e8add2658d424d5d318b383281d702add)

5 years agoBetter description and parameter name of setPreferredDataSubscriptionId
Malcolm Chen [Tue, 19 Mar 2019 00:26:43 +0000 (17:26 -0700)]
Better description and parameter name of setPreferredDataSubscriptionId

Bug: 128455935 128456058
Test: build
Change-Id: I41ae6752756d998739fd7635bcc7765f255806d7
Merged-In: I41ae6752756d998739fd7635bcc7765f255806d7

5 years agoRemove SubscriptionManager#setMetered API.
Malcolm Chen [Mon, 18 Mar 2019 20:50:23 +0000 (13:50 -0700)]
Remove SubscriptionManager#setMetered API.

Bug: 123661746
Test: sanity
Change-Id: Ia6772dee1bd566e0be6b06455d92c923d2c01b12
Merged-In: Ia6772dee1bd566e0be6b06455d92c923d2c01b12

5 years agoMerge changes from topic "vpn_data_accounting"
Varun Anand [Fri, 29 Mar 2019 00:40:53 +0000 (00:40 +0000)]
Merge changes from topic "vpn_data_accounting"

* changes:
  Move BatteryStats and StatsCompanionService to use NetworkStatsService.
  NetworkStatsService: Fix getDetailedUidStats to take VPNs into account.
  Take all VPN underlying networks into account when migrating traffic for VPN uid.

5 years agoUpdate documentation for updateAvailableNetworks
Sooraj Sasindran [Fri, 22 Mar 2019 22:14:12 +0000 (15:14 -0700)]
Update documentation for updateAvailableNetworks

Update documentation for updateAvailableNetworks
Bug: 128902411
Test: make

Change-Id: Ib6b6d72db3320e6c95f74b9371483f57bc90fee1

5 years agoMerge "Close tethering when UI entitlement fails"
Treehugger Robot [Thu, 28 Mar 2019 23:34:34 +0000 (23:34 +0000)]
Merge "Close tethering when UI entitlement fails"

5 years agoMerge "Clarify hasSelection description"
Hans Boehm [Thu, 28 Mar 2019 22:21:00 +0000 (22:21 +0000)]
Merge "Clarify hasSelection description"

5 years agoMerge "Change Values for Opportunistic Entry & Exit Thresholds"
Sooraj Sasindran [Thu, 28 Mar 2019 22:13:37 +0000 (22:13 +0000)]
Merge "Change Values for Opportunistic Entry & Exit Thresholds"

5 years agoChange ProvisioningManager API as per review
Brad Ebinger [Wed, 27 Mar 2019 23:51:59 +0000 (16:51 -0700)]
Change ProvisioningManager API as per review

Bug: 129344996
Test: Manual
Change-Id: I1c41cf1ae622ee24b4bed91c15d194518f91dac7

5 years agoChange Values for Opportunistic Entry & Exit Thresholds
Evan Tyra [Wed, 27 Mar 2019 22:11:15 +0000 (15:11 -0700)]
Change Values for Opportunistic Entry & Exit Thresholds

Due to the generally higher quality of these networks, we expanded the
entry and exit criteria of opportunistic networks.

Test: Make
Change-Id: Iaac1641db1d6a07bcce6dd194765c79c83a92070
Merged-In: Iaac1641db1d6a07bcce6dd194765c79c83a92070

5 years agoMerge "Migrate frameworks/base/packages/Shell to androidx.test"
Treehugger Robot [Thu, 28 Mar 2019 19:56:53 +0000 (19:56 +0000)]
Merge "Migrate frameworks/base/packages/Shell to androidx.test"

5 years agoMerge "Shutdown device gracefully when net discharging"
Treehugger Robot [Thu, 28 Mar 2019 18:34:28 +0000 (18:34 +0000)]
Merge "Shutdown device gracefully when net discharging"

5 years agoMerge "Revert "improve mism support for phonestatelistner""
Jayachandran Chinnakkannu [Thu, 28 Mar 2019 18:05:53 +0000 (18:05 +0000)]
Merge "Revert "improve mism support for phonestatelistner""

5 years agoMerge changes from topic "126637721"
Xiangyu/Malcolm Chen [Thu, 28 Mar 2019 17:54:14 +0000 (17:54 +0000)]
Merge changes from topic "126637721"

* changes:
  Show signal strength of current active subscription
  Update document of setSubscriptionEnabled public API.
  Clean up shouldHideSubscription API

5 years agoMove BatteryStats and StatsCompanionService to use NetworkStatsService.
Varun Anand [Fri, 25 Jan 2019 02:03:00 +0000 (18:03 -0800)]
Move BatteryStats and StatsCompanionService to use NetworkStatsService.

This CL is a manual merge of http://ag/c/6015966/3.

Bug: 113122541
Bug: 120145746
Test: atest FrameworksNetTests
Test: manual test: verified that BatteryStats are correctly accounting
for VPN traffic.
Change-Id: I5b07ce70ac58bdcbebc3114bfe9fd411469d57af
Merged-In: I230c1edbf64cfeb3dbb560db368b5e420f7b79a4

5 years agoNetworkStatsService: Fix getDetailedUidStats to take VPNs into account.
Varun Anand [Sat, 19 Jan 2019 03:22:48 +0000 (19:22 -0800)]
NetworkStatsService: Fix getDetailedUidStats to take VPNs into account.

This API is similar to one provided by NetworkStatsFactory with the
difference that NSS also migrates traffic from VPN UID to other apps.

Since traffic can only be migrated over NetworkStats delta, NSS
therefore maintains NetworkStats snapshot across all UIDs/ifaces/tags.

This snapshot gets updated whenever NSS records a new snapshot
(based on various hooks such as VPN updating its underlying networks,
network getting lost, etc.), or getDetailedUidStats API is invoked by
one of its callers.

Bug: 113122541
Bug: 120145746
Test: atest FrameworksNetTests
Test: manually verified that battery stats are migrating traffic off of
TUN (after patching above CL where we point BatteryStats to use this
API).
Change-Id: Ib0f0c2d4d41ee1d7a027ea9da457baaf198d649e

5 years agoTake all VPN underlying networks into account when migrating traffic for
Varun Anand [Mon, 18 Feb 2019 07:43:25 +0000 (23:43 -0800)]
Take all VPN underlying networks into account when migrating traffic for
VPN uid.

Bug: 113122541
Bug: 120145746
Test: atest FrameworksNetTests
Test: Manually verified on device that stats from VPN UID are moved
      appropriately based on its declared underlying network set.
Test: vogar --mode app_process --benchmark NetworkStatsBenchmark.java

Change-Id: I9d8d0cc58d18002c1c96f8ddff780ef8dc452d21

5 years agoMerge "To add the Android.bp of ExternalStorageProvider"
Treehugger Robot [Thu, 28 Mar 2019 17:31:14 +0000 (17:31 +0000)]
Merge "To add the Android.bp of ExternalStorageProvider"

5 years agoRevert "improve mism support for phonestatelistner"
Jayachandran Chinnakkannu [Thu, 28 Mar 2019 16:31:19 +0000 (16:31 +0000)]
Revert "improve mism support for phonestatelistner"

This reverts commit 2506ceb71e1535af49fd3495f8eae0bbdfe36c5b.

Reason for revert: DSDS system UI issues (b/129426477)

Change-Id: Ic0fde0d3bd412868917cdbe74504c3f9cebdc712

5 years agoFix cancellation race problem for aysnc DNS API
Luke Huang [Tue, 26 Mar 2019 07:50:10 +0000 (15:50 +0800)]
Fix cancellation race problem for aysnc DNS API

This problem might cause double-close fd and result in app crash
or unexpected behaviour

Bug: 129317069
Test: atest DnsResolverTest
      manual test with delaying response callback/cancel
Change-Id: I223234f527edafc51d34fa6be390419c05def8d8

5 years agoMerge "Only apply entitlement check to cellular upstream"
Mark Chien [Thu, 28 Mar 2019 09:52:52 +0000 (09:52 +0000)]
Merge "Only apply entitlement check to cellular upstream"

5 years agoMerge "Revert "Preload non-bootclasspath Java lib ClassLoaders.""
Nicolas Geoffray [Thu, 28 Mar 2019 09:27:05 +0000 (09:27 +0000)]
Merge "Revert "Preload non-bootclasspath Java lib ClassLoaders.""

5 years agoRevert "Preload non-bootclasspath Java lib ClassLoaders."
Nicolas Geoffray [Thu, 28 Mar 2019 09:25:11 +0000 (09:25 +0000)]
Revert "Preload non-bootclasspath Java lib ClassLoaders."

This reverts commit 1b11aaaf9ba824dc5df363736d54601e908efec6.

Bug: 128529256
Bug: 127406460

Reason for revert: Breaks FSI

Change-Id: Ie9775779cda7b376c36493f3ce3246eafc672c59

5 years agoMerge "Move the attribute tags"
Treehugger Robot [Thu, 28 Mar 2019 07:48:59 +0000 (07:48 +0000)]
Merge "Move the attribute tags"

5 years agoMerge "Align proto naming with server configuration"
Chiachang Wang [Thu, 28 Mar 2019 05:37:21 +0000 (05:37 +0000)]
Merge "Align proto naming with server configuration"

5 years ago[KA09] add keepalive offload permission to shell
markchien [Wed, 23 Jan 2019 09:24:10 +0000 (17:24 +0800)]
[KA09] add keepalive offload permission to shell

This change adds PACKET_KEEPALIVE_OFFLOAD to shell, which allows
shell or code with shell permission identity to use privileged
tcp keepalive offload API.

Bug: 114151147
Test: -atest ConnectivityManagerTest#testCreateTcpKeepalive
      -build, flash, boot

Change-Id: Ib6660a5eaa72f83042596481452be4d415383f02
Merged-in: Ib6660a5eaa72f83042596481452be4d415383f02

5 years agoClose tethering when UI entitlement fails
markchien [Tue, 26 Mar 2019 13:41:59 +0000 (21:41 +0800)]
Close tethering when UI entitlement fails

This is a alternative way for moving TetherService logic
into EntitlementManager[1]. Settings would close tethering
when silent entitlement check fail. To be consistent,
tethering should also be closed if UI entitlement check
fails.

[1] https://android-review.googlesource.com/c/platform/frameworks/base/+/928136

bug: 129330738
Test: -build, flash, boot,
      -atest EntitlementManagerTest
      -manual test with carrier SIM

Change-Id: Idfc35461b6359f3a624e78d49b6f73812db6d8ab

5 years agoMerge "support msim for captiveportal notification"
Treehugger Robot [Thu, 28 Mar 2019 03:28:19 +0000 (03:28 +0000)]
Merge "support msim for captiveportal notification"

5 years agoOnly apply entitlement check to cellular upstream
markchien [Fri, 7 Sep 2018 08:19:12 +0000 (16:19 +0800)]
Only apply entitlement check to cellular upstream

Instead of doing a tethering entitlement check whenever we turn
on tethering, provisioning result should only affect mobile
upstream. List behavior changes below:

1. Change tether entitlement check from pre-flight check to
run-time check.
2. Only run entitlement check when upstream is mobile.
3. Move schedule entitlement re-check logic from Settings to
framework.
4. Run all entitlement thing in TetherMaster thread to avoid
multi-thread problem.

Test: -atest FrameworksNetTests
      -build, flash, booted
bug: 111490073
Change-Id: Ic2980b4d6864d6f7287816c43eb6cf7a5cdec541
Merged-in: Ic2980b4d6864d6f7287816c43eb6cf7a5cdec541

5 years agoTo add the Android.bp of ExternalStorageProvider
felkachang [Tue, 16 Oct 2018 12:46:26 +0000 (20:46 +0800)]
To add the Android.bp of ExternalStorageProvider

ExternalStorageProvider doesn't have any tests yet.
1. Convert Android.mk to Android.bp
2. Add init testcase
3. formatted by bpfmt -s -w Android.bp

Fixes: 117812397
Bug: 122332340
Test: atest ExternalStorageProviderTests

Change-Id: I74235832f453110742de0b15cb14fac7514ecf0e
Merged-In: I74235832f453110742de0b15cb14fac7514ecf0e

5 years agoMerge "Update Android Beam deprecated API description"
Treehugger Robot [Thu, 28 Mar 2019 01:33:58 +0000 (01:33 +0000)]
Merge "Update Android Beam deprecated API description"

5 years agoMerge changes I0baf582f,I4bba01ba
Junyu Lai [Thu, 28 Mar 2019 00:53:20 +0000 (00:53 +0000)]
Merge changes I0baf582f,I4bba01ba

* changes:
  Block unpriviledged apps which create keepalives with null fd
  Fix keepalive don't get removed when lower layer error

5 years agoMerge "Fix glob syntax"
Treehugger Robot [Thu, 28 Mar 2019 00:35:27 +0000 (00:35 +0000)]
Merge "Fix glob syntax"

5 years agoMerge "Fix message names in dumpsys network_stack"
Remi NGUYEN VAN [Thu, 28 Mar 2019 00:14:31 +0000 (00:14 +0000)]
Merge "Fix message names in dumpsys network_stack"

5 years agoMerge "Preload non-bootclasspath Java lib ClassLoaders."
Steven Moreland [Wed, 27 Mar 2019 22:59:49 +0000 (22:59 +0000)]
Merge "Preload non-bootclasspath Java lib ClassLoaders."

5 years agoShutdown device gracefully when net discharging
Yifan Hong [Thu, 14 Feb 2019 00:00:43 +0000 (16:00 -0800)]
Shutdown device gracefully when net discharging

Instead of checking the presence of power supplies, check
battery status to determine whether it should
shutdown. In detail, shutdown if

battery level == 0 && status != charging

Change-Id: Ie3d93d305e40f2f45d60538e7831f00be0380544
Fixes: 115715604
Test: boots

5 years agoShow signal strength of current active subscription
Malcolm Chen [Wed, 27 Feb 2019 00:49:56 +0000 (16:49 -0800)]
Show signal strength of current active subscription

For grouped primary and opportunistic use-case, if both are active,
mobile signal bar should by default show which one is currently
used for Internet data. Unless carrier set it otherwise -- if they
want to always show signal bar of primary subscription.

Bug: 123780907
Test: manual
Change-Id: I62e298e7b9bdc82dd44f0c8ae783c623e101b0ef
Merged-In: I62e298e7b9bdc82dd44f0c8ae783c623e101b0ef

5 years agoUpdate document of setSubscriptionEnabled public API.
Malcolm Chen [Fri, 8 Mar 2019 23:27:38 +0000 (15:27 -0800)]
Update document of setSubscriptionEnabled public API.

Bug: 126391008
Test: build
Change-Id: Iffb7895f94f8d0b2d071edb1e06c8e99be14be4f
Merged-In: Iffb7895f94f8d0b2d071edb1e06c8e99be14be4f