Commit graph

58981 commits

Author SHA1 Message Date
TreeHugger Robot
4e8680f440 Merge "vts_processgroup_validate_test: make deps static" into rvc-dev am: f2caf7de6c
Change-Id: I0838b783f3de646e48bb0cfd5725245e4d408e0d
2020-05-11 23:47:53 +00:00
TreeHugger Robot
f2caf7de6c Merge "vts_processgroup_validate_test: make deps static" into rvc-dev 2020-05-11 23:33:28 +00:00
Yifan Hong
01840c53e8 vts_processgroup_validate_test: make deps static
Test: pass
Fixes: 155959743
Change-Id: I730526955a40ae00a97f487e423a00c743f75d53
(cherry picked from commit 2572f23af8)
Merged-In: I730526955a40ae00a97f487e423a00c743f75d53
2020-05-11 12:32:26 -07:00
Ruchir Rastogi
ea3a566de0 Merge "Use proper platform version checks (libstats)" into rvc-dev am: b797431342
Change-Id: I403446a3981375a13085894d637d4d67c2c65197
2020-05-11 18:00:33 +00:00
Woody Lin
8c2716135b InitFatalReboot: Trigger panic explicitly for init_fatal_panic am: 8fb6e3fdaf
Change-Id: I6e1ba46a5209eb0fb90c94936c33fe345b615e70
2020-05-11 18:00:22 +00:00
Ruchir Rastogi
b797431342 Merge "Use proper platform version checks (libstats)" into rvc-dev 2020-05-11 17:22:24 +00:00
Woody Lin
8fb6e3fdaf InitFatalReboot: Trigger panic explicitly for init_fatal_panic
The exit of init panics the system *after* process context (mm, stack,
...etc.) are recycled, according to Linux kernel's 'do_exit'
implementation. To preserve most init process context for debugging,
triggers the panic via proc-sysrq explicitly.

Note: after this change, there will be no "Attempt to kill init" panic
when androidboot.init_fatal_panic is set.

Test: Insert data abort fault in init, the full process context is
      preserved in memory dump captured after panic.
Bug: 155940351
Change-Id: I3393bd00f99b8cb432cfa19a105b7d636b411764
(cherry picked from commit be1cf9006a)
2020-05-11 14:50:27 +00:00
Lorenzo Colitti
eb5711913c Simplify code that parses ifa_flags. am: c00d57d353
Change-Id: I6459879e74cdc1b78cfe956ffd3bbac1dbe1db48
2020-05-11 13:53:42 +00:00
Lorenzo Colitti
9952566a32 Parse IFA_F_* values above 0x80. am: 3991ca5657
Change-Id: I9e5ff42e9a34137b005765cacaa159b2af6f564a
2020-05-11 08:16:56 +00:00
Lorenzo Colitti
c00d57d353 Simplify code that parses ifa_flags.
When parsing an RTM_NEWADDR or RTM_DELADDR, ifaddr is always
present (unless the message is invalid). So ifaddr->ifa_flags is
always known before any attributes are parsed.

Bug: 155005831
Test: atest NetworkStackNextIntegrationTests:IpClientIntegrationTest continues to apss
Change-Id: Id1998faccca7d81c1b7f3e85e4912aa22919e94a
2020-05-11 11:37:17 +09:00
Lorenzo Colitti
3991ca5657 Parse IFA_F_* values above 0x80.
In RTM_NEWADDR messages, the first 8 flags are reported in the
ifa_flags field in struct ifaddrmsg, but flags above 0x80 are
reported in the IFA_FLAGS attribute. NetlinkEvent currently only
looks at ifa_flags, so it cannot see higher-value flags such as
IFA_F_STABLE_PRIVACY. Fix this by parsing the IFA_FLAGS
attribute.

Bug: 155005831
Test: makes new test in aosp/1295495 pass
Original-Change: https://android-review.googlesource.com/1295670
Merged-In: I723f1106cbcea2186fc6452305942a0f8301fd2a
Change-Id: I723f1106cbcea2186fc6452305942a0f8301fd2a
2020-05-11 11:29:59 +09:00
Chen Zhu
5b59f27e2c Merge "Add test config for adbd_test and apply MainlineTestModuleController to it" into rvc-dev am: 8950624662
Change-Id: Iae50f577bb1233554a0d6a5101a30312f969b0f0
2020-05-09 03:00:51 +00:00
Chen Zhu
8950624662 Merge "Add test config for adbd_test and apply MainlineTestModuleController to it" into rvc-dev 2020-05-09 02:48:48 +00:00
Chen Zhu
5daea5a6a2 Add test config for adbd_test and apply MainlineTestModuleController to it
to only run the tests when com.google.android.adbd is

