Commit Graph

4749 Commits

Author SHA1 Message Date
Automerger Merge Worker
7fabca1b35 Merge "Expose ModemActivitiyInfo to system API" am: 5910f6dd65 am: 340397814a
Change-Id: I5ec18c82caa066e2aced3432756cd0811ff4a9cb
2019-12-19 18:42:52 +00:00
Chen Xu
5910f6dd65 Merge "Expose ModemActivitiyInfo to system API" 2019-12-19 18:01:46 +00:00
Automerger Merge Worker
813760c954 Merge "Always use a positive value for timestamp" am: bfe66d9800 am: e7fad0b026
Change-Id: Ic381b839fd0cde8e924aa967059cf7702dcaf17a
2019-12-19 17:24:28 +00:00
joker.yang
6955f0c97e Always use a positive value for timestamp
on go device when try to get timestamp, the value over-followed sometimes
as a result, GtsIncidentManagerTestCases would fail due to a negative timestamp

Bug: 142513252
Change-Id: I7d5e701bb8bf4e788a718e093681f97b95cb8551
2019-12-18 21:31:01 -08:00
Automerger Merge Worker
ba95108b92 Merge "Security Fix: Race Condition + NPE" into qt-qpr1-dev am: 8a00254d27
Change-Id: Ieff88bbc396d67d484a217d9497f058ba946f6a1
2019-12-19 00:43:01 +00:00
Tej Singh
0c4a21e4ea Security Fix: Race Condition + NPE
ShellSubscriber is lazily initialized, and multiple threads can attempt
to write the same pointer since it is not initialized in threadsafe
code. Additionally, there is an NPE that crashes statsd when a null
ResultReceiver is passed in, which allows an attacker to repeatedly
crash statsd until the race condition occurs. More details, including a
proof of concept attack, are in the bug.

Bug: 141243101
Test: repro steps in bug no longer crash statsd
Test: with only the lock on iniitiallizing mShellSubscriber, statsd
still crashed but after ~7 minutes, no race condition occurred.

Change-Id: Ib56f888620497fb41d1627c07867693eb251738e
2019-12-18 12:58:02 -08:00
Automerger Merge Worker
77420b1a37 Merge "Revert "Deprecate Data Command in Android"" am: 609f65048f am: 81ca5f3ee8
Change-Id: I69363e5070e5cb9218075555f69b86a39dbb6d13
2019-12-18 20:06:35 +00:00
Treehugger Robot
609f65048f Merge "Revert "Deprecate Data Command in Android"" 2019-12-18 19:41:49 +00:00
Chen Xu
9663781a86 Expose ModemActivitiyInfo to system API
ModemActivityInfo is used for batteryStatusService which is part of
system service. To prepare telephony to be an mainline module, we
should expose ModemActivityInfo to systemAPI

1. remove getConsumedPower API as we are missing modem support, API
today only report 0
2. isValid API is introduced to cover modem issues before. Do not
expose this for now.

Bug: 140908357
Test: Build
Change-Id: I6e1b0daa2e0ce23b9fd55f0dd7037631b93eb7a5
(cherry picked from commit 7322e4a7ce)
Merged-in: I6e1b0daa2e0ce23b9fd55f0dd7037631b93eb7a5
2019-12-18 10:45:00 -08:00
Shuo Qian
b179a7fc2f Revert "Deprecate Data Command in Android"
This reverts commit 5c4e7b81b5.

Reason for revert: <b/146461873>

Bug: 146461873

Change-Id: I8bd10333f2014e52e1d3122c5b9dc895a5d6c658
2019-12-18 17:27:21 +00:00
Automerger Merge Worker
57f0391e52 Merge "unique_fd is passed by value in AIDL interfaces" am: 6316f348e7 am: 7aa79697cd
Change-Id: I3dc4eb33e0983fff27082ae0852f0a239e9fc957
2019-12-18 06:36:45 +00:00
Jiyong Park
6316f348e7 Merge "unique_fd is passed by value in AIDL interfaces" 2019-12-18 06:14:38 +00:00
Jiyong Park
573fd3dfe0 unique_fd is passed by value in AIDL interfaces
FileDescriptor type in AIDL was translated into const unique_fd& in C++.
Now, it is unique_fd, i.e. passed by value, to make it easier to keep it
beyond the scope of the call.

