The PDK doesn't have frameworks/base, so having a dependency from adb to
a library in there breaks the build. #ifdef out fastdeploy until we
figure out what we're going to do here, to unbreak the PDK build.
Bug: http://b/118782743
Test: treehugger
Change-Id: I638cf09e5013935e112c7a57dae0e7e94e1a4680
The following static function has been added into class AvbHandle to
support loading the AVB hashtree descriptor to enable dm-verity for
a FstabEntry.
static AvbHashtreeResult SetUpStandaloneAvbHashtree(FstabEntry* fstab_entry);
Bug: 112103720
Bug: 117960205
Test: atest libfs_avb_test
Test: atest libfs_avb_internal_test
Test: Add /system/etc/system_other.avbpubkey, then add
avb_key=/system/etc/system_other.avbpubkey into /system/etc/fstab.postinstall.
factory reset, boot a device and checks that system_other is
mounted with verity (see the serial log below)
Serial log:
-----------
init: [libfs_avb]Built verity table: '1 /dev/block/by-name/system_a
/dev/block/by-name/system_a 4096 4096 8521
8521 sha1 895ba03023a35172b393429fadad9ee228b39203
3405d16fec2cd12ad9e6b36d3bc983e1e83b5e09 10 use_fec_from_device
/dev/block/by-name/system_a fec_roots 2 fec_blocks 8589 fec_start 8589
restart_on_corruption ignore_zero_blocks'
init: [libfs_mgr]superblock s_max_mnt_count:65535,/dev/block/dm-7
init: [libfs_mgr]__mount(source=/dev/block/dm-7,target=/postinstall,type=ext4)=0:
Success
Change-Id: Ie339a43ff9c6a7d170e12ef466df666b98ddec19
Remove all tests that validated libmeminfo against the libpagemap
implementation and make libmeminfo_test self sufficient.
Bug: 111694435
Bug: 113035067
Test: libmeminfo_test
Change-Id: I21b9a0e2c71ef3f1f672a3b1de8080c0c36b4bfe
Signed-off-by: Sandeep Patil <sspatil@google.com>
The rosegment changed the load segments and broke the unwind_info printing
of unwind information for the arm exidx frame.
Test: Fixed and verified by dumping the arm exidx frame.
Change-Id: I7270175e4dcb7fee2b96a16d168880ebd09f19b1
Load resources from /product/etc/res/{values,images}/charger. If a
resource fails, falls back to /res/{values,images}/charger.
If the device has GSI flashed, resources may exist in both paths.
Resources in /product is used with a higher priority.
Test: turn off device, charge, observe animation
Bug: 119549685
Change-Id: I5a5143d132a0cc6ce9135469fb523feeeafd1b1b
This is the userspace component for the improved shared memory buffer
tracking.
A new static library called libdmabufinfo will provide APIs to parse dmabuf
debugfs entries. The library can also map and read the file descriptors
per process to cross-reference the global data per process.
This change only adds a global API to read dmabuf stats from debugfs.
Bug: 63860998
Test: dmabufinfo_test
Change-Id: Ib0deedc73337a70875e03e07d3e9a692c4c33e63
Signed-off-by: Greg Hackmann <ghackmann@google.com>
Signed-off-by: Erick Reyes <erickreyes@google.com>
Signed-off-by: Sandeep Patil <sspatil@google.com>
And deprecate one more old style function that is not used after this
change.
Test: boot, disable and enable verity
Change-Id: Id509f479850120352b4ea4dc3b6c40f6e8e2e53e
Getting it back in line with the normal ld.config.txt. This was missed in
http://r.android.com/854740.
Test: Flash and boot on marlin
Bug: 119867084
Bug: 113373927
Change-Id: Ic7e482133250eda20ff2c94c27bdee30e015ab5c
Previously information from the fstab was needed for this test, but
that's not longer the case, so skip reading the fstab altogether.
Test: build
Change-Id: I3989c62e19ae2d8606f2bc3a617f9cc3da0e5a6f
New code should be using the new Fstab class, so remove these older
functions that don't have current users.
Test: build
Change-Id: I3ba2b12b838b4b46979963869939fd4b65264738
* changes:
fs_mgr: test parsing all mount and fs mgr options
fs_mgr: convert parse_flags over to C++
fs_mgr: store file_contents_mode and file_names_mode directly
We were logging "fd.get()" after we had already done a
"std::move(fd)". That won't log the value we were hoping for.
We instead cache the file descriptor value in a local int prior
to the move(), and log that.
Test: TreeHugger
Change-Id: I715874ac63329280ffb55881fb2590fb31dc2457
Support netd to load resolv Apex.
Switch namespaces when switching library paths between
/system and the APEX, so that internal library dependencies in both
locations are loaded from their own directory.
Bug: 119527674
Test: make; flash; lsof -p $(pidof netd)
Test: 1. manual test datacall/wifi work
2. manual test tethering work
3. system/netd/tests/runtests.sh
Change-Id: I3f69e85f2f529636f0ef29a2d9d71ad582c46dfb
vsock is a socket address family for communicating into and out of
virtual machines. Addresses have a port and CID. The CID is unique to
each virtual machine on the computer. The VM host always has CID 2.
http://man7.org/linux/man-pages/man7/vsock.7.html
Inside the android guest, the adb daemon hosts a vsock server with
VMADDR_CID_ANY, automatically using the guest CID. The adb server
can now connect to addresses of the form vsock:cid:port, where the CID
must be specified and the port defaults to 5555.
This is a significant speed improvement for ADB connections in
Cuttlefish, with 150-200 MB/s for `adb push` and 100-150 MB/s for
`adb pull`. It also allows removing some proxying steps from Cuttlefish,
simplifying the full connection path, and removes a dependency on the
unstable ivshmem protocol.
Commands tested against a Cuttlefish VM with CID 3:
adb connect vsock:3:5555
adb -s vsock:3:5555 shell
adb disconnect vsock:3:5555
Supporting "adb disconnect" and "adb -s" required modifying some of the
parts that parse addresses / serials.
push/pull trials with native adb vsock support in cuttlefish:
100m: 1 file pushed. 297.6 MB/s (104857600 bytes in 0.336s)
100m: 1 file pushed. 270.3 MB/s (104857600 bytes in 0.370s)
100m: 1 file pushed. 271.7 MB/s (104857600 bytes in 0.368s)
100m: 1 file pushed. 250.5 MB/s (104857600 bytes in 0.399s)
100m: 1 file pushed. 277.1 MB/s (104857600 bytes in 0.361s)
100m: 1 file pushed. 263.5 MB/s (104857600 bytes in 0.379s)
100m: 1 file pushed. 242.6 MB/s (104857600 bytes in 0.412s)
100m: 1 file pushed. 271.8 MB/s (104857600 bytes in 0.368s)
100m: 1 file pushed. 267.1 MB/s (104857600 bytes in 0.374s)
/data/local/tmp/100m: 1 file pulled. 212.8 MB/s (104857600 bytes in 0.470s)
/data/local/tmp/100m: 1 file pulled. 236.7 MB/s (104857600 bytes in 0.423s)
/data/local/tmp/100m: 1 file pulled. 201.2 MB/s (104857600 bytes in 0.497s)
/data/local/tmp/100m: 1 file pulled. 255.6 MB/s (104857600 bytes in 0.391s)
/data/local/tmp/100m: 1 file pulled. 199.6 MB/s (104857600 bytes in 0.501s)
/data/local/tmp/100m: 1 file pulled. 214.6 MB/s (104857600 bytes in 0.466s)
/data/local/tmp/100m: 1 file pulled. 254.2 MB/s (104857600 bytes in 0.393s)
/data/local/tmp/100m: 1 file pulled. 212.5 MB/s (104857600 bytes in 0.471s)
/data/local/tmp/100m: 1 file pulled. 218.9 MB/s (104857600 bytes in 0.457s)
/data/local/tmp/100m: 1 file pulled. 223.6 MB/s (104857600 bytes in 0.447s)
Bug: 121166534
Change-Id: I50f21fb5c9acafb8daa789df4e28c9e1bbbbf2ef
Test: adb connect/shell/disconnect
Fixes a bug where verify= and a path is not respected.
Keeps the default value of -1 for swap_prio, zram_size, and the vold
managed partition number in the case of not being able to parse their
values.
Test: fs_mgr unit tests, boot
Change-Id: I41bd92a7a2f9165d62134704cb7a1209d76a2071
The GetBuildID() function returns the raw build id data, so add a function
to get the printable hex version of the data.
Bug: 120606663
Test: New unit tests pass.
Change-Id: Ia5aefc97457efb08bbd30ea96cbb2d47ae59f954
New arguments 'dtb' and 'dtb-offset' have been added to
support boot image header version 2 for the 'fastboot boot'
and 'fastboot flash:raw boot' commands.
Test: fastboot boot Image.lz4 --dtb <dtb_path> --header-version 2
Test: fastboot flash:raw boot Image.lz4 --dtb <dtb_path>
--header-version 2
Bug: 111136242
Change-Id: Idf5c2eb138609dc7e915e80c4db64677c89f24b6
These tests are meant to replace the leak check tests from libbacktrace.
Bug: 120606663
Test: Ran tests on host and target.
Change-Id: I928b199304afc36b4bac78e9a2cd688b6f2910b9
It doesn't really make sense to have extra logic to convert these
strings to enums then back again to strings for usage, especially
since with the C++ fstab, these strings are small enough to fall into
the small string optimization of std::string.
This will help make future changes cleaner as well.
Test: boot, fs_mgr_test
Change-Id: I5669ed10f2fc3eafdb137747446a2e93c24d55c4