Age | Commit message (Collapse) | Author |
|
The mutex usage is removed in aosp/179410 , we can safely remove the
mutex fields now.
Test: th
Bug: 318078616
Change-Id: Id22e8eab9c8cb6cc24fcbf9e32d222ba6d11cb84
|
|
Test: th
Bug: 279705058
Change-Id: I644fcee0f206b2f9523f413d82650fe0ea8aba6d
|
|
fec_process miscalculates the number of blocks it needs to read when
we perform a small read that spans multiple blocks, which results in
a partial read. The function also returns early when it notices the
partial read without cleaning up the worker threads, which can lead to
the caller releasing the buffer that the threads are still using. Fix
the calculation and add a test case to fec_unittest.
Bug: 279705058
Test: fec_unittest
Change-Id: I0d36950d3324572043b345997a21bb3e985968e5
|
|
dm-verity already corrects I/O errors. userspace library libfec should
behave in the same way. This allows us to correct more errors during
OTA.
Test: th
Bug: 259622792
Change-Id: I0e53d7ff47474524f12c6a2abd901f55ed927137
|
|
For convenience, builds against musl libc currently use the
linux_glibc properties because they are almost always linux-specific
and not glibc-specific. In preparation for removing this hack,
tweak the linux_glibc properties by either moving them to host_linux,
which will apply to linux_glibc, linux_musl and linux_bionic, or
by setting appropriate musl or linux_musl properties. Properties
that must not be repeated while musl uses linux_musl and also still
uses the linux_glibc properties are moved to glibc properties, which
don't apply to musl. Whether these stay as glibc properties or get
moved back to linux_glibc later once the musl hack is removed is TBD.
Bug: 223257095
Test: m checkbuild
Test: m USE_HOST_MUSL=true host-native
Change-Id: Iff2b4ec1465033e3e076774bc0c72b2cf966478c
|
|
This call is deprecated on recent MacOS versions, use our portable
wrapper in libbase instead.
Change-Id: I3e247738434f621f83192d4cd6772dbf55f8bed0
|
|
This is needed to link libfs_mgr into snapuserd.
Bug: 193833730
Test: builds
Change-Id: I41aec802503f8c4bd0ddcf36140afdf02f68536e
|
|
Bug: 187196593
Test: boot
Change-Id: I3b4b8c4758d5e710d3c98dd138b0893a7b320601
|
|
There's a gtest_prod_headers headers_lib now, but since this is actually
a gtest, it doesn't need it.
Bug: http://b/185916167
Test: treehugger
Change-Id: I1688f899f5a91dbcb873ddc4f54bc5080ba3de61
|
|
Added SPDX-license-identifier-Apache-2.0 to:
alloc-stress/Android.bp
app-launcher/Android.bp
boot_control_copy/Android.bp
bootctl/Android.bp
boottime_tools/bootanalyze/stressfs/Android.bp
boottime_tools/bootio/Android.bp
brillo_config/Android.mk
checkpoint_gc/Android.bp
cppreopts/Android.bp
crypto-perf/Android.bp
ext4_utils/Android.bp
ext4_utils/Android.mk
f2fs_utils/Android.bp
ioblame/Android.bp
ioshark/Android.bp
iotop/Android.bp
kexec_tools/Android.bp
latencytop/Android.bp
libfec/Android.bp
libfec/test/Android.bp
libfscrypt/Android.bp
libfscrypt/tests/Android.bp
libjsonpb/parse/Android.bp
libjsonpb/verify/Android.bp
memory_replay/Android.bp
memtrack/Android.bp
mmap-perf/Android.bp
module_ndk_libs/libnativehelper/Android.bp
multinetwork/Android.bp
pagecache/Android.bp
partition_tools/Android.bp
partition_tools/aidl/Android.bp
perf2cfg/Android.bp
postinst/Android.bp
preopt2cachename/Android.bp
profcollectd/Android.bp
profcollectd/libprofcollectd/Android.bp
profcollectd/libprofcollectd/bindings/libflags/Android.bp
pssbench/Android.mk
puncture_fs/Android.bp
runconuid/Android.bp
sane_schedstat/Android.bp
showslab/Android.bp
simpleperf/Android.bp
simpleperf/runtest/Android.bp
simpleperf/scripts/inferno/Android.bp
simpleperf/simpleperf_app_runner/Android.bp
slideshow/Android.mk
sound/Android.bp
squashfs_utils/Android.bp
su/Android.mk
taskstats/Android.bp
tests/Android.bp
tests/audio/alsa/Android.bp
tests/binder/benchmarks/Android.bp
tests/bootloader/Android.mk
tests/cpueater/Android.bp
tests/crypto/Android.bp
tests/directiotest/Android.bp
tests/ext4/Android.mk
tests/framebuffer/Android.bp
tests/fstest/Android.bp
tests/icachetest/Android.bp
tests/iptables/qtaguid/Android.bp
tests/kernel.config/Android.mk
tests/lib/Android.bp
tests/lib/testUtil/Android.bp
tests/memeater/Android.mk
tests/pagingtest/Android.mk
tests/pftest/Android.bp
tests/schedtest/Android.bp
tests/storage/Android.bp
tests/suspend_stress/Android.bp
tests/tcp_nuke_addr/Android.bp
tests/timetest/Android.bp
tests/uevents/Android.bp
toolchain-extras/Android.bp
vbmeta_tools/Android.bp
verity/Android.bp
verity/fec/Android.bp
zram-perf/Android.bp
Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD to:
cpustats/Android.bp
Added SPDX-license-identifier-BSD to:
ANRdaemon/Android.bp
Bug: 68860345
Bug: 151177513
Bug: 151953481
Test: m all
Exempt-From-Owner-Approval: janitorial work
Change-Id: Ia559848af903a7b6746d9b12b7de8b83bc57f99d
|
|
This reverts commit 044d055c842a5750359ed71dfe50a6a4bf5f4cc3.
Reason for revert: Needs to run as multiple roots.
Change-Id: I8e06e7eb19e0f634f52fbd8a1c6662f43e347dd5
|
|
Added SPDX-license-identifier-Apache-2.0 to:
boot_control_copy/Android.bp
bootctl/Android.bp
boottime_tools/bootanalyze/stressfs/Android.bp
boottime_tools/bootio/Android.bp
checkpoint_gc/Android.bp
cppreopts/Android.bp
crypto-perf/Android.bp
ext4_utils/Android.bp
ext4_utils/Android.mk
f2fs_utils/Android.bp
ioshark/Android.bp
iotop/Android.bp
kexec_tools/Android.bp
latencytop/Android.bp
libfec/Android.bp
libfec/test/Android.bp
libfscrypt/Android.bp
libfscrypt/tests/Android.bp
libjsonpb/parse/Android.bp
libjsonpb/verify/Android.bp
memory_replay/Android.bp
memtrack/Android.bp
mmap-perf/Android.bp
module_ndk_libs/libnativehelper/Android.bp
multinetwork/Android.bp
pagecache/Android.bp
partition_tools/Android.bp
perf2cfg/Android.bp
postinst/Android.bp
preopt2cachename/Android.bp
profcollectd/Android.bp
profcollectd/libprofcollectd/Android.bp
profcollectd/libprofcollectd/bindings/libflags/Android.bp
puncture_fs/Android.bp
runconuid/Android.bp
sane_schedstat/Android.bp
showslab/Android.bp
simpleperf/Android.bp
simpleperf/runtest/Android.bp
simpleperf/scripts/inferno/Android.bp
simpleperf/simpleperf_app_runner/Android.bp
slideshow/Android.mk
sound/Android.bp
squashfs_utils/Android.bp
su/Android.mk
taskstats/Android.bp
tests/Android.bp
tests/audio/alsa/Android.bp
tests/binder/benchmarks/Android.bp
tests/bootloader/Android.mk
tests/cpueater/Android.bp
tests/crypto/Android.bp
tests/directiotest/Android.bp
tests/ext4/Android.mk
tests/framebuffer/Android.bp
tests/fstest/Android.bp
tests/icachetest/Android.bp
tests/iptables/qtaguid/Android.bp
tests/kernel.config/Android.mk
tests/lib/Android.bp
tests/lib/testUtil/Android.bp
tests/memeater/Android.mk
tests/pagingtest/Android.mk
tests/pftest/Android.bp
tests/schedtest/Android.bp
tests/storage/Android.bp
tests/suspend_stress/Android.bp
tests/tcp_nuke_addr/Android.bp
tests/timetest/Android.bp
tests/uevents/Android.bp
toolchain-extras/Android.bp
vbmeta_tools/Android.bp
verity/Android.bp
verity/fec/Android.bp
Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD to:
cpustats/Android.bp
Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD
legacy_notice
to:
Android.bp
Added SPDX-license-identifier-BSD
to:
ANRdaemon/Android.bp
Added legacy_notice
to:
alloc-stress/Android.bp
app-launcher/Android.bp
brillo_config/Android.mk
ioblame/Android.bp
partition_tools/aidl/Android.bp
pssbench/Android.mk
zram-perf/Android.bp
Bug: 68860345
Bug: 151177513
Bug: 151953481
Test: m all
Exempt-From-Owner-Approval: janitorial work
Change-Id: Ie7c022a4d7f828a89d0cda663684a497af37006e
|
|
With the fix to get avbtool compiled cleanly for
multilib "first", we can clean this.
Test: make host-unit-tests
Bug: 178591423
Change-Id: I036e5a8e6a754dd7357b063dee3de0f542710a0e
|
|
Test: make fec_unittest
Bug: 177450457
Change-Id: I01d8cb0585e94703be97523117ef95581b75cbba
|
|
The check() macro does not require a final semi-colon but its usage is
inconsistent through the code. Add a semi-colon for all calls to
check().
Change-Id: I5c9da52039f5c59428d40efe02a63aaec54bfb78
|
|
Comply with Android's inclusive language guidance.
Bug: 161896447
Test: comment updates only
Change-Id: I07ba5efdc703178208bf11724e95ca3f4b04183c
|
|
It's possible that the an image doesn't contain a hashtree
descriptor. And the current raises a segfault when we attempt
to validate and copy a non existing descriptor.
Bug: 157778739
Test: call fec_open on dtbo image.
Change-Id: Ieb5acf016ceeb547f2b23de43d4276ea4d013a6f
|
|
Add stub implementation for avb related functions to allow building
libfec without libavb support. This is useful to build the fec binary
when libavb isn't available on mac.
Test: build, unittests pass
Change-Id: I26f8de390c3c2c37bf48418fb31038ddd9863866
|
|
Add support to parse the AvbHashtreeFooter in the avb image. We are in
particular looking for the ecc and hashtree data so that they can laster
be used for error correction.
Bug: 144388532
Test: unittests pass
Change-Id: I3e53e3e84a58b00346274f9946cafc135702ac82
|
|
There's no need to do that. Also check_block_hash() only allocates a
buffer of digest_length_.
Bug: 144388532
Test: unit tests pass
Change-Id: Iec3209d260b51cb41905cc84ae86572bcb1cc130
|
|
AVB format uses sha1 as the hash algorithm when computing the hash of
each block. This cl adds the support to use either sha1 or sha256 in
the hashtree_info struct. It also moves some helper functions as the member
function of the struct.
Bug: 144388532
Test: unit tests pass
Change-Id: Ie4aef1bdd8fa89240f7c6f83fcb2e33f47a468cb
|
|
Add a unittest to load and verify a VB1.0 image.
Bug: 144388532
Test: unittest pass
Change-Id: I1bfc93239a6696c58e9220864009759a2468e136
|
|
Even though the format for the VB2.0(AVB) image is different from the VB1.0
image, the majority of the content is the same. In specific, they both
have a hashtree and ecc data. By factoring the hashtree info, fec_read
can later use only the hashtree for error correction and doesn't need to
have the knowledge of verity format.
VB 1.0:
Filesystem
hash_tree
metadata <- assume 8 blocks
ecc_data
VB 2.0:
Filesystem
hash_tree
ecc_data
vbmeta
avb footer
Also switch the internal struct to use std containers so that we don't
need to worry about the memory management.
Bug: 144388532
Test: load a verity image, unit tests pass
Change-Id: I83c55464c3ac75ac41be9f507b674886ad298350
|
|
squashfs_utils.h does it in its header.
Test: `mmma -j system/extra/libfec`
Change-Id: I8cc4b5e281fe5649cbb92021285e05e8a5f28ebf
|
|
This helps reduce the size of libfec.so and the overall size of recovery
image, as those libs are already installed on device.
Bug: 112494634
Test: `m dist` with aosp_taimen-userdebug
Test: `m -j bootimage` with aosp_taimen-userdebug. Check the size of
`recovery/system/lib64/libfec.so`.
Change-Id: I1c82ba6dcbb6f184fd9826b838af665cbfc06891
|
|
O_RDONLY is defined as zero, which makes the test for it incorrect. As
we don't allow O_WRONLY when opening files, it's sufficient to test for
O_RDWR instead.
Bug: 112147169
Test: tested that corrupt zero blocks are not read without O_RDWR
Change-Id: I2328cda4285f4c9daf98dffa2a6602c9db5ad539
|
|
If partition size > filesystem image, we must skip over the verity
tree appended to the filesystem image when trying to find the verity
metadata.
Bug: 112046449
Test: Enable verity for hikey960 (system partition size = ~2 x
filesystem size) and boot.
Change-Id: Ia6cdbc0f35a98fdfa1fb4677951ae5c829cabb0f
Signed-off-by: Sandeep Patil <sspatil@google.com>
|
|
Libraries that are direct or indirect dependencies of modules installed
to recovery partition (e.g. adbd) are marked as recovery_available:
true. This allows a recovery variant of the lib is created when it is
depended by other recovery or recovery_available modules.
Bug: 79146551
Test: m -j
Change-Id: I7bee45375b03d3ada86263580ddcb201e683f024
|
|
See build/soong/README.md for more information.
Some modules are no longer installed by default on eng/debug builds, but
I didn't see any automatic references to them. If they're commonly used
by users, they can be added into build/make with PRODUCT_PACKAGES_ENG /
PRODUCT_PACKAGES_DEBUG. Otherwise everyone's compiles get a little
smaller.
Some modules also moved from /system/xbin to /system/bin, as we've
deprecated xbin. I checked codesearch for references to the full paths
and couldn't find any.
Test: cd system/extras; mma
Test: for the modules changing locations, check cs/ for references
Change-Id: I4ffd99d3dcf50e4d5cb2197824abc11973214133
|
|
close always succeeds, even if it was interrupted and "fails" with
EINTR. Retrying will either close a nonexistent fd or stomp on another
thread's newly opened file descriptor.
Bug: http://b/20501816
Test: treehugger
Change-Id: I706d5e8027e60b13f23f9488fdf5cf7cef7b3d3b
|
|
In the future, target.linux will apply to all targets running a linux kernel
(android, linux_glibc, linux_bionic). So move all current users to the specific
linux_glibc.
There will be another cleanup pass later that will move some instances back to
target.linux if the properties should be shared with target.android and
target.linux_bionic, but target.linux needs to be removed first.
Test: out/soong/build.ninja identical before/after
Change-Id: I79c638f0e5d0db86f14cb62209ece9166ebe8585
Exempt-From-Owner-Approval: build system cleanup
|
|
clang is the default compiler since Android nougat
Test: mma & verified it´s still build with clang
Change-Id: Ie41a98a7d72940e8169996a7081ccec9b94aa61c
Signed-off-by: Lennart Wieboldt <lennart.1997@gmx.de>
|
|
Test: compile
Change-Id: I97e93313f9b6ab7e8a753d4035b7805b21fdfa2d
Merged-In: I97e93313f9b6ab7e8a753d4035b7805b21fdfa2d
(cherry picked from commit b86fd88966aa15c2b9cce1bf0f7907fcdd11134e)
|
|
This patch coverts libfec and its dependencies to soong. This also
updates the name of the libext2_uuid-host library removing the "-host"
suffix as that is also being converted to soong.
Also create a shared library for libfec given that it has quite a few
dependencies.
Bug: 34284069
Test: mmma system/extras; make checkbuild
Change-Id: Ib3ada6420bae32418a02ca92db664d0d24214e2f
|
|
When using the libsquashfs_utils we need to include its only header, so
exposing the include path for this library avoids repeating the path
when using it. This patch also removes the include path from the only
call site (libfec).
Bug: None.
Change-Id: I82380b89652f758e4f33a0dc90650b04223c0940
|
|
Bug: 34220783
Change-Id: I9a140ed7bafdb8342dbdc2c7143a765acb86ecb9
|
|
Bug: 34220783
Change-Id: Ia8da0c96a0384826afd8b089101468ac388d0ca2
|
|
libfec_rs_host is now renamed to libfec_rs.
Bug: 34220783
Change-Id: I70dd794cbf2ed2f118849371379e424159b312a4
|
|
Add _LARGEFILE64_SOURCE to handle large files such as larger than 4G,
fix fec_open cannot open file larger than 4G
Bug: https://code.google.com/p/android/issues/detail?id=231508
Test: tested on Android N devices
Change-Id: I8df81a039cb987f6bde36384bf69e8ab119fd515
Signed-off-by: wangjiangshao <wangjiangshao@xiaomi.com>
|
|
Host libraries don't need to have a different name from the device target.
Bug: None
Test: `make dist`
Change-Id: Ib7709a327ac2fdbdfb131e40f578217633e1f996
|
|
To increase reliability in the case where part of the partition is
corrupt and error correction might fail, attempt to use raw verity
table before the corrected one.
Bug: 32288104
Test: tested on angler
Change-Id: I201fdc6162c87b1808979486df5707d683a6d20c
|
|
Test: mmma system/extras/libfec
Change-Id: I28b71419019c3bb0873b159e178cdfcfb5d89922
|
|
Don't require fec_header to be immediately after ECC data.
Bug: 28865197
Change-Id: Ie8faeeb07c35e2593553f7678762aae7f14c2ff7
|
|
Bug: http://b/30708454
Change-Id: I471ed5e3be92d60a88bf75ed5e427f7e34eefbc3
|
|
Bug: 28341362
Change-Id: Id7d9593e87fc8187942ef808f6ccf943a6ec023d
Test: build with WITH_TIDY=1
|
|
* Use const reference type for for-loop index variables
to avoid unnecessary copy.
Bug: 30413223
Change-Id: I9819261087a5385fe580f805be44a2407f35cdf5
Test: build with WITH_TIDY=1
|
|
|
|
Since it's not possible for libfec to identify whether the signature
field was successfully corrected, return both and allow the caller to
validate either signature.
Bug: 28943429
Change-Id: Ie913c21ba1d07d6df4c6feeb7226b2ec963f4d19
(cherry picked from commit 65cbaeb020b209f3d75d594ebbe49a609dd3c7e7)
|
|
The fec_header structure is generated build time and stored on disk.
The fec_header might be build on a 64 bits machine while it is read
per a 32 bits device or the other way around. In such situations, the
fec_header fields are not aligned as expected by the device and it
fails to read the fec_header structure.
This patch makes the fec_header packed.
Change-Id: I77546f850cea5559909971a1192e1a7616d22d50
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
|
|
Adjust code and dependencies to use BoringSSL + libcrypto_utils
instead of libmincrypt.
Change-Id: Id1b4ee538923e9dac68a7db2521b70007119c268
|