Bug: 144943748
Test: m

Exempt-From-Owner-Approval: cherry-pick from internal

Merged-In: I2b87761401361f9cf96cdda070f26e70a5c6c935
(cherry picked from commit b8ba23418a)
Change-Id: I2b87761401361f9cf96cdda070f26e70a5c6c935
2019-12-18 05:32:25 +00:00
Automerger Merge Worker
81b66fc0b5 Merge "Deprecate Data Command in Android" am: 65943dbc41 am: 3c4fec229a
Change-Id: I14ded4a01c22b6537f5f472532af795e4123b1a4
2019-12-17 17:41:38 +00:00
Shuo Qian
5c4e7b81b5 Deprecate Data Command in Android
Please use adb shell cmd phone data enable/disable instead.

Bug: 145553588
Test: adb shell commands; manual
Change-Id: I7d1ab779bd6c08dc8c564dc5f3f5d9e165ae39ed
2019-12-16 17:09:54 -08:00
Automerger Merge Worker
a80641662a Merge "Add new UnsupportedAppUsage annotation as lib dependency." am: 938bc05883 am: 05057bd860
Change-Id: I88368905adc217e27b3e4ee238f3ee472925f80a
2019-12-12 14:21:36 +00:00
Artur Satayev
700e08b291 Add new UnsupportedAppUsage annotation as lib dependency.
Bug: 145132366
Test: m
Change-Id: Ibb7f8424186149365354a96249c06c9fccde66bd
Merged-In: Ibb7f8424186149365354a96249c06c9fccde66bd
2019-12-11 19:44:16 +00:00
Automerger Merge Worker
e08205b609 Merge "track and report packages with undecorated remoteviews" into qt-qpr1-dev am: 1eb5828022
Change-Id: I24e5eeecdac3a9d72d73fb5bca9cdc7ec202f94c
2019-12-10 18:59:17 +00:00
Chris Wren
bc487b5759 track and report packages with undecorated remoteviews
print query results with:
  adb shell dumpsys notification --remote-view-stats

test the pulled atom with:
  make statsd_testdrive
  ./out/host/linux-x86/bin/statsd_testdrive 10066

Bug: 144855217
Test: atest frameworks/base/services/tests/uiservicestests/src/com/android/server/notification
Change-Id: I6dcc9871f78298a8b213a051223c7316f8feefc5
Merged-In: I773378fc7cfb47a9f9c7495404ddafa63f39cfaf
2019-12-09 15:48:14 -05:00
Hall Liu
a2a1150aa8 Merge "Remove telephony hidden api usages from commands" am: e07c943cfd
am: 798e77ff77

Change-Id: I2cf125ea80b0c27abe9e5f415aa1c71d688967f1
2019-12-05 19:19:46 -08:00
Hall Liu
e3b535b98c Remove telephony hidden api usages from commands
Remove usages of Telephony hidden APIs from Telecom's debugging commands

Fixes: 141576016
Test: manual
Change-Id: Ia1184f804b3b03104dd5c911b15c8c28190b2395
Merged-In: Ia1184f804b3b03104dd5c911b15c8c28190b2395
2019-12-05 18:21:06 -08:00
Hector Dearman
25af773ac6 Reland Perfetto upload logging atoms DO NOT MERGE
Initial state:
- I landed ag/9652310 (the original change) downstream
- I cherry-picked this change on upstream to aosp/1158971
- This cherry-pick had an incorrect Merged-In tag referring to ag/7911242
- This cl was present between mirror-aosp-master and master internally

Branch                      CL
aosp/master                 (aosp/1158971)
    \/
internal/mirror-aosp-master (aosp/1158971)
    \/
