* changes:
fs_mgr: libdm: Add support to list existing device mapper devices
fs_mgr: libdm: add support to create and delete device mapper devices.
fs_mgr: device mapper: Add libdm and 'dmctl' tool to use it.
Test: dmctl create system; dmctl delete system
Test: verify that ueventd creates /dev/block/dm-X and verify the dm
device name from /sys/block/dm-X/dm/name
Bug: 110035986
Change-Id: I2a08e2ea7007c0c13fe64d444f0d6618784edae7
Signed-off-by: Sandeep Patil <sspatil@google.com>
libdm is small static library that is intended to be the one source to
control device mapper. It is intended to have APIs to create, control
and destroy device mapper targets. Eventually, all fs_mgr implementation
that talks to device mapper will be moved to using libdm APIs.
Added 'dmctl', a command line tool that lists the registered device
mapper targets and their corresponding version. The tool will continue
to get new features to exemplify new APIs implemented in libdm.
The library is intentionally static and folds into libfs_mgr. All
clients must link to libfs_mgr as a result.
Test: dmctl list
Bug: 110035986
Change-Id: I71e7146073a74e7523524bf3b20d0be6d06f9fad
Signed-off-by: Sandeep Patil <sspatil@google.com>
The legacy fence/pt info API has been deprecated for a while. This
change removes it from headers, so remaining users will have to switch
to the modern API when they're re-compiled. The functions are still
provided by libsync.so and tests remain, so existing binaries should
continue to work. Eventually these will be removed too, though, once
it's reasonable to expect those binaries to have been recompiled.
This reverts commit eed25df46a, which
reverted the previous attempt in commit
798ba95bda now that more users of the
legacy API have been converted.
Bug: 35326015
Test: make checkbuild
Test: adb shell dumpsys SurfaceFlinger --latency
init need find required devices and it some times takes a long time due
to rogue drivers. Add a warning if the timing is longer than 50ms.
Bug: 80494921
Test: Reboot
Change-Id: I8f937d7ca7127dc89ed76bb6e5f1781459d5c94a
This change removes the call to prctl(PR_SET_KEEPCAPS, 1), because now
that logd is being run with ambient capabilities, init will set the
KEEP_CAPS / KEEP_CAPS_LOCKED securebits.
Bug: 110127913
Test: liblog-unit-tests, logd-unit-tests, logcat-unit-tests
(on an aosp_sailfish-userdebug)
Change-Id: I72b6a49c5cd1552085f9ad44cb19a7333a13eeea
Init never checked the return values of the calls made during first
stage init (since of course they're not going to fail, right?). But
of course commands can fail and they might not necessarily be obvious
when they do, so let's make it obvious.
Since the kernel log isn't up until later, this creates a list of the
failures that can then be sent to the kernel log once it's ready
(pending of course failures in setting it up...)
Test: boot bullhead, don't see errors
Change-Id: I8c12c61fa12e4368346e8b0e1c0bb0844b5d0377
When adding a new error case for host_init_parser, I didn't handle the
individual line callbacks used for ueventd correctly. This change
fixes that.
Test: bullhead boots without extraneous ueventd warnings
Change-Id: I56cad854b0defd936a7fbcab73fe2f2963c0e2e4
It turns out that for the dwarf information, if a FDE indicates it's pc
relative, then pc has to be incremented by the load bias. If not, then
it should not be incremented.
Previously, the code always subtracted load bias values from pcs, and assumed
that all fdes were incremented by load bias values. The new code actually
reads the fdes and adjusted the pcs in the fde and in the eh frame hdr so
that load bias values are already handled properly.
In addition, add dumping of arm exidx values in unwind_reg_info. This allowed
verifying that the debug frame in those elf files was being handled properly.
Added a new unit test that only has a debug frame that has a non-zero load
bias and has fde entries that do not have pc relative encoding.
Fix a couple of other small bugs.
Bug: 109824792
Test: All libbacktrace/libunwindstack unit tests pass.
Test: Ran ART 137-cfi test and 004-ThreadStress.
Test: Verify that displaying the fde start and end pc actually match the
Test: real data for fde that have pc relative set, and that don't.
Test: Verified that the unwind information for arm exidx matches the
Test: debug frame data.
Change-Id: I707555286b5cb05df9f25489e8c5ede753cfe0fb
This change removes the CAP_SYSLOG file based capability from bootstat,
since the intention is that it should not be accessing the logs in the
long term. In order to avoid bitrot, the fallback code that depends on
CAP_SYSLOG has also been removed.
Bug: 62845925
Test: system/core/bootstat/boot_reason_test.sh
Change-Id: I899be44ef3ac1c4d81072f801d55c928ae09bb15
This change moves logd's capabilities from being file based to being set
by init through ambient capabilities.
Bug: 62845925
Test: sailfish:/ # grep Cap /proc/`pidof logd`/status
CapInh: 0000000000000000
CapPrm: 0000000440000000
CapEff: 0000000440000000
CapBnd: 0000000440000040
CapAmb: 0000000000000000
$ capsh --decode=0x440000040
0x440000040=cap_setgid,cap_audit_control,cap_syslog
Test: liblog-unit-tests, logd-unit-tests, logcat-unit-tests
Change-Id: I28c7c4ad37ad5eafd399aef78c303ce31298a9ef