aboutsummaryrefslogtreecommitdiffstats
path: root/vm/adb
Commit message (Collapse)AuthorAgeFilesLines
* vm/adb: don't check for ret code on adb shell rebootSebastian Ene2026-01-201-1/+10
| | | | | | | | | Prevent the fuzzer from entering in an infinte loop of device reboots when the adb shell reboot command returns with an error code. Fixes: #6598 Signed-off-by: Sebastian Ene <sebastianene@google.com>
* vm/adb: use the correct path for debugfsSebastian Ene2026-01-191-1/+1
| | | | | | | | | | Probe for the debugfs rootdir instead of the kcov sub-path to prevent the fuzzer from entering in device reboot loop in case the android device doesn't support kcov. Fixes: #6600 Signed-off-by: Sebastian Ene <sebastianene@google.com>
* vm: add context to Pool.Create()Aleksandr Nogikh2025-10-011-1/+1
| | | | | | | | | | Enable external abortion of the instance creation process. This is especially useful for the qemu case where we retry the creation/boot up to 1000 times, which can take significant time (e.g. it timeouts syz-cluster pods on unstable kernels). The context can be further propagated to WaitForSSH, but that requires another quite significant vm/ refactoring.
* vm: func Run accepts contextTaras Madan2025-05-191-3/+3
| | | | It allows to use context as a single termination signal source.
* vm/adb: pass device|console info to scriptJiao, Joey2025-04-081-1/+1
|
* vm/adb: run script allows executing complex scriptJiao, Joey2025-04-081-7/+1
|
* vm/adb: change printk level to allow findConsoleJiao, Joey2025-04-031-0/+8
|
* vm: support console_cmd to run cmd to collect console logJoey Jiao2025-02-101-20/+29
| | | | | | | | - Sometimes we need customized cmd to get serial log, ex FTDI4232H chip gets serial log through usb directly, thus we need to call cmd like `pyterm.py ftdi://ftdi:4232:FT7JLD0U/1`. - There are seveval places in console implementation to call osutil.Command, move the command code into one function.
* vm: dedup VM count restriction in debug modeDmitry Vyukov2024-11-251-3/+0
| | | | | | | Move the VM count restriction logic info vm package. This avoids lots of duplication, makes it supported for VM types that failed to do this, and allows to unify more VM count logic in future.
* vmimpl: refactor VM type registrationDmitry Vyukov2024-07-231-1/+3
| | | | | | | | | Pass Type struct directly during registration. This allows to add additional optional parameters to VM types without changing all VM implementations. We we will need to add SupportsSnapshots flag and one flag to resolve #5028. With this change it will be possible to add "SupportsSnapshots: true" to just one VM type implemenetation.
* vm: make Instance implement io.CloserAleksandr Nogikh2024-07-111-1/+2
| | | | It's better to follow standard interfaces.
* vm: refactor vm.Multiplex argumentsAleksandr Nogikh2024-07-011-13/+22
| | | | | Introduce a MultiplexConfig structure that contains optional parameters. Include a Scale parameter to control the intended slowdown.
* executor: add runner modeDmitry Vyukov2024-06-241-1/+1
| | | | | | | Move all syz-fuzzer logic into syz-executor and remove syz-fuzzer. Also restore syz-runtest functionality in the manager. Update #4917 (sets most signal handlers to SIG_IGN)
* vm/adb: fix permission when running under WSLJoey Jiao2024-05-211-0/+1
|
* pkg/rpctype: prepare for not using for target communicationDmitry Vyukov2024-05-031-1/+1
| | | | | | Remove things that are only needed for target VM communication: conditional compression, timeout scaling, traffic stats. To minimize diffs when we switch target VM communication to flatrpc.
* all: go fix everythingDmitry Vyukov2024-04-261-1/+0
|
* pkg/rpctype: make RPC compression optionalDmitry Vyukov2024-04-031-1/+1
| | | | | | | | RPC compression take up to 10% of CPU time in profiles, but it's unlikely to be beneficial for local VM runs (we are mostly copying memory in this case). Enable RPC compression based on the VM type (local VM don't use it, remove machines use it).
* vm/adb: allow lower-case in serial numberNecip Fazil Yildiran2023-08-311-1/+1
|
* all: use special placeholder for errorsTaras Madan2023-07-241-8/+8
|
* vm/adb: have adb work with android emulator by defaultb10tt02023-06-131-2/+3
| | | | Add syzkaller recognition of android emulator ID.
* all: ioutil is deprecated in go1.19 (#3718)Taras Madan2023-02-231-3/+2
|
* vm/adb: added a new condition to determine localhostAndrey Artemiev2022-08-101-1/+1
|
* vm/adb: wait for Android boot to finishAndrey Artemiev2022-07-251-10/+51
| | | | executor: removed condition around tun init
* vm/adb: use adb wait-for-device for inst.waitForSSH()Kris Alder2022-06-241-10/+13
| | | | | Instead of looping 300 times (and spamming logs) we should just use the tooling built in to ADB to wait for the device to come up.
* vm/adb: unlink symlinks before calling rmMax Spector2021-10-201-2/+6
| | | | rm fails if a symlink exists but points to a nonexistent location.
* vm/adb: add localhost to ip regex of deviceHuizi Yang2021-10-141-2/+2
| | | | remote_device_proxy uses localhost for Android WFH connection.
* vm/adb: support both old and new device formatHuizi Yang2021-09-101-6/+34
|
* vm/vmimpl/console: tail to kernel log to get serial outputHuizi Yang2021-09-101-24/+1
|
* vm/adb: add new adb device format and console impl for CuttlefishHuizi Yang2021-09-101-10/+58
|
* vm/adb: invoke waitForSSH right after the `root` commandAleksandr Nogikh2021-08-311-2/+1
|
* vm/adb: mount debugfs on Android if it is not mountedMax Spector2021-08-311-0/+11
| | | | | On Android 12+ debugfs gets unmounted after boot. This remounts it as part of reset.
* pkg: update generated files to go 1.17Alexey Kardashevskiy2021-07-071-0/+1
| | | | | | | | | | | "make generate" produces this diff when go 1.17 (go1.17-c95464f0ea3f==upstream) is used. Seems compatible with >=1.16. https://github.com/golang/go/commit/4d2d89ff42ca documents the syntax. https://github.com/golang/go/commit/eeadce2d8713 enforces "ignore" for unsatisfiable tags hence the pkg/csource/gen.go change. Signed-off-by: Alexey Kardashevskiy <aik@linux.ibm.com>
* vm/adb: add repair_script before adb availableJoey Jiao2021-04-141-10/+25
| | | | The repair script can bring the device out of crash mode.
* vm/adb: add startup_script configJoey Jiao2021-04-141-2/+17
|
* vm/adb: add flag to avoid adb reboot for testJoey Jiao2021-03-201-9/+17
|
* vm: pass Report to DiagnoseDmitry Vyukov2020-11-211-1/+2
| | | | | | | | | The way to diagnose generally depends on the issue. E.g. do we need register dump to debug this issue? Do we need host dmesg dump? Some diagnosis may be directly specific to a particular problem (e.g. dumping a particular debugfs/procfs file). Pass Report to Diagnose to make this possible.
* all: fix comments formatDmitry Vyukov2020-07-121-2/+2
| | | | | | | Fix capitalization, dots at the end and two spaces after a period. Update #1876
* all: fix warnings pointed to by golangci-lintDmitry Vyukov2019-03-281-4/+3
| | | | Update #977
* vm: allow Diagnose to directly return diagnosisMichael Pratt2018-12-211-2/+2
| | | | | | Rather than writing the diagnosis to the kernel console, Diagnose can now directly return the extra debugging info, which will be appended ot the kernel console log.
* syz-ci: de-hardcode list of VMs that support overcommitDmitry Vyukov2018-09-111-1/+1
| | | | | | | | We currently have this list in multiple places (somewhat diverged). Specify this "overcommit" property in VM implementations. In particular, we also want to allow overcommit for "vmm" type. Update #712
* gometalinter: clean up some errcheck warningsDmitry Vyukov2018-08-021-35/+3
| | | | | | | Check some errors where relevant. Unfortunately enabling errcheck does not look feasible, too many warnings. Update #538
* adb: Add console logic for ttyUSB.serialZach Riggle2018-07-261-0/+8
| | | | | | | | | | | By using UDEV rules, we can create device nodes which exist at /dev/ttyUSB.{android device serial} Which makes it easier to determine which console belongs to a device. While this is non-standard behavior, it's an inexpensive path check and makes the lookup faster and deterministic.
* vm/vmimpl: add vm.Diagnose methodDmitry Vyukov2018-06-221-0/+4
| | | | | | Diagnose is called on machine hang to try to get some additional diagnostic information from it. For now it's all stubs.
* vm/adb: don't fail if port 35099 is busyDmitry Vyukov2018-06-111-5/+8
|
* vm/adb: disable kptr_restrict for AndroidBilly Lau2018-05-161-0/+1
| | | | | | echo 0 to kptr_restrict in /proc/sys/kernel to unhide kernel pointers when fuzzing for more reliable crash dedup and easier debugging when analyzing crash.
* all: get rid of underscores in identifiersDmitry Vyukov2018-05-071-6/+6
| | | | | | Underscores are against Go coding style. Update #538
* vm/{adb,isolated}: dudup common codeDmitry Vyukov2018-05-061-37/+1
| | | | | | Found with gometalinter/dupl. Update #538
* all: fix too long linesDmitry Vyukov2018-05-051-1/+2
| | | | | Not sure why I have not seen warnings about these lines on another machine...
* gometalinter: check dot importsDmitry Vyukov2018-05-031-13/+13
| | | | Update #538
* adb: add debug level to ALERT for UART detectorJean-Baptiste Théou2018-04-181-1/+1
| | | | | | | The UART output may filter lower level messages. This ensure proper detection of the unique ID Signed-off-by: Jean-Baptiste Théou <jb@essential.com>