internal/[---]              Nothing since ag/7911242 was here
    ||                      already automerger skipped our change
    \/
internal/master             (ag/9652310)
    \/
[various children]          (ag/9652310)

See:
https://android-build.googleplex.com/builds/automerger/graph/project/googleplex-android/platform/frameworks/base

How this will fix the issue:
- The revert will go everywhere aosp/1158971 did
- The reland will go everywhere aosp/1158971 did plus to internal/master

This reverts commit 8ed72df3d8e21c06d8b1b848d6e58c15b251d25a.

Merged-In: Ia40303aa2a669c301fab912b0b0bdf5ec1259caf
Change-Id: I3c061fef4f103f0f83147d56ed8019dcb39a7711
2019-12-04 21:56:05 +00:00
satayev
fca52b7e36 Merge "Swap default for disableTestApiChecks." am: 972f7adfbf
am: f814dc9c05

Change-Id: Ic66116e0c77d34ae970db5b05d6e66dacb0c3482
2019-12-04 09:31:57 -08:00
Tyler Gunn
bed4e9789c Merge "Car mode InCallService changes." am: 1d4fcf1703
am: 920d3e0fbf

Change-Id: I8c8000e59819f5158194f2a3d50c74524e075eda
2019-12-04 09:24:43 -08:00
satayev
f814dc9c05 Merge "Swap default for disableTestApiChecks."
am: 972f7adfbf

Change-Id: Ic6ab43ecd38ab8e7f0437b0e9e3db1bc400d26c3
2019-12-04 09:16:09 -08:00
satayev
972f7adfbf Merge "Swap default for disableTestApiChecks." 2019-12-04 17:10:17 +00:00
Tyler Gunn
920d3e0fbf Merge "Car mode InCallService changes."
am: 1d4fcf1703

Change-Id: If7f239e57df1e6131b36548d0ebb06375fcffeaf
2019-12-04 08:57:36 -08:00
Tyler Gunn
1d4fcf1703 Merge "Car mode InCallService changes." 2019-12-04 16:50:47 +00:00
Hector Dearman
f35827bc17 DO NOT MERGE resolve merge conflicts of 872009a3bc to qt-qpr1-dev-plus-aosp
Test: I solemnly swear I tested this conflict resolution.
Bug: None
Change-Id: Ia40303aa2a669c301fab912b0b0bdf5ec1259caf
2019-12-04 14:54:25 +00:00
Artur Satayev
fdc9fe8dc0 Swap default for disableTestApiChecks.
There are more runners than those updated in tradefed/testtype/, which donot/cannot push --no-test-api-checks arg to `am instrument`. Instead reverse the default, so that by default `am instrument` disables test api enforcement policy.

Test: atest CtsHiddenApiBlacklistApi27TestCases \
        CtsHiddenApiBlacklistApi28TestCases \
        CtsHiddenApiBlacklistCurrentApiTestCases \
        CtsHiddenApiBlacklistDebugClassTestCases \
        CtsHiddenApiBlacklistTestApiTestCases \
        CtsAppSecurityHostTestCases:android.appsecurity.cts.ExternalStorageHostTest#testMediaEscalation \
        CtsAppSecurityHostTestCases:android.appsecurity.cts.StorageHostTest#testVerify \
        CtsAppSecurityHostTestCases:android.appsecurity.cts.DirectBootHostTest#testDirectBootNative
Exempt-From-Owner-Approval: small fix
Bug: 133832325
Change-Id: Id1870cdd4bb0a51bddede24afd7f87d6e5ec766c
2019-12-04 14:31:07 +00:00
Hector Dearman
872009a3bc Merge "Reland Perfetto upload logging atoms DO NOT MERGE"
am: ad3e08aa69

