From patchwork Thu Aug 3 16:00:42 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cole Robinson X-Patchwork-Id: 109348 Delivered-To: patch@linaro.org Received: by 10.140.101.6 with SMTP id t6csp964350qge; Thu, 3 Aug 2017 09:01:00 -0700 (PDT) X-Received: by 10.55.212.194 with SMTP id s63mr3250923qks.102.1501776059915; Thu, 03 Aug 2017 09:00:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1501776059; cv=none; d=google.com; s=arc-20160816; b=CAkB4Swb753W0Ltdasw6t78M9pMmraZ+w/Px8lzfRO0xE1wsUu5iOld5zx0kGG2Vs3 2ptOlKCFSeJ27jhmKtR0PF6R2TEFu/FsgGIsmZ44qlLK0HenBpX+j1gh2GKyHdV8pkOU yC3agF9G/ZM9l06hVr+el+9LgmGkiWCwE0xcIHaOB43wuCHdQprQo9XhKbp7JFJzrDvR PkH/V8ffcfoj9dQ8LyKJiiCojA1zsAcnkNB7Hy/hRXkaNaByyh1E5Q8A2722nOdcuQDi 9eSbZYkjrXCva/DHdLZmI2Cg/JsTrAGTIYsu+VNNtaxDX8D9M113MreYJGEozZqMPDFZ Y/rA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:message-id:date:to:from:delivered-to :dmarc-filter:arc-authentication-results; bh=fxvXBuRnh94zRLCvTtI+Hr2USAr/bLaJFHoEOjIgTBU=; b=oEK1uMd1SIRWaUWDuI8IuYh3ifEVTltvYM6FtLIts/5h4DM+w4vb7Jbm46FweYOGE8 ivP8FvdomIEW332jeWVlBKvXEBRdXouv0DTmqY/iIbXtnPVfMJJK4IfcFqAUOSkfJ9W6 Yx6NVrKG3AaCfwb2CxNQM5/Eh9f+rk8iZOUW8nKWQjWd2QV9EAdCcasBMrWxttVyKmY3 fyuLvk6F/5ZhTb9wY9/Yw77F0LbQefYdPWqrMuICLT2gBbes2Gc2dPxetieSME7uDyDH BLXkhOVcAYJZSa92RHCx3y2ejTmpMBQhMXpeedB4v2mJ4MLDwu9Rf/9b06/xH6A72dFS iD8A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com. [209.132.183.28]) by mx.google.com with ESMTPS id o88si30188404qte.465.2017.08.03.09.00.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 Aug 2017 09:00:59 -0700 (PDT) Received-SPF: pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; Authentication-Results: mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BC1495FB2C; Thu, 3 Aug 2017 16:00:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com BC1495FB2C Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx04.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9263488D6B; Thu, 3 Aug 2017 16:00:57 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 46A734BB79; Thu, 3 Aug 2017 16:00:57 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v73G0uuj007700 for ; Thu, 3 Aug 2017 12:00:56 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0854978A20; Thu, 3 Aug 2017 16:00:56 +0000 (UTC) Delivered-To: libvirt-list@redhat.com Received: from colepc.redhat.com (ovpn-116-32.phx2.redhat.com [10.3.116.32]) by smtp.corp.redhat.com (Postfix) with ESMTP id 34BAF78A21; Thu, 3 Aug 2017 16:00:44 +0000 (UTC) From: Cole Robinson To: libvirt-list@redhat.com Date: Thu, 3 Aug 2017 12:00:42 -0400 Message-Id: <57ec0b02fcac94aa470b8a1dbaeda08c5dffd4d0.1501776011.git.crobinso@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Cc: Pavel Hrdina Subject: [libvirt] [PATCH v2] tests: add qemu x86 kvm 32-on-64 test X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.28]); Thu, 03 Aug 2017 16:00:58 +0000 (UTC) There's some specific logic in qemuBuildCpuCommandLine to support auto adding -cpu qemu 32 for arch=i686 with an x86_64 qemu binary. Add a test case for it Signed-off-by: Cole Robinson --- v2: Drop unnecessary qemu-kvm path usage .../qemuxml2argv-x86-kvm-32-on-64.args | 21 +++++++++++++++++++++ .../qemuxml2argv-x86-kvm-32-on-64.xml | 13 +++++++++++++ tests/qemuxml2argvtest.c | 1 + 3 files changed, 35 insertions(+) create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.args create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.xml -- 2.13.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list diff --git a/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.args b/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.args new file mode 100644 index 000000000..5b644b0a6 --- /dev/null +++ b/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.args @@ -0,0 +1,21 @@ +LC_ALL=C \ +PATH=/bin \ +HOME=/home/test \ +USER=test \ +LOGNAME=test \ +QEMU_AUDIO_DRV=none \ +/usr/bin/qemu-system-x86_64 \ +-name kvm \ +-S \ +-machine pc,accel=kvm \ +-cpu qemu32 \ +-m 4096 \ +-smp 1,sockets=1,cores=1,threads=1 \ +-uuid d091ea82-29e6-2e34-3005-f02617b36e87 \ +-nographic \ +-nodefaults \ +-chardev socket,id=charmonitor,path=/tmp/lib/domain--1-kvm/monitor.sock,server,\ +nowait \ +-mon chardev=charmonitor,id=monitor,mode=readline \ +-no-acpi \ +-boot c diff --git a/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.xml b/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.xml new file mode 100644 index 000000000..37f53bf2a --- /dev/null +++ b/tests/qemuxml2argvdata/qemuxml2argv-x86-kvm-32-on-64.xml @@ -0,0 +1,13 @@ + + kvm + d091ea82-29e6-2e34-3005-f02617b36e87 + 4194304 + + hvm + + + /usr/bin/qemu-system-x86_64 + + + + diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index aa83013a2..f74d45ba0 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -709,6 +709,7 @@ mymain(void) DO_TEST("kvm", QEMU_CAPS_MACHINE_OPT); DO_TEST("default-kvm-host-arch", QEMU_CAPS_MACHINE_OPT); DO_TEST("default-qemu-host-arch", QEMU_CAPS_MACHINE_OPT); + DO_TEST("x86-kvm-32-on-64", QEMU_CAPS_MACHINE_OPT); DO_TEST("boot-cdrom", NONE); DO_TEST("boot-network", NONE); DO_TEST("boot-floppy", NONE);