OSDN Git Service
Lorenzo Colitti [Wed, 27 Sep 2017 04:17:47 +0000 (13:17 +0900)]
Delete the legacy framework code for manipulating ND offload.
This only worked on broadcom devices, and was superseded in
M by a wifi HAL call made by IpManager.
Test: bullhead builds, boots
Change-Id: I711cae7dafe171c2c8b4e84a229adbcad27f3d14
Lorenzo Colitti [Thu, 24 Aug 2017 13:35:10 +0000 (22:35 +0900)]
Declare support for Ethernet if the service is running.
On some devices, support for TYPE_ETHERNET is not specified in
the networkAttributes config resource, even though the device is
capable of supporting Ethernet (e.g., via USB host adapters).
This leads to Ethernet working but various connectivity APIs
behaving as if it was not - for example, no CONNECTIVITY_ACTION
broadcasts will be issues when it connects or disconnects.
Ensure that ConnectivityService always treats Ethernet as
available if the service is running. Currently the service is
started if the device supports FEATURE_ETHERNET or
FEATURE_USB_HOST.
Bug:
37359230
Test: bullhead builds, boots
Test: ConnectivityServiceTest passes
Test: Ethernet is available even if removed from networkAttributes resource
Test: ConnectivityManagerTest CTS test passes
Change-Id: I58801bf4f0bbdc3ff6345ec6bfdc911ce045c8ab
Nicolas Geoffray [Mon, 25 Sep 2017 08:32:51 +0000 (08:32 +0000)]
Merge "Move code around for deleting oat artifacts."
Nicolas Geoffray [Mon, 25 Sep 2017 08:22:34 +0000 (08:22 +0000)]
Merge "Special handling of priv-apps in PMS."
Hans Boehm [Mon, 25 Sep 2017 04:09:30 +0000 (04:09 +0000)]
Merge "Naming fix and add comments"
Treehugger Robot [Sat, 23 Sep 2017 02:39:42 +0000 (02:39 +0000)]
Merge changes from topic "equalizer_1"
* changes:
Fixing code formatting to comform to checkstyle
Add sensor HAL process into dump list
Peng Xu [Sat, 23 Sep 2017 00:17:10 +0000 (00:17 +0000)]
Merge changes from topic "equalizer"
* changes:
Update Java doc of SensorManager.createDirectChannel
sensors: pass sensor handle along with injected event
Peng Xu [Fri, 22 Sep 2017 18:50:33 +0000 (11:50 -0700)]
Fixing code formatting to comform to checkstyle
Fix following types of issue
* over 100 char/line
* missing space
* trailing spaces
* array bracket position
* variable naming convention (some cases)
* indentation
* long expression wrapping operator position
* missing curly brace for one line scope
* function modifier order
Things not changed in this CL:
* Redundant public modifiers.
* A few local variable names.
* Suggested @deprecate but function is actually @removed.
Test: m and m docs
Change-Id: I5c22648888487edaa5954026a166cfd810a8a912
Hans Boehm [Wed, 20 Sep 2017 22:59:12 +0000 (15:59 -0700)]
Naming fix and add comments
Also fix up imports to make repohooks happy and some whitespace issues.
A very small step towards making this code more understandable.
Bug:
65760710
Test: Builds.
Change-Id: I0396c06bb303e0b06ad0cbbbff4fdc1ac527ac6c
Myles Watson [Fri, 22 Sep 2017 16:37:33 +0000 (16:37 +0000)]
Merge changes from topic "avrcp_cherry_picks"
* changes:
Bluetooth: Add AVRCP 1.3 as a developer option for AVRCP version (1/2)
Add equal overloads to some MediaDescription and MediaQueue objects (2/3)
Ajay Panicker [Fri, 1 Sep 2017 18:58:38 +0000 (11:58 -0700)]
Bluetooth: Add AVRCP 1.3 as a developer option for AVRCP version (1/2)
This is requied for the 2012 Mazda 3 carkit as the carkit refuses to send
AVRCP commands other than passthrough commands when the version is anything
else. AVRCP 1.3 is compatible with most carkits on the market and can be
used to get most carkits working at the cost of losing many features.
Bug:
37943083
Test: Set AVRCP 1.3 in developer options and see that SDP and the AVRCP
capabilites have updated to reflect this.
TestTracker: 105915/3975
Change-Id: I637b695e5cd8baa5f054ca0dda81372080a96269
Ajay Panicker [Fri, 21 Jul 2017 20:29:57 +0000 (13:29 -0700)]
Add equal overloads to some MediaDescription and MediaQueue objects (2/3)
Bug:
64686424
Test: Connect to carkit and see that NowPlayingChanged only gets sent when
the queue changes, run cts test
Change-Id: I58c9dd0bf976485a2efefd042cd667ee433e07e1
(cherry picked from commit
6edb68bea68d5f324384f3e9e411118eb8dfc781)
Nicolas Geoffray [Fri, 8 Sep 2017 12:01:40 +0000 (13:01 +0100)]
Special handling of priv-apps in PMS.
If pm.dexopt.priv-apps is set to false, don't do any dexopt on it, and
check the APKs have uncompressed and aligned code.
bug:
30972906
bug:
63920015
Test: works as expected when pm.dexopt.priv-apps is true or false
Change-Id: I72a322defb459549617028e030f1aec997223af5
Treehugger Robot [Fri, 22 Sep 2017 09:04:16 +0000 (09:04 +0000)]
Merge "fixed handling of data URI schemes in Intent.toUri"
Nicolas Geoffray [Fri, 22 Sep 2017 08:01:32 +0000 (09:01 +0100)]
Move code around for deleting oat artifacts.
Test: make and boot
(partially cherry-picked from commit
246dccf9327631597767afe418ce43ae6d07d102)
Change-Id: Id3ce5fdee116df264241dfdee95734ac4bbad7ce
Treehugger Robot [Fri, 22 Sep 2017 02:17:47 +0000 (02:17 +0000)]
Merge "Add checking values not to save illegal value to appwidgets.xml"
Christopher Schuster [Fri, 21 Jul 2017 21:53:52 +0000 (14:53 -0700)]
fixed handling of data URI schemes in Intent.toUri
Data URIs in intents can use schemes with digits and some special
characters (see RFC 2396 and 3986). This patch fixes how these
data URIs are handled by Intent.toUri to support these schemes.
Bug:
63930680
Test: run cts android.content.cts.IntentTest#testUris
Change-Id: I0dbb72325f59f372abba83be9e14c59d5665a053
Signed-off-by: Christopher Schuster <levjj@google.com>
vichang [Thu, 21 Sep 2017 12:42:15 +0000 (12:42 +0000)]
Merge "Remove StructGroupSourceReq"
Hugo Benichi [Thu, 21 Sep 2017 12:00:48 +0000 (12:00 +0000)]
Merge "Implement ConnectivityService TODO and fix many race conditions"
Treehugger Robot [Thu, 21 Sep 2017 11:47:33 +0000 (11:47 +0000)]
Merge "Also support 464xlat on SUSPENDED networks"
Hugo Benichi [Wed, 20 Sep 2017 02:20:14 +0000 (11:20 +0900)]
Implement ConnectivityService TODO and fix many race conditions
This patch implements an outstanding TODO in ConnectivityService to add
synchronization over the map of network request ids to network agent
info objects.
This structure is accessed from multiple threads:
- Binder thread on public aidl methods, most notably via
getDefaultNetwork().
- Internal handler.
This leads to many race conditions that can crash the system server and
reboot the phone if getDefaultNetwork() is called on a Binder thread to
service a public ConnectivityManager api while the default network state
is being updated on the internal handler after losing the default
network.
Bug:
65911184
Test: runtest frameworks-net
Change-Id: I86c830ebd559e31d4576a7606705a056afb064ac
Erik Kline [Thu, 21 Sep 2017 08:28:10 +0000 (17:28 +0900)]
Also support 464xlat on SUSPENDED networks
Test: as follows
- built
- flashed
- booted
- runtest frameworks-net passes
Bug:
65684232
Change-Id: I1b10aab01554b1f926ec7157dba78645fdaff90f
Treehugger Robot [Thu, 21 Sep 2017 08:35:44 +0000 (08:35 +0000)]
Merge "have OffloaderController store and re-push more state"
Erik Kline [Tue, 19 Sep 2017 08:56:10 +0000 (17:56 +0900)]
have OffloaderController store and re-push more state
Test: as follows
- built
- flashed
- booted
- runtest frameworks-net passes
Bug:
29337859
Bug:
32163131
Bug:
64976634
Merged-In: If3a859736a1b3730e4e3d0d2685f3e5432927796
Merged-In: If9afc160fa2f8b5da66cb0a6a35dfcb4f1839d36
Change-Id: Ib1421438a1e748722fc41f1fbfb01ada187bb1c8
(cherry picked from commit
7334b0e2cc5ec7f8803c463a1e674cceb7e4c3ba)
Peng Xu [Wed, 12 Jul 2017 04:12:11 +0000 (21:12 -0700)]
Add sensor HAL process into dump list
Test: use "adb shell am hang --allow-restart" to trigger an ANR,
trace of /vendor/bin/hw/android.hardware.sensors@1.0-service
shows up in /data/anr/traces.txt
Bug:
63096400
Change-Id: If2996eeb215c5339602babd84595107aa4402aed
Merged-In: If2996eeb215c5339602babd84595107aa4402aed
Peng Xu [Wed, 5 Jul 2017 22:21:12 +0000 (15:21 -0700)]
Update Java doc of SensorManager.createDirectChannel
Java doc was left out when addressing API reviewer comments.
This CL fix the discrepancy between the actual logic and java doc.
Bug:
36550285
Test: compiles
Change-Id: I6406892ecdcc5d02f11966fa3fb0b81ed8d3b285
Merged-In: I6406892ecdcc5d02f11966fa3fb0b81ed8d3b285
Tyler Gunn [Wed, 20 Sep 2017 20:19:30 +0000 (20:19 +0000)]
Merge "De-couple data enabled from VT settings."
Tyler Gunn [Wed, 20 Sep 2017 18:20:04 +0000 (18:20 +0000)]
Merge "Add Telephony connection event for call forwarded supp service notice."
Alexey Polyudov [Wed, 24 May 2017 02:54:26 +0000 (19:54 -0700)]
sensors: pass sensor handle along with injected event
Change-Id: I5e8eacfa940c082a14a9876f455c55b84b975086
Merged-In: I5e8eacfa940c082a14a9876f455c55b84b975086
Tyler Gunn [Wed, 7 Jun 2017 22:42:39 +0000 (15:42 -0700)]
Add Telephony connection event for call forwarded supp service notice.
Test: Test Harness
Bug:
33761801
Merged-In: I5503232f90b3255df601be3f16443e8ae311a479
Change-Id: I8ffc8079b43c54594e596f29cec641ca051d4796
Tyler Gunn [Thu, 17 Aug 2017 22:58:47 +0000 (15:58 -0700)]
De-couple data enabled from VT settings.
The existing KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS has the impact
of decoupling whether VT is enabled from whether mobile data is enabled.
Making this TRUE by default.
Adding a new carrier config option to indicate whether VILTE data is metered.
This, coupled with KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS allows
us to ensure that wifi video calls can be made, while still ensuring that
mobile data is not used for VT calls.
A carrier config update needs to be made for the few instances where
KEY_IGNORE_DATA_ENABLED_CHANGED_FOR_VIDEO_CALLS was set true to ensure
that KEY_VILTE_DATA_IS_METERED_BOOL is false in that case.
Test: Manual
Bug:
36900451
Merged-In: I424cd828a7616c2947367bdb4a82a62cf17847e7
Change-Id: I037f8930901907b55e4245a655e0480668549185
Jason Monk [Wed, 20 Sep 2017 13:50:45 +0000 (13:50 +0000)]
Merge "Fix random systemui crashes during boot"
Treehugger Robot [Wed, 20 Sep 2017 12:08:58 +0000 (12:08 +0000)]
Merge "Fix reliability triggering"
Victor Chang [Fri, 11 Aug 2017 16:17:16 +0000 (17:17 +0100)]
Remove StructGroupSourceReq
- Remove the class as part of removing setsockoptGroupSourceReq from
Os.java
- CtsLibcoreTestCases and CtsLibcoreOjTestCases pass on aosp/master
Bug:
32071916
Test: cts-tradefed run cts-dev --module CtsLibcoreTestCases
Test: cts-tradefed run cts-dev --module CtsLibcoreOjTestCases
Merged-In: I132190f47cea9f56ec56a824763f7e2b2cfde893
Change-Id: I132190f47cea9f56ec56a824763f7e2b2cfde893
Jordan Liu [Tue, 19 Sep 2017 23:39:42 +0000 (23:39 +0000)]
Merge "Fix wrong reading the sms lengh of stored long sms in RUIM"
Fyodor Kupolov [Tue, 19 Sep 2017 18:29:14 +0000 (18:29 +0000)]
Merge "Fix AddAccountSettings memory leak"
Tyler Gunn [Tue, 19 Sep 2017 16:28:52 +0000 (16:28 +0000)]
Merge "Fix ImsCallProfile parceling and add protection for invalid parcelables."
Neil Fuller [Wed, 13 Sep 2017 20:59:59 +0000 (21:59 +0100)]
Fix reliability triggering
Fix reliability triggering in the time zone update
feature. The reliability triggering is there to
resume an update check when things go wrong. For
example, if the device is turned off after a
time zone data app is updated but before the time
zone update process has finished pulling the data
out and installing it in /data. The reliability
trigger happens when the device is idle and will
complete the work.
The idle triggering currently doesn't work as it
was implemented incorrectly.
The code has been changed to use the
JobScheduler to trigger on idle and scheduling
has been made explicit.
Unit tests run with:
make -j30 FrameworksServicesTests
adb install -r -g \
"out/target/product/marlin/data/app/FrameworksServicesTests/FrameworksServicesTests.apk"
adb shell am instrument -e package com.android.server.timezone -w \
com.android.frameworks.servicestests \
"com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner"
Test: See above
Test: Manual testing: adb shell am idle-maintenance, adb logcat/adb shell dumpsys timezone
Test: PTS: run pts -m PtsTimeZoneTestCases
Bug:
65657543
Change-Id: Ibb2c537955d09a5d538c50490dae94a518522f19
Merged-In: Ibb2c537955d09a5d538c50490dae94a518522f19
(cherry picked from commit
cd1a109b872f58f5baa0ce8438bf3ddd69eec9fc)
Nicolas Geoffray [Tue, 19 Sep 2017 11:47:58 +0000 (11:47 +0000)]
Merge "Special handling of priv-apps in Zygote."
Charles He [Tue, 19 Sep 2017 07:56:44 +0000 (07:56 +0000)]
Merge changes from topic "vpn-dialog"
* changes:
Unbreak VPN unit tests.
Add alert dialog when always-on VPN disconnects.
Charles He [Wed, 16 Aug 2017 12:14:13 +0000 (13:14 +0100)]
Unbreak VPN unit tests.
VpnTest was broken earlier due to a change to always-on VPN
notifications. This CL adds the corresponding mocks to the unit test to
fix it.
Bug:
36650087
Bug:
65439160
Test: runtest frameworks-net
Change-Id: Icff57c7e927c135d75a7d70ff347a579c5d45134
Merged-In: Icff57c7e927c135d75a7d70ff347a579c5d45134
(cherry picked from commit
3da6a1fc82b7e0c7adc88b92e50cceec8173672e)
Charles He [Tue, 19 Sep 2017 07:50:13 +0000 (07:50 +0000)]
Merge changes from topic "always-on-vpn"
* changes:
Opt-out for always-on VPN: rename API.
Opt-out for always-on VPN
Takamasa Kuramitsu [Mon, 18 Sep 2017 01:49:41 +0000 (10:49 +0900)]
Add checking values not to save illegal value to appwidgets.xml
Symptom:
All AppWidgets on Home screen disppear after appwidgets.xml updated
with invalid value.
Root cause:
The issue occurs when size information of an AppWidget is set to 0
via AppWidgetHostView#updateAppWidgetSize() API.
Since width and height are taken positive padding, so they become
negative number and are sent to
AppWidgetServiceImpl#updateAppWidgetOptions().
In updateAppWidgetOptions(), convert values by
Integer.toHexString() to save widget parameters to appwidgets.xml,
but negative numbers become illegal values for Integer.parseInt().
After device is rebooted, widgets cannot be reloaded because parsing
appwidgets.xml fail by NumberFormatException at Integer.parseInt().
Solution:
When writing the widget's info to appwidgets.xml, check the size
parameters and replace with 0 if they're negative value.
Bug:
65705916
Change-Id: I48f69fbf081201a176ea1093094ba6cdb120e5f5
Hugo Benichi [Tue, 19 Sep 2017 07:12:03 +0000 (07:12 +0000)]
Merge "Wakeup packet events: addressing a few comments"
Treehugger Robot [Tue, 19 Sep 2017 06:28:21 +0000 (06:28 +0000)]
Merge "Fix LinkPropertiesTest.testCompareResult"
Hugo Benichi [Tue, 19 Sep 2017 04:15:26 +0000 (13:15 +0900)]
Wakeup packet events: addressing a few comments
This patch addresses a few post-submit comment for
commits
f562ac34a51dc and
60c9f63b66921.
Bug:
34901696
Bug:
62179647
Test: runtest frameworks-net
Change-Id: I4abec57e0c6bc869dc57b5eb54582dd977b64c30
Treehugger Robot [Tue, 19 Sep 2017 03:12:18 +0000 (03:12 +0000)]
Merge "Remove unused variable from screencap."
Pengquan Meng [Tue, 19 Sep 2017 01:14:34 +0000 (01:14 +0000)]
Merge "Incorrect decoding when TP-OA contains non-integer information"
Erika Avenberg [Sat, 30 Aug 2014 10:00:47 +0000 (12:00 +0200)]
Incorrect decoding when TP-OA contains non-integer information
When receiving a GSM SMS message where the TP-Originating-Address
(TP-OA) field contains non-integer information, it is currently
decoded incorrectly.
This CL adds support for decoding BCD according to spec:
ETSI TS 123 040 V9.3.0
Section: 9.1.2.3 Semi-octet representation
"If a mobile receives an address field containing non-integer
information in the semi-octets other than "1111" (e.g. 1110)
it shall display the semi-octet as the representation given
in GSM 44.008 [12] under "called BCD number", viz 1010="*",
1011="#", 1100="a", 1101="b", 1110="c"."
Bug:
65042708
Test: runtest --path frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/GsmSmsTest.java --test-method testAddressing
Change-Id: Ied2d6ca4d84d5c3ca6cc5c4d9875d2ff2a8e5df9
Treehugger Robot [Mon, 18 Sep 2017 17:37:26 +0000 (17:37 +0000)]
Merge "Fix extracting 32-bit uuid error via calling method uuidToBytes"
Ruina Liu [Sat, 22 Jul 2017 10:41:48 +0000 (18:41 +0800)]
Fix extracting 32-bit uuid error via calling method uuidToBytes
A new defined method of uuidToBytes is used to convert
Bluetooth uuid to bytes in the case of BLE advertising.
But the most significant 16 bits of a 32-bit uuid
will be cleared after the and operations with
0X0000FFFF00000000L in the function of
getServiceIdentifierFromParcelUuid.
0XFFFFFFFF00000000L should be used as bit mask.
Change-Id: I83e22ffbecd718540e644289fee12bf9c3b66305
Test: Advertise with payload contains 32-bit uuid
Treehugger Robot [Fri, 15 Sep 2017 16:38:38 +0000 (16:38 +0000)]
Merge "Fix a no-op uninstall being treated as a failure"
Neil Fuller [Thu, 14 Sep 2017 08:34:56 +0000 (09:34 +0100)]
Fix a no-op uninstall being treated as a failure
Treat a stageUninstall() doing nothing as a success, not a
failure. This prevents the system retrying the uninstall
later.
Unit tests run with:
make -j30 FrameworksServicesTests
adb install -r -g \
"out/target/product/marlin/data/app/FrameworksServicesTests/FrameworksServicesTests.apk"
adb shell am instrument -e package com.android.server.timezone -w \
com.android.frameworks.servicestests \
"com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner"
Test: See above
Test: Manual testing, adb dumpsys timezone
Test: PTS: run pts -m PtsTimeZoneTestCases
Bug:
65657176
Merged-in: Ifd205da90e848552711ac3f4207cd22ad2c2747b
Change-Id: Ifd205da90e848552711ac3f4207cd22ad2c2747b
(cherry picked from commit
8e27c9226b82f41279ee6c108d2b06bb6f1cef5e)
Rubin Xu [Fri, 15 Sep 2017 10:51:39 +0000 (11:51 +0100)]
Fix LinkPropertiesTest.testCompareResult
Test: runtest frameworks-core -c android.net.LinkPropertiesTest
Change-Id: Ie97b7a7a1557b14296d7c33e98991cdede8463b0
Hall Liu [Fri, 15 Sep 2017 00:21:58 +0000 (00:21 +0000)]
Merge "API council suggested edits, part 3"
Hall Liu [Fri, 15 Sep 2017 00:21:13 +0000 (00:21 +0000)]
Merge "Apply suggested edits to the file-download API"
Treehugger Robot [Thu, 14 Sep 2017 23:41:34 +0000 (23:41 +0000)]
Merge changes Id931d441,I83faf974
* changes:
Zygote: Improve logging and error handling during connections.
Zygote: Fix race condition on package preloads.
Treehugger Robot [Thu, 14 Sep 2017 22:59:37 +0000 (22:59 +0000)]
Merge changes from topic "incl_svc_parsing_fix"
* changes:
Fix included service parsing (3/3)
Bluetooth: fix typo in comment
Hall Liu [Sat, 9 Sep 2017 01:02:38 +0000 (18:02 -0700)]
API council suggested edits, part 3
* MbmsException no longer thrown from the common methods, and the error
codes are now containined in MbmsError.
* In order to avoid ANRs while processing download-done broadcasts,
don't perform arbitrary moves when a download is done. Instead, move
into a staging directory and let the app handle it.
Bug:
30981736
Test: testapps
Change-Id: I9416f28b4f24f89af1da6f56a93ea0f0e4ea3878
Hall Liu [Sat, 2 Sep 2017 00:59:15 +0000 (17:59 -0700)]
Apply suggested edits to the file-download API
* Rename Manager -> Session
* Add Handler for callbacks in download flow
* Separate out registering a state callback into another method
* Rename dispose -> close, implement AutoClosable
* No more thrown MbmsExceptions
* Add sanity check for temp file root
* Remove the getNames method, replace with getNameForLocale
Bug:
30981736
Test: testapps
Change-Id: I1a2054d79c934bc4929464de4a644b6960db47e9
Jakub Pawlowski [Thu, 14 Sep 2017 18:54:59 +0000 (11:54 -0700)]
Fix included service parsing (3/3)
Bug:
65637368
Test: sl4a GattIncludedServiceTest
Change-Id: Idb967df9d5064b0532db7f5c250f677d1dbbc54c
Hall Liu [Thu, 14 Sep 2017 19:34:11 +0000 (19:34 +0000)]
Merge "Make changes to MBMS Streaming APIs per recommendations"
Jakub Pawlowski [Thu, 14 Sep 2017 15:51:44 +0000 (08:51 -0700)]
Bluetooth: fix typo in comment
Test: none
Change-Id: I48c674049df88285268145d4140870eb4ab79a62
Jakub Pawlowski [Thu, 14 Sep 2017 19:24:06 +0000 (19:24 +0000)]
Merge "Bluetooth: fix parameter name in onConnectionUpdated"
Jakub Pawlowski [Thu, 14 Sep 2017 15:24:15 +0000 (08:24 -0700)]
Bluetooth: fix parameter name in onConnectionUpdated
Test: compilation
Change-Id: I625e4ca63477b795310ebb42ca5e9a0549523cc5
Neil Fuller [Thu, 14 Sep 2017 14:07:59 +0000 (14:07 +0000)]
Merge "Finalize package intents used to trigger tz update"
Neil Fuller [Wed, 13 Sep 2017 15:01:58 +0000 (16:01 +0100)]
Finalize package intents used to trigger tz update
Finalize the package intents used to trigger tz update and
improve the documentation.
Bug:
64018084
Test: PTS: run pts -m PtsTimeZoneTestCases
Change-Id: Ifba9dea1d6d8818f875d4c7efba09d77c8e6d66a
Merged-In: Ifba9dea1d6d8818f875d4c7efba09d77c8e6d66a
(cherry picked from commit
228dc6cfefd06936657fa39848f7ee73162def8f)
Hugo Benichi [Thu, 14 Sep 2017 11:59:58 +0000 (11:59 +0000)]
Merge changes I4719b4dc,I0308cdf4,I38db1bb7
* changes:
IpManagerTest: fix flaky test
Fix flaky NsdManagerTest
Boostrap test for NetworkMonitor
Hugo Benichi [Thu, 14 Sep 2017 11:53:02 +0000 (11:53 +0000)]
Merge changes Ie2676b20,Ie8db6f85
* changes:
Connectivity metrics: add WakeupStats events
Connectivity metrics: collect NFLOG wakeup events
Hugo Benichi [Tue, 5 Sep 2017 04:34:48 +0000 (13:34 +0900)]
Connectivity metrics: add WakeupStats events
This patch defines a new WakeupStats event in ipconnectivity.proto and
populates these events from the NFLOG wakeup events stored in
NetdEventListenerService.
There is one WakeupStats object per known interface on which ingress
packets arrive and may wake the system up.
Example from $ adb shell dumpsys connmetrics list:
UPDATEME
...
WakeupStats(wlan0, total: 58, root: 0, system: 3, apps: 38, non-apps: 0, unrouted: 17, 6111s)
WakeupEvent(13:36:31.686, iface wlan0, uid -1)
WakeupEvent(13:38:50.846, iface wlan0, uid -1)
WakeupEvent(13:39:16.676, iface wlan0, uid 10065)
WakeupEvent(13:40:32.144, iface wlan0, uid 1000)
WakeupEvent(13:40:35.827, iface wlan0, uid 1000)
WakeupEvent(13:40:47.913, iface wlan0, uid 10004)
WakeupEvent(13:40:52.622, iface wlan0, uid 10014)
WakeupEvent(13:41:06.036, iface wlan0, uid 10004)
...
Bug:
34901696
Bug:
62179647
Test: runtest frameworks-net
Change-Id: Ie2676b20bfb411a1902f4942643df0c20e268d99
Narayan Kamath [Wed, 5 Jul 2017 13:45:38 +0000 (14:45 +0100)]
Zygote: Improve logging and error handling during connections.
Before this change, we were throwing a checked exception on success
and returning on failure. This made it hard to figure out where / when
something was going wrong. This change switches things around to throw
a RuntimeException when something goes wrong and to return a Runnable
on success. This lets us make stronger assertions in both the parent
and the child process about their state and expected return values.
This change also upgrades the severity of several errors that we would
earlier just ignore. We will now reject the command and terminate the
connection to the client when we encounter these errors such as:
- Malformed arguments
- Any ZygoteSecurityException, such as thown thrown by
applyUidSecurityPolicy and applyInvokeWithSecurityPolicy.
- Any error in setting up pipes etc. to facilitate communication
with child processes.
(cherry picked from commit
bf99d06003e76469a99269816babe16a22d83b89)
Bug:
13618569
Test: Manual
Merged-In: Id931d44135ae2e4ede1bbac6a4b187f6c139e1fd
Change-Id: Id931d44135ae2e4ede1bbac6a4b187f6c139e1fd
Narayan Kamath [Mon, 3 Jul 2017 13:12:26 +0000 (14:12 +0100)]
Zygote: Fix race condition on package preloads.
Before this change, ZygoteProcess.preloadPackageForAbi returned
as soon as the command was written to the zygote socket and not
after the preload completed. This meant that there was a small
window of time before the server side of the socket polled its FDs
where a second command could be written to the zygote socket. This
would lead to only one of the commands being processed and the
other being dropped. The client side of that socket would then wait
forever for a response and bring down the system once the watchdog
timeout was hit.
Example failure case :
--------------
system_server:send command(preloadPackage)
system_server:send command(fork)
zygote:poll & process command(preloadPackage) // the fork command is dropped.
Example of normal operation :
------------------
system_server:send command(preloadPackage)
zygote:poll & process command(preloadPackage)
system_server:send command(fork)
zygote:poll & process command(fork)
This change makes preloadPackageForAbi synchronous, which ensures
that each POLLIN event corresponds to precisely one command.
(cherry picked from commit
24a3306c32aa3860184025638f3abaab96cc9153)
Bug:
62886909
Bug:
13618569
Test: Manual
Contributed-By: yuqianyu@huawei.com
Merged-In: I83faf974c9a70a6ab18323f692c1981784e4c56a
Change-Id: I83faf974c9a70a6ab18323f692c1981784e4c56a
Treehugger Robot [Wed, 13 Sep 2017 22:09:54 +0000 (22:09 +0000)]
Merge "Abort connecting to native daemon during shutdown"
Hall Liu [Wed, 13 Sep 2017 20:40:34 +0000 (20:40 +0000)]
Merge "Unhide EMBMS download API"
Hall Liu [Wed, 13 Sep 2017 19:55:58 +0000 (19:55 +0000)]
Merge changes from topics "embms-0804-adjustments", "prepare-download-unhide"
* changes:
Make EMBMS adjustments for 08/04
Prepare EMBMS apis for un-hiding
Treehugger Robot [Wed, 13 Sep 2017 19:03:47 +0000 (19:03 +0000)]
Merge "Bluetooth: thread-safe callback invocation"
Jakub Pawlowski [Wed, 13 Sep 2017 16:33:34 +0000 (09:33 -0700)]
Bluetooth: thread-safe callback invocation
Bug:
65596701
Test: manual
Change-Id: I92a436328a3070ea842e8e652891e485406c2ed7
Treehugger Robot [Wed, 13 Sep 2017 17:31:30 +0000 (17:31 +0000)]
Merge "Bluetooth: fix GATT race conditions when using Handler"
Jakub Pawlowski [Tue, 12 Sep 2017 21:48:30 +0000 (14:48 -0700)]
Bluetooth: fix GATT race conditions when using Handler
Bug:
65596701
Test: manual
Change-Id: Id703cea0543626bdd5a583da95615b650bbcc331
Nicolas Geoffray [Wed, 13 Sep 2017 13:21:00 +0000 (14:21 +0100)]
Special handling of priv-apps in Zygote.
If pm.dexopt.priv-apps is set to false, disable verifier and
only allow loading oat files from system.
bug:
30972906
bug:
63920015
Test: works as expected when pm.dexopt.priv-apps is true or false
Change-Id: Ib9e80c9b7b4106e82c0b9d1c7fbb8065c190ac1f
Hugo Benichi [Thu, 7 Sep 2017 05:18:33 +0000 (14:18 +0900)]
IpManagerTest: fix flaky test
Reset the callback mock for every onLinkPropertiesChange expected when
pushing address updates on the BaseNetworkObserver.
Bug:
32561414
Bug:
62918393
Test: runtest frameworks-net, IpManagerTest passes 200 times in a row
Change-Id: I4719b4dc86044438243887634191c2d21686b80f
Hugo Benichi [Fri, 8 Sep 2017 00:03:54 +0000 (09:03 +0900)]
Fix flaky NsdManagerTest
Bad synchronization between the mock handler and the test assertions
were causing testDiscoverService() to sometime fails (1/50 ~ 1/100 repro
rate).
Bug:
32561414
Bug:
62918393
Test: runtest frameworks-net, NsdManager#testDiscoverService now passes
1000 times without errors.
Change-Id: I0308cdf48fc6bdc2fc9b4e8f7d5241a1cf2ea443
Rubin Xu [Wed, 13 Sep 2017 09:35:04 +0000 (09:35 +0000)]
Merge "Refactor CompareResult<> class and its call sites"
Nicolas Geoffray [Wed, 13 Sep 2017 08:08:47 +0000 (08:08 +0000)]
Merge "Rename debugFlags to runtimeFlags."
Hugo Benichi [Mon, 31 Jul 2017 03:58:20 +0000 (12:58 +0900)]
Boostrap test for NetworkMonitor
This will finally allow to write captive portal detection unit tests.
Bug:
32561414
Bug:
62918393
Test: runtest frameworks-net
Change-Id: I38db1bb79ae80a82b4199dc9cb1b56257e0cf222
Tyler Gunn [Tue, 12 Sep 2017 20:39:38 +0000 (13:39 -0700)]
Fix ImsCallProfile parceling and add protection for invalid parcelables.
Two things:
1. The writeToParcel and readFromParcel in the ImsCallProfile never
worked; they were not parceling the Bundle properly.
2. Ensuring on writeToParcel that invalid Bundle contents are removed and
not sent across a Binder interface.
The existing Bundle.filterValues method accomplishes this by ensuring only
primitive types and android.* namespace parcelables are included in the
Bundle. We use this to ensure that when the ImsCallProfile instances cross
the binder call boundary, package-local Parcelables don't cause the
Bundle to be invalidated when unmarshaled in a place where the
pacakge-local parcelable is not available.
Test: Manual, also wrote new unit tests
Bug:
65562929
Change-Id: Iea982d14a053414b9a4daba998c021c61902119d
Nicolas Geoffray [Thu, 7 Sep 2017 13:13:29 +0000 (14:13 +0100)]
Rename debugFlags to runtimeFlags.
Also now pass the flags to the forked process through --runtime-flags instead
of converting to command line arguments and converting back to an integer.
bug:
30972906
bug:
63920015
Test: builds
Change-Id: I7f10c43dd916ca2d3b9b5141f17261eb7b64f49a
Treehugger Robot [Tue, 12 Sep 2017 11:12:53 +0000 (11:12 +0000)]
Merge "Patch incoming LinkProperties before it's visible to the outside"
Rubin Xu [Mon, 11 Sep 2017 14:21:10 +0000 (15:21 +0100)]
Patch incoming LinkProperties before it's visible to the outside
Otherwise we risk a race condition when we are fixing the LinkProperties
routes, other parts of ConnectivityService is reading the field at the
same time.
Test: runtest frameworks-net -c com.android.server.ConnectivityServiceTest
Test: runtest frameworks-core -c android.net.LinkPropertiesTest
Bug:
65529483
Bug:
35995111
Change-Id: I539578703570a901e0a5dff0155422ca78c52401
Treehugger Robot [Tue, 12 Sep 2017 06:10:45 +0000 (06:10 +0000)]
Merge "Check for IControllOffload.getServer() returning null"
Erik Kline [Mon, 11 Sep 2017 07:33:27 +0000 (16:33 +0900)]
Check for IControllOffload.getServer() returning null
Test: as follows
- built
- flashed
- booted
- runtest frameworks-net passes
Bug:
29337859
Bug:
65529504
Merged-In: I5a57a9fd14dc53eaf1722fbc9a972f4f73280497
Merged-In: Ib2d1862367145260ac83f14d181646eb827538f8
Change-Id: I671487344000f1f2db92b8e4a693c096b680830c
(cherry picked from commit
87b3bfd5f2d3d0ccfc3ee1279b496d4ff289e38f)
Hugo Benichi [Mon, 4 Sep 2017 04:24:43 +0000 (13:24 +0900)]
Connectivity metrics: collect NFLOG wakeup events
This patch stores NFLOG packet wakeup events sent by Netd to the system
server into a ring buffer inside NetdEventListenerService. The content
of this buffer is accessible by $ dumpsys connmetrics or $ dumpsys
connmetrics list, and is added to bug reports.
The wakeup event buffer stores currently uid and timestamps.
Bug:
34901696
Bug:
62179647
Test: runtest frameworks-net, new unit tests
Change-Id: Ie8db6f8572b1a929a20398d8dc03e189bc488382
Jordan Liu [Mon, 11 Sep 2017 22:52:20 +0000 (22:52 +0000)]
Merge "Show 3G data icon for TD-SCDMA network type"
Treehugger Robot [Mon, 11 Sep 2017 21:34:53 +0000 (21:34 +0000)]
Merge "AAPT2: Fix processing of quotes in XML"
Treehugger Robot [Mon, 11 Sep 2017 21:10:12 +0000 (21:10 +0000)]
Merge "Revert "OMS: fix listener callbacks triggered by changes to target package""
Wileen Chiu [Fri, 18 Sep 2015 22:17:54 +0000 (15:17 -0700)]
Show 3G data icon for TD-SCDMA network type
- The data annunciator on the UI shows up as
"G" instead of "3G"
- Map the 3G telephony icon to network type
TD-SCDMA
Bug:
36802489
Test: manual
Change-Id: I63a0e54aab7fda2bcc6f098bb0b43799aad2f6c2
Adam Lesinski [Fri, 30 Jun 2017 00:53:36 +0000 (17:53 -0700)]
AAPT2: Fix processing of quotes in XML
When processing attributes in XML, quotes can't be used to mark a
section as whitespace preserving, so the assumption should be that the
entire string is whitespace preserving, which makes quote characters
literals.
Bug:
62840718
Bug:
62840406
Test: make aapt2_tests
Change-Id: I4afff02148b5b8e78833abf1f323c2f5325d6155
Treehugger Robot [Mon, 11 Sep 2017 19:44:31 +0000 (19:44 +0000)]
Merge "Add ims registration status"
Adam Lesinski [Mon, 11 Sep 2017 19:05:04 +0000 (19:05 +0000)]
Revert "OMS: fix listener callbacks triggered by changes to target package"
Some internal tests broke due to this. Revert for now to unblock, and investigate why this occurred.
This reverts commit
f08ad98acbb83abf7d30b6583bdfc188145a4215.
Bug:
65319218
Change-Id: I1bfb2d4937708441eac2ee5909717abec10f4971
nharold [Mon, 11 Sep 2017 17:44:34 +0000 (17:44 +0000)]
Merge "Un-hide TelephonyManager.getSignalStrength()"