Commit graph

73339 commits

Author SHA1 Message Date
David Anderson
f3b02fc2db Merge changes I21563564,I2afd6444
* changes:
  libsnapshot: Fix libsnapshot_fuzzer_test.
  libsnapshot: Fix checks for compression to work with new snapuserd.
2021-12-16 18:35:46 +00:00
David Drysdale
f7eed000de Merge "Report Trusty KeyMint as KmVersion::KEYMINT_2" 2021-12-16 09:37:15 +00:00
David Anderson
00c0cb8020 libsnapshot: Fix libsnapshot_fuzzer_test.
Rather than fix this up to work in all configurations, just
force-disable snapuserd testing for these tests.

This patch also adds a "UseUserspaceSnapshots" helper to IDeviceInfo so
we can simplify some checks in snapshot.cpp.

Bug: 208944665
Test: libsnapshot_fuzzer_test
Change-Id: I215635645d49ad21e80af7fe084e25669c64110c
2021-12-15 22:09:05 -08:00
David Anderson
5c1d54e092 libsnapshot: Fix checks for compression to work with new snapuserd.
Most checks for compression are used as a gate to decide whether dm-user
is enabled. However, dm-user can now be enabled without compression, so
these checks have to be audited and adjusted.

Once the "old" compression path is removed, these checks will become
simpler.

Bug: 208944665
Test: vts_libsnapshot_test -force_config vab
Change-Id: I2afd644464935c965d1b84205ef54ca605d32d78
2021-12-15 22:09:05 -08:00
Ramji Jiyani
856817afe0 Merge "Create /system_dlkm mount point for GKI modules." 2021-12-16 02:41:24 +00:00
Treehugger Robot
e71fdca896 Merge "Diced: Added AID for Android's dice daemon diced." 2021-12-16 01:47:23 +00:00
Treehugger Robot
f54ebc7650 Merge "Add instant trace methods" 2021-12-15 18:11:52 +00:00
Treehugger Robot
9e0a218c74 Merge "Fix missing comma" 2021-12-15 16:43:51 +00:00
David Drysdale
37514bb907 Report Trusty KeyMint as KmVersion::KEYMINT_2
Bug: 194358913
Test: TreeHugger, VtsAidlKeyMintTargetTest
Change-Id: Ic5e321c739a66a384907539a339511e5418e9c6a
2021-12-15 12:02:06 +00:00
Yi Kong
b4b20ae65d Fix missing comma
This is discovered by Clang's -Wstring-concatenation diagnostic.

Test: presubmit
Bug: 175068488
Change-Id: Ied97b32e6707236621387bb06993d52a662d9d83
2021-12-15 17:23:46 +08:00
Lucas Dupin
2c2c5d998e Add instant trace methods
Bug: 207049735
Test: atest TraceDevTest
Change-Id: If2826a9bb1fb99d75ff3c9c03c16c2f5f1ec5d1b
2021-12-15 02:44:36 +00:00
David Anderson
c594ada00b Merge changes I875067c9,I0bb0fdc9
* changes:
  libsnapshot: Fix artifact cleanup.
  libsnapshot: Unify vts_libsnapshot_test harness.
2021-12-14 23:41:08 +00:00
Kalesh Singh
66b7ee851d Merge "Add group ID for reading tracefs" 2021-12-14 19:37:02 +00:00
Treehugger Robot
1d3b45e4fa Merge "canned fs_config accepts multiple lines having the same path" 2021-12-14 19:00:28 +00:00
Tej Singh
f1e4354b5d Merge "Create manager lib for StatsBootstrapAtomService" 2021-12-14 18:05:14 +00:00
Treehugger Robot
badd64bdbd Merge "canned_fs_config.cpp is written in C++" 2021-12-14 03:27:56 +00:00
Tej Singh
ff863caa61 Create manager lib for StatsBootstrapAtomService
Manages binder lifecycle & provides interfaces for the underlying IPCs.
Callers can use StatsBootstrapAtomClient::reportBootstrapAtom. Under the
hood, we use checkService, which will not wait for the service. This is
so we avoid blocking the client. If StatsBootstrapAtomService is not
available, the log will be dropped, and false will be returned.

Test: manually verified atoms could be logged to statsd
Bug: 206644307
Change-Id: I63ae62f1ce4d1dc337f99c9e3b35b2496131c582
2021-12-13 19:18:21 -08:00
Jiyong Park
4bd3687422 canned fs_config accepts multiple lines having the same path
Previously, each file/dir in a filesystem had to have exactly one
matching entry in the canned fs_config file. With this change, the
config file can have multiple entries for the same path. e.g.