installed on device.

Bug: 154845935
Test: m mts && mts-tradefed run mts-adbd
Change-Id: I2f203d25288580a07391703e2b28df54479a69f0
2020-05-08 16:47:07 -07:00
TreeHugger Robot
11a5105f05 [automerger skipped] Merge "first_stage_init: add support to skip module load failures" into rvc-dev am: 1cf1238d4a -s ours
am skip reason: Change-Id I068c631a22c848e45a421b297b1acae1b3deb3c1 with SHA-1 6c5f82642b is in history

Change-Id: I0ddcd89091161631b4418dfe01086d895bb10d36
2020-05-07 22:02:06 +00:00
TreeHugger Robot
1cf1238d4a Merge "first_stage_init: add support to skip module load failures" into rvc-dev 2020-05-07 21:48:05 +00:00
Will McVicker
f3483ec6a0 first_stage_init: add support to skip module load failures
Extend androidboot.first_stage_console cmdline property to enable
skipping module load failures without stopping at a serial console. This
is useful for GKI development.

Set androidboot.first_stage_console=2 for this behavior.

Bug: 155296582
Test: verify behavior for values 0, 1, and 2
Merged-In: I068c631a22c848e45a421b297b1acae1b3deb3c1
Change-Id: I068c631a22c848e45a421b297b1acae1b3deb3c1
(cherry picked from commit 6c5f82642b)
2020-05-07 21:47:17 +00:00
David Anderson
bc141e0071 Merge "libfiemap: Remove brittle tests." into rvc-dev am: 7d50e96978
Change-Id: I5439b9eaae680b0f05fb76552063951480073c10
2020-05-07 19:45:09 +00:00
David Anderson
10088dbe4e Merge "fastboot: Fix snapshot-update merge behavior." into rvc-dev am: 4adbeb470f
Change-Id: I56da350eec80f0232d24c2f6d160b97b2e3c4087
2020-05-07 19:44:47 +00:00
David Anderson
7d50e96978 Merge "libfiemap: Remove brittle tests." into rvc-dev 2020-05-07 19:34:04 +00:00
David Anderson
4adbeb470f Merge "fastboot: Fix snapshot-update merge behavior." into rvc-dev 2020-05-07 19:32:43 +00:00
Ruchir Rastogi
4ae167e829 Use proper platform version checks (libstats)
Test: bit libstatspush_compat_test
Bug: 146019024
Change-Id: If99a7067944ddfbe30bb0ddfe586a337a94d4c07
2020-05-07 12:31:39 -07:00
TreeHugger Robot
061e079781 Merge "Using ABB for install-multi." into rvc-dev am: 67a2bebf74
Change-Id: I522b1f80e84d0f1123a29f38e1a088849b9659fb
2020-05-06 23:16:05 +00:00
TreeHugger Robot
67a2bebf74 Merge "Using ABB for install-multi." into rvc-dev 2020-05-06 23:00:02 +00:00
Alex Buynytskyy
13e98eaf72 Using ABB for install-multi.
ABB uses single shared CMD for all operations which improves
reliability.

Bug: b/153486595
Fixes: 153486595
Test: atest adb_test adbd_test fastdeploy_test
Change-Id: I1e3da63882c980811ed2e9f5556732b24a041ce5
Merged-In: I1e3da63882c980811ed2e9f5556732b24a041ce5
2020-05-06 14:10:56 -07:00
David Anderson
3afca7c11e libfiemap: Remove brittle tests.
libfiemap functionality is extensively tested via libsnapshot, gsid, and
fiemap_writer_test. However those tests rely on the configuration of the
device, and libfiemap has fairly different behavior based on whether FBE
or metadata encryption is in use. (The former will use loop devices, the
latter uses dm-linear).

To expand coverage, we added tests with very complicated nesting,
creating fiemaps on a rw partition mounted off a device backed by a
fiemap. Unsurprisingly, this was brittle to begin with, and now
consistently fails due to the intermediate partition not having
sepolicy.

