From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38242) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c7E9H-0001XJ-Fb for qemu-devel@nongnu.org; Wed, 16 Nov 2016 23:18:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c7E9E-0002RV-Aj for qemu-devel@nongnu.org; Wed, 16 Nov 2016 23:18:07 -0500 Date: Thu, 17 Nov 2016 14:18:06 +1100 From: David Gibson Message-ID: <20161117031806.GD18808@umbus.fritz.box> References: <1479285571-28145-1-git-send-email-thuth@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="rz+pwK2yUstbofK6" Content-Disposition: inline In-Reply-To: <1479285571-28145-1-git-send-email-thuth@redhat.com> Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH] tests/postcopy: Use KVM on ppc64 only if it is KVM-HV List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Thomas Huth Cc: qemu-ppc@nongnu.org, Laurent Vivier , "Dr. David Alan Gilbert" , Stefan Hajnoczi , Andrea Arcangeli , Eric Blake , qemu-devel@nongnu.org, Greg Kurz --rz+pwK2yUstbofK6 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Nov 16, 2016 at 09:39:31AM +0100, Thomas Huth wrote: > The ppc64 postcopy test does not work with KVM-PR, and it is also > causing annoying warning messages when run on a x86 host. So let's > use KVM here only if we know that we're running with KVM-HV (which > automatically also means that we're running on a ppc64 host), and > fall back to TCG otherwise. >=20 > Signed-off-by: Thomas Huth Applied to ppc-for-2.8. Longer term, I think we should default to tcg for all these tests - on x86 as well - then run KVM *as well* when available. But in the short term we should fix make check for the 2.8 release. > --- > tests/postcopy-test.c | 12 ++++++++---- > 1 file changed, 8 insertions(+), 4 deletions(-) >=20 > diff --git a/tests/postcopy-test.c b/tests/postcopy-test.c > index d6613c5..dafe8be 100644 > --- a/tests/postcopy-test.c > +++ b/tests/postcopy-test.c > @@ -380,17 +380,21 @@ static void test_migrate(void) > " -incoming %s", > tmpfs, bootpath, uri); > } else if (strcmp(arch, "ppc64") =3D=3D 0) { > + const char *accel; > + > + /* On ppc64, the test only works with kvm-hv, but not with kvm-p= r */ > + accel =3D access("/sys/module/kvm_hv", F_OK) ? "tcg" : "kvm:tcg"; > init_bootfile_ppc(bootpath); > - cmd_src =3D g_strdup_printf("-machine accel=3Dkvm:tcg -m 256M" > + cmd_src =3D g_strdup_printf("-machine accel=3D%s -m 256M" > " -name pcsource,debug-threads=3Don" > " -serial file:%s/src_serial" > " -drive file=3D%s,if=3Dpflash,format= =3Draw", > - tmpfs, bootpath); > - cmd_dst =3D g_strdup_printf("-machine accel=3Dkvm:tcg -m 256M" > + accel, tmpfs, bootpath); > + cmd_dst =3D g_strdup_printf("-machine accel=3D%s -m 256M" > " -name pcdest,debug-threads=3Don" > " -serial file:%s/dest_serial" > " -incoming %s", > - tmpfs, uri); > + accel, tmpfs, uri); > } else { > g_assert_not_reached(); > } --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --rz+pwK2yUstbofK6 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJYLSFuAAoJEGw4ysog2bOSHD8QAIsBVsqKSWwzpMapd+e5oYdJ UJ++6DxZ+IMrvO5ZRXxtU+ERKelyDSiUbkaVtlYZiihP2AE4rrCUbdr5FZ4XXRcJ /874zu/0EYyjv8fX7lcaM45VmICcZu1ucP1rXYmQizfSLxZPG92MTqobexOQm7yl l6Hl8WsYx/5w8EDvPSxcy95vteBXWbTe/3L7Nt3TpIbSZNKJiwrBI8c4RewXSxQR tGwN2bNf8a8tqp8y+xK3Dgkgh+lJe3/eqPLr5+OT6NI90o8XUlHrpMzXRzt56CUG /FeMhNO8SGYi8Q+DPXFCmTOAJm+7FpV3LcDgl+AhA7oPK892mrAFEznPov4yXu6p tzUDsnh1RPEOejJllEDwlyeB/XECVw0QhhMk9cWtdl/MoKXbaj1CczUU7D3NHWF2 JmrD6nFNpq4HfkeYNIBoaQHZuHjnE++v0JNPbjW5Ryx+BAWBhie+f6gamg4P+HL0 7v9yCRhxCZGOuNf8PUkpHu7KbcjEFm2tdJpwNzZAsykW8u9MamJIG5F3umLzp/G3 Y2lULLuwAosONg8oap78o2V7TmJV/Bp8rFvExm7KlCjmfwxAc3u/SuJODsUQ2j8E cJ+50tdLSJctL8e/kdfuTchx36Ybt4kDZTKKrct2twcRlE4JE8GEh1sKR/8J1+aX /CQrfq6Zg0+wnf1wQXNb =Ygqd -----END PGP SIGNATURE----- --rz+pwK2yUstbofK6--