Change-Id: Ieef0b8d98b43cc3897bec8cca0bbe223f510a7d6
2019-12-03 08:55:59 -08:00
Hector Dearman
ad3e08aa69 Merge "Reland Perfetto upload logging atoms DO NOT MERGE" 2019-12-03 15:02:24 +00:00
Hector Dearman
8d4a16cfc6 Reland Perfetto upload logging atoms DO NOT MERGE
Initial state:
- I landed ag/9652310 (the original change) downstream
- I cherry-picked this change on upstream to aosp/1158971
- This cherry-pick had an incorrect Merged-In tag referring to ag/7911242
- This cl was present between mirror-aosp-master and master internally

Branch                      CL
aosp/master                 (aosp/1158971)
    \/
internal/mirror-aosp-master (aosp/1158971)
    \/
internal/[---]              Nothing since ag/7911242 was here
    ||                      already automerger skipped our change
    \/
internal/master             (ag/9652310)
    \/
[various children]          (ag/9652310)

See:
https://android-build.googleplex.com/builds/automerger/graph/project/googleplex-android/platform/frameworks/base

How this will fix the issue:
- The revert will go everywhere aosp/1158971 did
- The reland will go everywhere aosp/1158971 did plus to internal/master

This reverts commit 8ed72df3d8e21c06d8b1b848d6e58c15b251d25a.
2019-12-03 15:01:33 +00:00
Hector Dearman
bab05b054d Merge "Revert "Add Perfetto upload logging atoms"" 2019-12-03 10:05:07 +00:00
Mark Tabry
529d73bd4f Add AIDL interface and puller implementation for automotive devices.
Changes:
  - Adds hidden ICarStatsService AIDL API.
  - Adds CarStatsPuller for pulling atoms from ICarStatsService.
  - Pulls VmsClientStats via CarStatsPuller.

Bug: 141697665
Test: Manual testing on hawk using statsd_testdrive
Change-Id: I44e104d430f64b1bd3dce96e9749df79ab3d2fbf
Merged-In: I44e104d430f64b1bd3dce96e9749df79ab3d2fbf
(cherry picked from commit 9dc13578f7)
2019-12-02 13:08:13 -08:00
Tyler Gunn
f701f7a765 Car mode InCallService changes.
1. Grant ENTER_CAR_MODE and CONTROL_INCALL_EXPERIENCE permissions to the
shell identity for use within CTS tests.
2. Remove un-needed Telecom shell command.

Test: unit tests, telecom CTS tests, manual testing
Bug: 144345414
Change-Id: I54a2e723d6ef9552117e6cadf4ab7c449dd5e3cb
2019-11-26 13:43:53 -08:00
Mark Tabry
c4755ff9a0 Merge "Add AIDL interface and puller implementation for automotive devices." into qt-qpr1-dev-plus-aosp 2019-11-25 18:31:34 +00:00
Mark Tabry
e441ef5480 Add AIDL interface and puller implementation for automotive devices.
Changes:
  - Adds hidden ICarStatsService AIDL API.
  - Adds CarStatsPuller for pulling atoms from ICarStatsService.
  - Pulls VmsClientStats via CarStatsPuller.

Bug: 141697665
Test: Manual testing on hawk using statsd_testdrive
Change-Id: I44e104d430f64b1bd3dce96e9749df79ab3d2fbf
Merged-In: I44e104d430f64b1bd3dce96e9749df79ab3d2fbf
(cherry picked from commit 9dc13578f7)
2019-11-22 12:48:35 -08:00
Mark Tabry
b01c08d0a6 Define new atoms for Vehicle Maps Service.
Bug: 140889664
Test: N/A
Change-Id: I6bf37ed236e81fbcca50046b5a9b649685affb4a
Merged-In: I6bf37ed236e81fbcca50046b5a9b649685affb4a
(cherry picked from commit a824a64be1)
2019-11-20 23:50:45 +00:00
Mark Tabry
8a4a9989fc Define new atoms for Vehicle Maps Service.
Bug: 140889664
Test: N/A
Change-Id: I6bf37ed236e81fbcca50046b5a9b649685affb4a
Merged-In: I6bf37ed236e81fbcca50046b5a9b649685affb4a
(cherry picked from commit a824a64be1)
2019-11-19 13:24:26 -08:00
Hector Dearman
38b8b858a7 Revert "Add Perfetto upload logging atoms"
This reverts commit 9df31fae0e.

