Not all Android kernels support all the cgroup controllers mentioned in
task_profiles.json and/or cgroups.json. Support such kernels by ignoring
certain cgroup activation failures.
Bug: 213617178
Change-Id: I90c0bd959f8a6484c4f2fbc895845e073527271e
Signed-off-by: Bart Van Assche <bvanassche@google.com>
During verification, update-engine will invoke
SnapshotMap() and Unmap() for every partition verification.
Post Unmap(), update-engine immediately invokes Map()
for next partition. This is a narrow window wherein, daemon
from previous unmap() is still present and init hasn't
terminated it. Thus, when next MapSnapshot() is invoked,
Connect() fails as init may end up terminating the service.
Wait for the daemon to fully terminate and exit
when Detach() is invoked.
Bug: 258514587
Test: OTA on Pixel, Map/Unmap in a loop
Change-Id: I36b7ce183dfa4c89a873118876d195480e28d48c
Signed-off-by: Akilesh Kailash <akailash@google.com>
Improve the readability of this function by splitting it.
This CL includes the following behavior changes:
- If changing the directory owner and/or mode fails for /sys/fs/cgroup,
this is considered as a fatal error instead of something that should
only fail if "Optional" has not been set.
- If mounting the v2 cgroup controller fails, this is considered as an
error.
- Activating/mounting a cgroup controller only fails if the controller
has not been marked as optional.
Bug: 213617178
Change-Id: If6908dfdbcb2e1c9637ab4ac8a7625f0a17dc9e0
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This CL prepares for introducing an additional flag test.
Bug: 213617178
Change-Id: Ia74c1990792b5839f76498de2cac0008ed92040f
Signed-off-by: Bart Van Assche <bvanassche@google.com>
Added SPDX-license-identifier-Apache-2.0 to:
rootdir/Android.mk
Bug: 68860345
Bug: 151177513
Bug: 151953481
Test: m all
Change-Id: I19aaea76a932cc928bbc178c01a33fdc98b0cf16
Bug: 267507577
Bug: 267505625
Test: tested file lock api works on linux/windows
Test: tested storage api works on linux/windows
Change-Id: I33dda819370900310ae7fc63cbf6b00ba22ad4e8
Signed-off-by: Dmitrii Merkurev <dimorinny@google.com>
Without root, Service::Start() fails due to lack of permissions.
Bug: 267559075
Test: run cts -m CtsInitTestCases -t init#GentleKill
atest init#GentleKill
Will skip under cts, pass under atest
Change-Id: I69e8be7000718bdba1c2acd9675b5645c0891afc
These tests don't work because 32-bit dependencies are not normally
packaged on a 64-bit system.
Bug: 263062262
Test: builds
Change-Id: I68859a9e9c029a528ee12c02569a3693261c7251
(cherry picked from commit 32fa3e96f4)
Replaced HIDL spec implementation with AIDL spec in gatekeeper
module. Based on the changes in aosp/2161796.
Bug: 268342724
Test: VtsHalGatekeeperTargetTest, CtsVerifier
Change-Id: Ic322e5c5a7d0577df28410a546cbad88549158bc
Currently, debuggerd tells the teacher that an app that received a fatal
signal. On the playground, dobbing on a process that doesn't actually
need to be killed is considered a friendship-ending move.
Because recoverable GWP-ASan is *supposed* to not crash your app,
suppress this behaviour and don't let ActivityManager know about the
crash.
Bug: N/A
Test: Run a use-after-free in an app that's using recoverable GWP-ASan,
through the 'libc.debug.gwp_asan.recoverable.<app_name>=1' and
'libc.debug.gwp_asan.process_sampling.<app_name>=1' sysprops.
Change-Id: I033ea67d577573df10936e37db7302d4f4bc0069
These tests have historically been pretty flaky, and have gone through a
few rounds of improvement. This is yet another: remove the
parameterization, so we can test that at least one variant of the test
succeeds, rather than all of them.
Filesystems (especially F2FS) have a lot going on underneath the hood,
and there's no guarantee that precise free space can be allocated,
measured, or relied upon in the ways this test expects. And all that we
really need to test is that some kind of out-of-space error can be
triggered.
Bug: 266645706
Test: vts_libsnapshot_test
Change-Id: I9620e5b496d5020b21cc37074e87dd21fc419ed2
Adds a background watchdog thread to the Trusty storageproxy to monitor
and log any requests that are delayed for too long. This is intended to
assist in recognizing and debugging any sources of hangs related to
servicing Trusty storage requests in Android.
Test: Add sleep() and run trusty storage tests
Bug: 266595872
Change-Id: I98dfaff0dff04f97d5c657ee131e746f63b39739
This reverts commit 3e6c9dbee8.
Reason for revert: This is breaking boot on several devices.
Bug: 267836481
Bug: 261678056
Change-Id: I67c4b784936828c448a53e3092af70d949fcbc65
So fastboot_driver.h includes <android-base/logging.h>, but that
file has a dependency on <android-base/endian.h>. So if
fastboot_driver.h gets included somewhere before
<android-base/endian.h>, it results in *very* opaque error
message:
system/core/fastboot/fastboot.cpp:1490:9: error: expected unqualified-id
LOG(VERBOSE) << "Cannot optimize flashing super on non-AB device";
^
system/libbase/include/android-base/logging.h:221:23: note: expanded from macro 'LOG'
^
system/libbase/include/android-base/logging.h:227:4: note: expanded from macro 'LOGGING_PREAMBLE'
(WOULD_LOG(severity) && \
^
system/libbase/include/android-base/logging.h:202:40: note: expanded from macro 'WOULD_LOG'
(UNLIKELY(::android::base::ShouldLog(SEVERITY_LAMBDA(severity), _LOG_TAG_INTERNAL)) || \
^
system/libbase/include/android-base/logging.h:174:26: note: expanded from macro 'SEVERITY_LAMBDA'
using ::android::base::ERROR; \
^
prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8/x86_64-w64-mingw32/include/wingdi.h:75:15: note: expanded from macro 'ERROR'
^
This patch includes <android-base/endian.h> before
<android-base/logging.h> to avoid this issue.
Reported-by: Daniel Zheng <zhengdaniel@google.com>
Signed-off-by: John Stultz <jstultz@google.com>
Change-Id: I8752f2cdbef5b13901f0f4e8adfe60a21db785b6
We want to set the contents of "out_size_num_byte", and not
the pointer value, in the error case.
Bug: 266757931
Change-Id: I02edddcbcc4fc80dbb61efe8dc7c45bd3ce1c904
Test: TreeHugger
Recoverable GWP-ASan is a mode landed upstream in
https://reviews.llvm.org/D140173. For more information about why/what it
is, see
https://android-review.git.corp.google.com/c/platform/bionic/+/2394588.
This patch makes debuggerd call the required libc callbacks for GWP-ASan
to recover from the memory corruption. It also adds the functionality
that libart/sigchain eventually ends up calling, which dumps a GWP-ASan
report for the first error encountered.
Test: Build the platform, run sanitizer-status in recoverable mode,
asserting that it doesn't crash but we get a debuggerd report.
Bug: 247012630
Change-Id: I27212f7250844c20a8fd1e961417cdb4e5bd3626