/metadta/aconfig/boot dirs
Create aconfig dirs on /metadata to store aconfig storage related files.
Under /metadata/aconfig we will store the following pb files:
1, aconfig_storage_location.pb, store the location of the storage files for
each container.
2, aconfig_flag_persistent_overrides.pb, store the local flag value overrides.
Under /metadata/aconfig/flags we will store flag value and info files
for each container, this include:
1, <container_name>.val flag value file
2, <container_name>.info flag info file
Under /metadata/aconfig/boot we will store read only flag value files
copied from /metadata/aconfig/flags at boot. These read only files are
used to serve flag read queries.
Bug: 312444587
Test: m
Change-Id: I8ae06e56fc9b9e8c0b06f86e3deb4219d7f49660
Re-order the fields in the declaration to address the following
ISO C++ requires field designators to be specified in declaration order;
field 'sigaction::(anonymous union at bionic/libc/include/bits/signal_types.h:76:20)'
will be initialized after field 'sa_flags' [-Wreorder-init-list]
Test: TH
Change-Id: I3f1d4739f1677aad50d4f07361aa264da43bdd13
1: Move to v3 COW writer
2: Enable variable block size. Default compression set to lz4
with compression factor 64KiB
3: Prepare merge sequence so that device can initiate the merge
4: Verify the merge order
Bug: 319309466
Test: On Pixel 6
This was tested on live builds where the actual builds/testing
is done on CI.
Patch-Create+Apply = Create the snapshot patches between two
builds and apply them to the device
Branch(main) Patch-Creation+Apply Snapshot-size
=============================================================
Build-1 -> Build-2 14 seconds 160MB
Build-2 -> Build-3 21 seconds 331MB
Build-3 -> Build-4 30 seconds 375MB
Build X -> Build X 3 seconds 8MB
Change-Id: I96437032de029d89de62ba11fe37d9287b0a4071
Signed-off-by: Akilesh Kailash <akailash@google.com>
In newer versions of libc++, std::char_traits<T> is no longer defined
for non-character types, and a result, std::basic_string<T> and
std::basic_string_view<T> are also no longer defined for non-character
types. See
https://discourse.llvm.org/t/deprecating-std-string-t-for-non-character-t/66779.
Replace them with std::vector<T> and std::span<const T>.
Bug: 175635923
Test: m MODULES-IN-system-core-fs_mgr
Test: /data/nativetest64/cow_api_test/cow_api_test
Change-Id: Ife2e87833ced43ff24e5765998cb6993e4f9b4c0
If the system time changes during the execution of fastboot we might
see some strange output such as:
Sending sparse 'super' 4/20 (254972 KB) OKAY [-516.263s]
Fix it by changing now() to use clock_gettime(CLOCK_MONOTONIC).
I confirmed that all callers of now() are using it for relative time
and not time since the epoch.
Change-Id: Ic3e9442c2ab21dfb076bfed88915085a183754b0
If the device provides an interface string, we should remove the newline
from the read file that is added from by the linux kernel.
Bug: 324320178
Test: Ran the same command with my local changes vs not
```
bash$ ./fastboot devices -l
5f42ad5ad259c90cf14ea222791b6aaa fastboot usb:7-3
bash$ fastboot devices -l
5f42ad5ad259c90cf14ea222791b6aaa fastboot
usb:7-3
```
Change-Id: Ida3316fdba8e35f0c66784f83455a4d82e90ba1c
This is log spam and fills the kernel log. Reduce log level from warning
to debug.
Test: manual
Bug: 36785118
Change-Id: I70fc3a0d796cb1a984705236fe7527e266a69a03
Signed-off-by: Neill Kapron <nkapron@google.com>
Current check is kind of device specfic and causes false positive.
Bug: 320829712
Test: Trigger long key press and check boot reason
Change-Id: I5b2b8307f16eecd05513bfa51494da174fc839bd
The fastboot command currently uses USBDEVFS_BULK to transfer data
(including image data) to the target. On the kernel side it looks
like this:
1. Allocate a contiguous memory region and copy the user data into
the memory region (which may involve accessing storage).
2. Instruct the driver to start a DMA operation.
3. Wait for the DMA to finish.
This is suboptimal because it misses out on a pipelining
opportunity. We could be doing 3 for the current operation in parallel
with 1 for the next operation, so that the next DMA is ready to go
as soon as the current DMA finishes.
The kernel supports asynchronous operations on usbdevfs file
descriptors (USBDEVFS_SUBMITURB and USBDEVFS_REAPURB), so we can
implement this like so:
1. Submit URB 0
2. Submit URB 1
3. Wait for URB 0
4. Submit URB 2
5. Wait for URB 1
and so on.
That is what this CL implements. On my machine it increases transfer
speed from 125 MB/s to 160 MB/s using a USB 3.0 connection to the
target (Pixel 8).
Bug: 324107907
Change-Id: I20db7ea14af85db48f6494091c8279ef7a21033d
Two things need changing for debuggerd_test to pass.
1. The seccomp policy needs to allow for PROT_MTE (0x20) in both
mprotect() and mmap(). Stack MTE processes do a mprotect()/mmap() of
the stack when launching a process.
2. The fault address and stack pointer need to be untagged when trying
to figure out the stack overflow cause.
Bug: 320448268
Bug: 292478827
Test: atest debuggerd_test --iterations=10
Change-Id: I56471c32ca40edffbb61b7547bdf2b85a6eb1ff7
This is needed to upgrade the android_logger crate from 0.12.0
to 0.13.3.
with_max_level provides the same functionality as with_min_level.
The renaming is admittedly confusing, but the new name is accurate
and it makes sense that they deprecated and then removed the
previously poorly named with_min_level.
See crate documentation [1] and code [2].
[1]: https://docs.rs/android_logger/0.12.0/android_logger/struct.Config.html#method.with_min_level
[2]: https://docs.rs/android_logger/0.12.0/src/android_logger/lib.rs.html#227
Bug: 322718401
Test: build and run CF with the change.
Test: m aosp_cf_x86_64_phone
Change-Id: Ib4fbd486267d30e74e886139846950b066848d43
Add a new AID for Virtual Machines so we can grant
capabilities such as CAP_SYS_NICE.
Bug: 322197421
Test: Build and boots, and verified capabilities
Change-Id: Ie893ba8ed6956a554bccfbd00e4e6fe9212ea77d
Signed-off-by: David Dai <davidai@google.com>