Reason for revert: Merged-In was incorrect

Merged-In: I8f41d72c8f96a004911ef68491de8a214da4db24
Change-Id: I886a900bdc99f4b9cc06ce83d51398b546288600
2019-11-19 16:48:10 +00:00
satayev
5c8ed7f6e7 Merge "Add --no-test-api-acces to am instrument."
am: 188abff5b2

Change-Id: I4b345fd330ba92caa96781f64f703a057adad2b0
2019-11-12 10:49:01 -08:00
satayev
188abff5b2 Merge "Add --no-test-api-acces to am instrument." 2019-11-12 18:39:01 +00:00
Artur Satayev
e2ebc1be4b Add --no-test-api-acces to am instrument.
By default instrumented processed have access to @TestApis; however for certain CTS tests we want to disable access to test APIs, where this flag would be used.

Test: manual
Bug: 133832325
Change-Id: Id56ce3079bcea2632d4002edcf120d9d5c9e0a26
Merged-In: Id56ce3079bcea2632d4002edcf120d9d5c9e0a26
2019-11-12 12:52:19 +00:00
Eric Jeong
4326effee1 Terminate statsd on a few signals including SIGTERM
- statsd is handling SIGHUP/SIGQUIT/SIGINT/SIGTERM, but doesn't exit.
- The expected behaviour is that statsd would exit after finalizing log
processing when those signals are received.

Bug: 139817664
Test: Send SIGTERM to statsd and check if it is terminated. (note that
init will revive statsd)

Change-Id: Id1146d772f8c68892256ee7a3eea70837fee5c7a
(cherry picked from commit 2d99718adf)
(cherry picked from commit 931811bda4e52ba74dd17121b514615f2991583f)
Merged-In: Id1146d772f8c68892256ee7a3eea70837fee5c7a
2019-11-11 18:18:36 +00:00
Hector Dearman
9df31fae0e Add Perfetto upload logging atoms
Assessment: https://eldar.corp.google.com/assessments/480866545
Doc: go/perfetto-monitoring-uploads
Bug: b/140984898
Bug: b/139351286
Test: Patch aosp/1156355 & aosp/1156886
  Run ./out/host/linux-x86/bin/statsd_testdrive 229
  adb shell perfetto -c :test --dropbox perfetto
Change-Id: I3e2dfa213b8fd3496aa0b09e02e0094be41711bc
Merged-In: I8f41d72c8f96a004911ef68491de8a214da4db24
(cherry picked from 40579f616d)
2019-11-06 16:34:13 +00:00
Tej Singh
dbd03d7f3a Merge "Store elapsedRealtimeNs as int64 instead of long"
am: dc51e5ef21

Change-Id: I487ca72036cfcc28bb04aebc44c7f3ca156a78b4
2019-11-04 12:15:03 -08:00
Tej Singh
ca782ac5ff Store elapsedRealtimeNs as int64 instead of long
long can be 32 bits, which will overflow in ~2 seconds if signed.

Test: builds
Change-Id: I78e69e2c2ceb21a5748d9d5d860b45e5a3fae865
Merged-In: I78e69e2c2ceb21a5748d9d5d860b45e5a3fae865
2019-11-01 17:30:36 -07:00
Xin Li
6f48900f50 DO NOT MERGE - qt-qpr1-dev-plus-aosp-without-vendor@5915889 into stage-aosp-master
Bug: 142003500
Change-Id: If5056a73ede668b0048ca107b686413695e5b3b6
2019-10-30 14:33:01 -07:00
Xin Li
d3498e3053 Merge Coral/Flame into AOSP master
Bug: 141248619
Change-Id: Ic0486c8c79d94c9a30efa37676b2f6a94fb7b5fa
Merged-In: Ibe8ff7bdba7a886bd8b91155ae56f087a836981f
2019-10-25 10:27:58 -07:00