From 9f36949b26d43c6ccbb08181c9d4452458d2c673 Mon Sep 17 00:00:00 2001 From: Aleksandr Nogikh Date: Fri, 26 Sep 2025 13:17:29 +0200 Subject: vm: add context to Pool.Create() 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/vmware/vmware.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vm/vmware/vmware.go') diff --git a/vm/vmware/vmware.go b/vm/vmware/vmware.go index e4379717b..d7c2a5eff 100644 --- a/vm/vmware/vmware.go +++ b/vm/vmware/vmware.go @@ -77,7 +77,7 @@ func (pool *Pool) Count() int { return pool.cfg.Count } -func (pool *Pool) Create(workdir string, index int) (vmimpl.Instance, error) { +func (pool *Pool) Create(_ context.Context, workdir string, index int) (vmimpl.Instance, error) { createTime := strconv.FormatInt(time.Now().UnixNano(), 10) vmx := filepath.Join(workdir, createTime, "syzkaller.vmx") sshkey := pool.env.SSHKey -- cgit mrf-deployment