Given the preference toward metadata encryption, and the fact that the
FBE mode will still be properly tested via VTS, let's just remove these
tests.

Bug: 148874852
Test: fiemap_image_test
Change-Id: I7be7d44dea81508505c050ed995b3b78086ad35f
Merged-In: I7be7d44dea81508505c050ed995b3b78086ad35f
2020-05-05 19:16:21 -07:00
Tim Murray
da3a838435 Merge "mark atrace buffers as uninitialized" into rvc-dev am: 9842adf768
Change-Id: Ic7605fcf70c23b7c807b1e54c5026fb964aa1c12
2020-05-05 22:50:34 +00:00
Tim Murray
9842adf768 Merge "mark atrace buffers as uninitialized" into rvc-dev 2020-05-05 22:33:04 +00:00
Tim Murray
0f85154117 mark atrace buffers as uninitialized
The atrace buffer does not need to be zero-initialized every time.

Test: memset calls from atrace_{begin,end}_body are gone
bug 155788214

Change-Id: I8082b6a9e6d6328f4aee3a22137977e9fae21933
2020-05-05 18:37:02 +00:00
TreeHugger Robot
2574b305a8 Merge "stats: Set min_sdk_version" into rvc-dev am: 4cfdfef1bf
Change-Id: I9960b0c64a2c41ff07acfac71d2caee7a1130805
2020-05-04 23:30:00 +00:00
TreeHugger Robot
4cfdfef1bf Merge "stats: Set min_sdk_version" into rvc-dev 2020-05-04 23:11:27 +00:00
David Anderson
f2f5edd9d5 fastboot: Fix snapshot-update merge behavior.
When merging in recovery, the "imminent data wipe" code was used, which
made the assumption the /metadata and /data state would be zapped. This
caused future OTAs to error because the old snapshots were detected.

This CL allows OTAs to proceed even if unexpected snapshots are present.
It also forces the state to "MergeCompleted" after a merge in recovery,
so that the next normal boot can perform cleanup.

Bug: 155339165
Test: fastboot snapshot-update merge, then take another OTA
      vts_libsnapshot_test
Change-Id: Ief6dea3ba76323044e61307272dda320a4494aea
Merged-In: Ief6dea3ba76323044e61307272dda320a4494aea
2020-05-04 15:53:06 -07:00
Christopher Ferris
2273266944 Merge "Fix dangling pointer issue in LocalUpdatbleMaps" into rvc-dev am: 64021d834a
Change-Id: I23e337eb2b6705e07b2d93f3561285923544d4f0
2020-05-02 16:36:18 +00:00
Christopher Ferris
64021d834a Merge "Fix dangling pointer issue in LocalUpdatbleMaps" into rvc-dev 2020-05-02 16:28:23 +00:00
Yifan Hong
c3b037686d Merge "Handle zero snapshot size appropriately." into rvc-dev am: 5b182952de
Change-Id: Ia2794499c5fc9cbbb7b09b1c0f7f73e4729cf2f7
2020-05-02 05:01:37 +00:00
Yifan Hong
5b182952de Merge "Handle zero snapshot size appropriately." into rvc-dev 2020-05-02 04:47:00 +00:00
Sim Sun
ce0f3201d1 Fix dangling pointer issue in LocalUpdatbleMaps
Libunwindstack would remove duplicated items and update the `prev_map`
during reparsing `/proc/self/maps`. But we leave `prev_real_map`
pointing toward a MapInfo that will be deleted soon. It will cause a
dangling pointer issue.

Add new tests to cover this dangling pointer issue.

Bug: 155511785

Test: libunwindstack_test
Change-Id: I62e1b97bcb73f07e9349671f0b758f5ec9de16c0
(cherry picked from commit a7a194beb4)
2020-05-01 17:24:57 -07:00
TreeHugger Robot
427e663b96 Merge "first_stage_init: add support to skip module load failures" into rvc-d1-dev 2020-05-01 23:27:42 +00:00
Suren Baghdasaryan
78b82bec83 task_profiles.json: add a new task profile used by camera HAL am: 0b4313fede
Change-Id: I008253a87cc8a7b77c41c94745cc9ee1c65229bf
2020-05-01 22:43:22 +00:00
Suren Baghdasaryan
90910f5489 init: Add task_profiles init command am: 21ae541691
Change-Id: I5a175d44ad5c88dcf245374d9a12ed424b1b7d3e
2020-05-01 22:43:20 +00:00
Suren Baghdasaryan
0b4313fede task_profiles.json: add a new task profile used by camera HAL
Add new CameraServicePerformance task profile used by camera HAL.

