Also add a -l to the undocumented `adb track-devices` for easier
testing.
Bug: https://issuetracker.google.com/118470090
Test: manual
Change-Id: I436f6e45b249b98a073aa147ad4ed67d4d87f9bd
Simplify the argument parsing of DmTargetSnapshot::ParseStatusText() and
improve its robustness when dealing with wrong imputs.
Add test for DmTargetSnapshot::ParseStatusText().
Change-Id: I7f078c9ecacb402e71db49e3e7072e37cffbc234
Test: dm_test
Signed-off-by: Alessio Balsini <balsini@google.com>
* changes:
adb-remount-test: add /system/priv-app
adb-remount-test: support devices that do not have verity
adb-remount-test add --no-wait-screen option
This reverts commit 588fe9e8af.
Reason for revert: definite cause for test failure
Test: adb-remount-test.sh
Bug: 138407617
Fixes: 138622072
Change-Id: If2fee8873dd7d4360e7ff5572a0481247beffbca
The default port of 5555 was removed a while back, but the help text was
never updated, and other contexts still allow a default port.
Bug: https://issuetracker.google.com/128561172
Test: manual
Change-Id: I6e5e6edeb2243386a0301c0a6cad569189f9910e
Fetch detailed information for devices through its flags and store in
helper Info class, i.e.:
- active
- access
- activeTable
- inactiveTable
- bufferFull
Change-Id: I3241c5bca00e038d19f99390f40710ca7cff8456
Bug: 137759376
Test: manual test
Signed-off-by: Alessio Balsini <balsini@google.com>
The tests do not care about legacy ION interface and are intended to
concentrate for kernels 4.14+ (new API). Running these tests
successfully during changes in ION will keep us honest with the upcoming
heap-as-module changes in ION.
Test: ./ion-unit-tests on cuttlefish.
Bug: 133508579
Change-Id: I2a31d09d09deb5be9ae84c4981cdf4b3c2cceb4c
Signed-off-by: Sandeep Patil <sspatil@google.com>
The errors were caught by ion-unit-tests. Make sure we fix them before
we start running the tests in automation etc.
Bug: 133508579
Test: ion-unit-tests
Change-Id: I7ebecfa037767481ee7f2b30e2923c84ebc352bf
Signed-off-by: Sandeep Patil <sspatil@google.com>
Previously we were ignoring ENOENT from all builtins as
rootdir/init.rc has many legacy commands that we need to keep for
backwards compatibility, but are otherwise no longer relevant.
However, this wasn't catching actual issues, for example chown failing
due to not finding the user or group name. This change therefore
reduces the scope of ignoring ENOENT to the only the extraneous errors
in builtins.
Test: boot CF and walleye without seeing errors from init.rc
Test: see errors from invalid users/groups in chown
Change-Id: Ia8e14fa2591e083cb1736c313a3e55515bc5d15e
Seems like the bug submitter thought that -l listed the partitions shown
on the line above, rather than the files. Be more explicit.
Bug: https://issuetracker.google.com/73122762
Test: treehugger
Change-Id: I6ed1027639a5b785a5992909430d739958d10ad7
In 4.19+ kernels not yet patched, /system/priv-app/<file> can
cause EPERM on fstat of the directory, resulting in failure to
access content.
Test: adb-remount-test.sh
Bug: 138649540
Change-Id: I96d1acb3cdb80824c9d2ebce415ea6e1253f9c5b
If the device screen drivers or frameworks are compromised, permit
remount testing without waiting for full boot complete to occur with
the --no-wait-screen option. In the same vein to support development,
add --wait-adb and --wait-fastboot options to adjust the timeout.
For TreeHugger testing where other (previous) tests demonstrate
framework or screen regressions, it _may_ be advised to switch to the
--no-wait-screen option so that we do not register a false signal.
It should be noted that some of the past issues with overlayfs and
adb remount could introduce boot up, framework or screen regressions,
so it is advised to not use the option if that interlocking logic can
not be set up.
Test: adb-remount-test.sh
Bug: 138649540
Change-Id: Idf8f4a0eb6d7c9139bd4f2c600d14a70dc71902f
Export suspend and resume functionalities of libdm to command line
through dmctl.
Change-Id: I8e1dd7d67d8814631e4174d3ba169e705efc1df6
Bug: 137759376
Test: manual
Signed-off-by: Alessio Balsini <balsini@google.com>
In some cases it would be required to suspend the device to succesfully
complete some operations. An example is the suspension of the origin
device that is necessary to avoid data corruption when merging a
snapshot.
Introduce suspend and resume ioctls in libdm.
Bug: 137759376
Test: libdm_test
Change-Id: Id2ff34e930a8b32e570cb9f49da9cc3f65cb499c
Signed-off-by: Alessio Balsini <balsini@google.com>
It is exceedingly difficult to debug I/O and filesystem corruption
issues during first and selinux initialization stage init. By
redirecting stderr, and for good measure stdout, to /dev/kmsg in
first stage init before it exec's "/system/bin/init" we can see
the filesystem corruption errors more clearly.
Before this we would see:
init: Skipped setting INIT_AVB_VERSION (not in recovery mode)
Kernel panic - not syncing: Attempted to kill init! exitcode=0x...
and then wonder why?
After this change we can see:
init: Skipped setting INIT_AVB_VERSION (not in recovery mode)
libc: Fatal signal 5 (SIGTRAP), code 128 (SI_KERNEL), fault addr...
Kernel panic - not syncing: Attempted to kill init! exitcode=0x...
-or-
init: Skipped setting INIT_AVB_VERSION (not in recovery mode)
linker: CANNOT LINK EXECUTABLE "/system/bin/init": cannot locate symbol...
Kernel panic - not syncing: Attempted to kill init! exitcode=0x...
(NB: with stutter removed because of stdout and stderr)
Silence from these sources otherwise on successful execution.
Test: boot
Bug: 138459777
Change-Id: I4200b24baeaa6e408a5e0a2c890561bda1e2f1f4
$ adb remount
W DM_DEV_STATUS failed for scratch: No such device or address
E Can not mount overlayfs for partitions: No such file or directory
/system/bin/remount exited with status 8
remount failed
Bug: 138407617
Test: $ adb remount
Change-Id: I0f359071234b57324ad2324905b5239dbfa44d01
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Move the symlink destination of /system/usr/icu from Runtime APEX to
i18n APEX
Bug: 137009149
Test: Device boots
Change-Id: I86ff83a28d4124892d2b5d84ff09bc539f76c941
When a new namespace is added to ld.config.txt, it has to be reflected
to native_loader_test.cpp. However, failing to do so crashes the test
instead of showing an error message that the namespace hasn't been
added.
Fixing the issue by not returning nullptr when the namespace isn't
found.
Bug: 138304345
Test: libnativeloader_test
Change-Id: I9eee1293956caac69f95a946604a2e6f665bde89
Remove the out parameters for error messages using Result<T>.
Bug: 130388701
Test: libnativeloader_test
Change-Id: Idbaf391c183fb20d5e1d7c96f3a4ccbf9745b7e6