/lib/libfoo.so 1000 1000 0644
/lib/libfoo.so 1000 2000 0644 capabilities=0x30

In this case, the last matching entry is chosen and used. This is to
make it possible to customize system-provided (and thus generic)
fs_config file with a user-provided (and thus context-specific) one.

Bug: 209971551
Test: m
Change-Id: I43902fed08db1b4968d02c75fac0a47976fff72a
2021-12-14 09:54:34 +09:00
Jiyong Park
d8602917f0 canned_fs_config.cpp is written in C++
This re-writes the file using C++, in preparation for a follow-up
change.

Also, removes debugging code that is no longer used.

Bug: 209971551
Test: m
Change-Id: I82a793cfdd7abd10024e304df7bd4ae323ffeabf
2021-12-14 09:08:42 +09:00
Yifan Hong
51f11baa5b Merge "healthd: *charger_test links to a.h.health@2.x statically." am: c7facae95a
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1920840

Change-Id: I9ad1a0b8ce08e4de19a7281b7943c877c9bbbf86
2021-12-13 23:02:56 +00:00
Yifan Hong
c7facae95a Merge "healthd: *charger_test links to a.h.health@2.x statically." 2021-12-13 22:36:30 +00:00
Yifan Hong
5771858dc0 healthd: *charger_test links to a.h.health@2.x statically.
These libraries might not be installed on the device
any more.

Fixes: 210093617
Test: run it
Change-Id: Ic1bc6ba3c78ccaad93aef00ab695f3c2acd2b367
2021-12-13 14:12:05 -08:00
Treehugger Robot
6ef37c8225 Merge "libutils: do not follow process's group" am: 83347fdb7c
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1920521

Change-Id: I9a1d34d84355e3651c478ee4c8f7cde82d19c3a4
2021-12-13 20:29:38 +00:00
Treehugger Robot
83347fdb7c Merge "libutils: do not follow process's group" 2021-12-13 20:02:31 +00:00
Wei Wang
e73180f8f5 libutils: do not follow process's group
1) App doesn't have cgroup access and there is no purpose of reading cgroup
for app. For system_server it should be known in foreground group. So
there is no benefit of reading group.

2) Reading cgroup in apps can also cause contention for other cgroup
operations.

3) vendor can change cgroup setting and get_sched_policy may return
incorrect information for get_sched_policy_profile_name.

Test: Boot
Bug: 210011562
Signed-off-by: Wei Wang <wvw@google.com>
Merged-In: I8e8c8b346984781c56ec93c0616121f7d5c99fe5
Change-Id: I8e8c8b346984781c56ec93c0616121f7d5c99fe5
(cherry picked from commit defb7773121545130fff80928ebcd7d6015be1d1)
2021-12-13 10:05:05 -08:00
Treehugger Robot
2ae516ef50 Merge "storaged: Fix bug in empty check" am: 46de7add81
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1915078

Change-Id: I14b3bfa86cffc6aa2b33fe48196e4089de1e14a4
2021-12-11 03:21:51 +00:00
Treehugger Robot
46de7add81 Merge "storaged: Fix bug in empty check" 2021-12-11 03:07:39 +00:00
Rick Yiu
18173b1e54 Merge "libprocessgroup: Use WriteStringToFd for WriteFileAction" am: 9dfff25365
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1895031

Change-Id: Ifbe096257f40ca43e12b6f4156c1c146c3916794
2021-12-11 00:36:44 +00:00
Rick Yiu
9dfff25365 Merge "libprocessgroup: Use WriteStringToFd for WriteFileAction" 2021-12-11 00:17:55 +00:00
Rick Yiu
d4c53518fe libprocessgroup: Use WriteStringToFd for WriteFileAction
Using WriteStringToFile will hold kernfs_mutex which is a big lock,
so use WriteStringToFd instead. Besides, also support fd cache for it.

Bug: 206970384
Test: build pass
Change-Id: Id79f9e1095f52079393c58edb9a4d526f4cc6b5e
2021-12-10 11:46:26 +08:00
Wei Wang
270aca8a98 Merge "Add a profile for OTA" am: e797a5c75a
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1914609