Bug: 155419956
Test: confirm profile applies correctly
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I21cf942eca279a5ad4c1ff75c735560954f4ebc1
Merged-In: I21cf942eca279a5ad4c1ff75c735560954f4ebc1
2020-05-01 22:21:09 +00:00
Suren Baghdasaryan
21ae541691 init: Add task_profiles init command
Introduce new command to allow setting task profiles from inside .rc
script. This is to replace usage of writepid when a service is trying
to join a cgroup. Usage example from a .rc file:

service surfaceflinger /system/bin/surfaceflinger
    task_profiles HighPerformance

Bug: 155419956
Test: change .rc file and confirm task profile is applied
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I0add9c3b363a7cb1ea89778780896cae1c8a303c
Merged-In: I0add9c3b363a7cb1ea89778780896cae1c8a303c
2020-05-01 22:20:57 +00:00
Will McVicker
6c5f82642b first_stage_init: add support to skip module load failures
Extend androidboot.first_stage_console cmdline property to enable
skipping module load failures without stopping at a serial console. This
is useful for GKI development.

Set androidboot.first_stage_console=2 for this behavior.

Bug: 155296582
Test: verify behavior for values 0, 1, and 2
Change-Id: I068c631a22c848e45a421b297b1acae1b3deb3c1
2020-05-01 13:48:33 -07:00
TreeHugger Robot
b7da236617 Merge "liblog: require root for multi_connect_dgram_socket test" into rvc-dev am: 67a92651a2
Change-Id: I1273e42167586a73eb4cebf5e863ffa0cd519204
2020-05-01 19:34:32 +00:00
TreeHugger Robot
67a92651a2 Merge "liblog: require root for multi_connect_dgram_socket test" into rvc-dev 2020-05-01 19:15:43 +00:00
Yifan Hong
c2a048e2ed Handle zero snapshot size appropriately.
This won't happen in practice because device size is never
zero. Hypothetically, if it is, PartitionCowCreator still
suggests that a CoW size of 8192 bytes needs to be created. In
reality, it is not necessary.

Test: libsnapshot_fuzzer
Bug: 155484992
Change-Id: I6c69f54820522d50c699384eec90c474ca3a9402
(cherry picked from commit bc84824e21acfdc83590d6d0d4827bd9854fc0f5)
Merged-In: I6c69f54820522d50c699384eec90c474ca3a9402
2020-05-01 11:52:01 -07:00
David Anderson
1a7bb7d724 Merge "libfiemap: Ignore userdata requirements in fiemap_writer_test when running a DSU." into rvc-dev am: 0d246eb96a
Change-Id: Ia271ae0ede6597ef12d7727cd35d035d0f2517c8
2020-05-01 18:01:35 +00:00
David Anderson
0d246eb96a Merge "libfiemap: Ignore userdata requirements in fiemap_writer_test when running a DSU." into rvc-dev 2020-05-01 17:46:02 +00:00
Jooyung Han
f2d4dc6b8f stats: Set min_sdk_version
Modules contributing mainline modules (APK/APEX) should set
min_sdk_version as well as apex_available.

For now setting min_sdk_version doesn't change build outputs.
But build-time checks will be added soon.

Bug: 152655956
Test: m
Merged-In: Icd184c6fe06a688bd79ef6514bb49dffb706a9a1
Change-Id: Icd184c6fe06a688bd79ef6514bb49dffb706a9a1
(cherry picked from commit cc3588afcb)
2020-05-02 02:29:19 +09:00
Tom Cherry
3ac8ba1820 liblog: require root for multi_connect_dgram_socket test
Bug: 65062446
Test: multi_connect_dgram_socket is skipped for non-root
Test: multi_connect_dgram_socket passes for root
Merged-In: I610bed5987580e0c5a01952efc2e32e7d8cdf9b4
Change-Id: I610bed5987580e0c5a01952efc2e32e7d8cdf9b4
(cherry picked from commit 710825ce47)
2020-05-01 10:27:21 -07:00