From: reyk Date: Thu, 23 Aug 2018 06:04:53 +0000 (+0000) Subject: Allow to boot CDROM-only VMs. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=d967289559b8c61730b5a42610649414ff3dc7b9;p=openbsd Allow to boot CDROM-only VMs. Pointed out by Jon Williams OK mlarkin@ kn@ ccardenas@ --- diff --git a/usr.sbin/vmctl/vmctl.c b/usr.sbin/vmctl/vmctl.c index 7ab9a9bc60c..867a0e703e0 100644 --- a/usr.sbin/vmctl/vmctl.c +++ b/usr.sbin/vmctl/vmctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vmctl.c,v 1.54 2018/07/12 12:04:49 reyk Exp $ */ +/* $OpenBSD: vmctl.c,v 1.55 2018/08/23 06:04:53 reyk Exp $ */ /* * Copyright (c) 2014 Mike Larkin @@ -98,8 +98,8 @@ vm_start(uint32_t start_id, const char *name, int memsize, int nnics, errx(1, "too many disks"); else if (ndisks == 0) warnx("starting without disks"); - if (kernel == NULL && ndisks == 0) - errx(1, "no kernel or disk specified"); + if (kernel == NULL && ndisks == 0 && !iso) + errx(1, "no kernel or disk/cdrom specified"); if (nnics == -1) nnics = 0; if (nnics > VMM_MAX_NICS_PER_VM)