From nobody Fri May 3 23:33:33 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1486649679557842.252110277165; Thu, 9 Feb 2017 06:14:39 -0800 (PST) Received: from localhost ([::1]:38173 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cbpUc-0002r8-5P for importer@patchew.org; Thu, 09 Feb 2017 09:14:38 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55181) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cbpTa-00026H-Mv for qemu-devel@nongnu.org; Thu, 09 Feb 2017 09:13:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cbpTW-0000yR-Lr for qemu-devel@nongnu.org; Thu, 09 Feb 2017 09:13:34 -0500 Received: from mx1.redhat.com ([209.132.183.28]:58358) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cbpTW-0000y6-Ga; Thu, 09 Feb 2017 09:13:30 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 934F88050D; Thu, 9 Feb 2017 14:13:30 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-117-163.ams2.redhat.com [10.36.117.163]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v19EDS96014677; Thu, 9 Feb 2017 09:13:28 -0500 From: Thomas Huth To: Peter Maydell , qemu-devel@nongnu.org Date: Thu, 9 Feb 2017 15:13:27 +0100 Message-Id: <1486649607-31248-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Thu, 09 Feb 2017 14:13:30 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH] tests/prom-env: Ease time-out problems on slow hosts X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-ppc@nongnu.org, David Gibson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Peter Maydell recently ran into time-out problems with the prom-env test on a rather slow ARM board. To tackle this issue, we can speed up the test by running QEMU with "-nodefaults" here, so that SLOF has less devices to scan during boot, and by using the "nvramrc" environment variable instead of "boot-command", since this variable is evaluated earlier in the boot process. And to be really sure that we do not face such time out problems again, let's also increase the time out value from 100s to 120s instead. Signed-off-by: Thomas Huth Tested-by: Peter Maydell --- tests/prom-env-test.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/prom-env-test.c b/tests/prom-env-test.c index 0ba6f48..7d97ae4 100644 --- a/tests/prom-env-test.c +++ b/tests/prom-env-test.c @@ -30,8 +30,8 @@ static void check_guest_memory(void) uint32_t signature; int i; =20 - /* Poll until code has run and modified memory. Wait at most 30 second= s */ - for (i =3D 0; i < 10000; ++i) { + /* Poll until code has run and modified memory. Wait at most 120 secon= ds */ + for (i =3D 0; i < 12000; ++i) { signature =3D readl(ADDRESS); if (signature =3D=3D MAGIC) { break; @@ -46,7 +46,9 @@ static void test_machine(const void *machine) { char *args; =20 - args =3D g_strdup_printf("-M %s,accel=3Dtcg -prom-env 'boot-command=3D= %x %x l!'", + args =3D g_strdup_printf("-M %s,accel=3Dtcg -nodefaults " + "-prom-env 'use-nvramrc?=3Dtrue' " + "-prom-env 'nvramrc=3D%x %x l!'", (const char *)machine, MAGIC, ADDRESS); =20 qtest_start(args); --=20 1.8.3.1