From nobody Mon Feb 9 16:54:06 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1587634865; cv=none; d=zohomail.com; s=zohoarc; b=EKtrR+wP031un6BQifWZiSjjglg3cXq07X8UaO3aqNSSG6mxSRvWrFRTtYbMKL4Z54sPhLt141/VDOgGvt5rV7/hpRofSaetpkbsuHcAvVpDLgKWbfOBrYaQvEYtSkO8plId5v/jx6aeMxQeOs+DUE6ZHj2dWUExBstfTWC9mSw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1587634865; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=LYW0debNagmMpEkMSmwQ0nv0hPTjdN1kKNP3Z8FkpTw=; b=MWkjHJlZjwedQcT6RSRDykepLAtPj+ZVncPFWQv7CIWQYWMtyAYTDQbnwVp01drIXHM519f1DRdc8ah01T43hEpQPwRFg6NbH6xQ6Ug95LTzi1tanPQz4OrZe2zxGtXv2u6LjZBuEjqsN/PAZDjXdsEOITTXxJ8d4xxBMuhVD+I= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1587634865681920.2810840908393; Thu, 23 Apr 2020 02:41:05 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-45-KipeLC1IM52rvSLEWp0ynA-1; Thu, 23 Apr 2020 05:40:32 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 96BA28014D8; Thu, 23 Apr 2020 09:40:26 +0000 (UTC) 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 6610819D9E; Thu, 23 Apr 2020 09:40:26 +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 225A14CAA0; Thu, 23 Apr 2020 09:40:26 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 03N9eCO9015607 for ; Thu, 23 Apr 2020 05:40:12 -0400 Received: by smtp.corp.redhat.com (Postfix) id 81E4A18B5C; Thu, 23 Apr 2020 09:40:12 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.40.208.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id EA0F1600F5 for ; Thu, 23 Apr 2020 09:40:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1587634864; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=LYW0debNagmMpEkMSmwQ0nv0hPTjdN1kKNP3Z8FkpTw=; b=FAAcg8usCPD+IH9UCIZM11MQ1ORecEm4nfodeZiXYAjHCKf08yJY66psMdletm/+uVPbjU YtHKxXGuez+cC5YKO/VIwI9GB3y9qhEqyfYoJpY+Dy0j8TFKU01E4FAcci1HadArstZ+NW mp4lf+a1kUOhWE9h8McaF403PSX94S0= X-MC-Unique: KipeLC1IM52rvSLEWp0ynA-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 3/4] mock: qemuDomainGetUnplugTimeout: Decrease timeout Date: Thu, 23 Apr 2020 11:40:03 +0200 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" We always queue the DEVICE_DELETED events before successful return from the command so that tests are reliable. This means we can decrease the unplug timeout as it's guaranteed to be executed in correct order. According to my testing it shaves off ~450ms of test run: real 0m0.721s vs. real 0m0.259s Signed-off-by: Peter Krempa --- tests/qemuhotplugmock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/qemuhotplugmock.c b/tests/qemuhotplugmock.c index 8fe7fe7448..d2324913cf 100644 --- a/tests/qemuhotplugmock.c +++ b/tests/qemuhotplugmock.c @@ -45,8 +45,8 @@ qemuDomainGetUnplugTimeout(virDomainObjPtr vm) * timeout in case of PSeries guest to be consistent with the * original logic. */ if (qemuDomainIsPSeries(vm->def)) - return 200; - return 100; + return 20; + return 10; } --=20 2.26.0