Change-Id: I80fc7b21d3966329ae08513b21488931c0a4079f
2021-12-09 17:04:26 +00:00
Wei Wang
e797a5c75a Merge "Add a profile for OTA" 2021-12-09 16:48:29 +00:00
Yifan Hong
43373678d9 Merge "storaged: skip disk_stats test if not supported." am: c232e0af05
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1912710

Change-Id: Idef33600e262756c6c262e266ffda7e099a209ba
2021-12-09 08:31:01 +00:00
Yifan Hong
c232e0af05 Merge "storaged: skip disk_stats test if not supported." 2021-12-09 08:13:26 +00:00
Treehugger Robot
ff5182de81 Merge "Replace test_min_api_level with test_options.min_shipping_api_level" am: 3589db8c3c
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1905070

Change-Id: Id9c39332454f3b9ab8f45487b1eaf34b27274e40
2021-12-09 06:06:51 +00:00
Treehugger Robot
3589db8c3c Merge "Replace test_min_api_level with test_options.min_shipping_api_level" 2021-12-09 05:51:25 +00:00
David Anderson
3a9fc6ea0a Merge "init: Add --only-if-running argument to restart command." am: 8189339de3
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1910536

Change-Id: I840853a26ff4b76431c78145df81a2617207bd6a
2021-12-09 01:26:55 +00:00
David Anderson
8189339de3 Merge "init: Add --only-if-running argument to restart command." 2021-12-09 01:10:36 +00:00
Rick Yiu
91ce8bd935 Add a profile for OTA
Add an aggregated profile, OtaProfiles, for OTA process.

Bug: 199006579
Test: build pass
Change-Id: Ie6d5c593096d6ca77cdd8e3765b21bfcfd6641a5
2021-12-09 01:06:59 +00:00
Justin Yun
95c42d97e1 Replace test_min_api_level with test_options.min_shipping_api_level
Test options for the api levels are moved to test_options.
test_min_api_level property will be removed.

Bug: 187258404
Test: build
Change-Id: I1ba26faa83d3872dca757d84d530c9795ee2d283
2021-12-09 00:16:29 +00:00
Greg Kaiser
00c5e4c9ea storaged: Fix bug in empty check
Test: TreeHugger
Bug: 208543110
Change-Id: I89610a1e9e8f6bab57bab593132365f88d4adc76
2021-12-08 10:15:04 -08:00
Yifan Hong
c85081b431 Merge "fastboot: use health AIDL HAL" am: fc5692852e
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1912711

Change-Id: I2a6f732e9ffb66f7da42d89998691e2dfd0c92a6
2021-12-08 07:41:53 +00:00
Yifan Hong
fc5692852e Merge "fastboot: use health AIDL HAL" 2021-12-08 07:33:48 +00:00
Yifan Hong
1407fd04db storaged: skip disk_stats test if not supported.
If HAL does not support disk stats, do not run
corresponding storaged tests.

Also add storaged-unit-tests to Treehugger.

Test: storaged-unit-tests
Bug: 208543110
Change-Id: Ia2acf30ca3e259e0f0744385da69d92f9c00f223
2021-12-08 07:33:09 +00:00
Treehugger Robot
dfb242c8fb Merge "storaged: use health HAL" am: c034ce0880
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1912632

Change-Id: I05e7edaf46bde61390d2de3bfa62be8afcb8945f
2021-12-08 04:49:37 +00:00
Treehugger Robot
c034ce0880 Merge "storaged: use health HAL" 2021-12-08 04:30:07 +00:00
Treehugger Robot
94174d5131 Merge "snapuserd: opt out of Global ThinLTO to workaround segfault" am: f060e6492a
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1912774

Change-Id: I2cc9f2f6170747db1c0396a28349839f6608a3f1
2021-12-07 20:37:51 +00:00
Treehugger Robot
f060e6492a Merge "snapuserd: opt out of Global ThinLTO to workaround segfault" 2021-12-07 20:02:57 +00:00
Yifan Hong
94fd5ca73c Merge "storaged: test do not crash on cuttlefish." am: ecbf9e4f7a
Original change: https://android-review.googlesource.com/c/platform/system/core/+/1912709

Change-Id: If4f59651f27ff14b56b3ac8d857418dd38242f51
2021-12-07 19:26:56 +00:00
Yi Kong
9d0c06d3e2 snapuserd: opt out of Global ThinLTO to workaround segfault
Test: manual
Bug: 208565717
Change-Id: I78397a44a7cbc2e2f04e0c77c4a816b909c95517
2021-12-07 19:12:05 +00:00