From nobody Fri Apr 26 18:14:31 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) client-ip=207.211.31.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 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=1589282617; cv=none; d=zohomail.com; s=zohoarc; b=fzbmYmDVfxGb4VFV6T4lSkg+72Y07XbVcgeIGrFr+tKXklxpk2R5FJ4GPyEqs6zEJyHjYgN1GukQKkOYRZY2Ts/coLVC1ZQnP7MGaYO0OLwX97LImTmLn+9+IXQeCLncZ0f8k3emCso+f1MtbeKlOP6uP4C95+l72n2C+FyKLe8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1589282617; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=hBx7zVFc2VZNp0kg3XePhF7PVFPy9xVXi/A5KMMtT2g=; b=SwviquZZb4lv+3puMaLctcwKK7zJ+7GrG+b+gD1W1aD2aXNfu+apgmIucKyQPyIm1erbb3x0DqTSbMkJkGT+TZZjiVOIn1gFfiyNXLFHhenQLm1fFbVRGDe5soNXnoM/dylJNexhk8DUPkI9hZ77h/0fb/c0tRP+YZRmWNNgZlk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 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-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by mx.zohomail.com with SMTPS id 1589282617955869.6562342721893; Tue, 12 May 2020 04:23:37 -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-497-Q-Y8YCwWPq2lEucvyFG6OQ-1; Tue, 12 May 2020 07:23:34 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EDEBA800687; Tue, 12 May 2020 11:23:28 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0220F66071; Tue, 12 May 2020 11:23: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 82B7A1809543; Tue, 12 May 2020 11:23:23 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 04CBNMoa001377 for ; Tue, 12 May 2020 07:23:22 -0400 Received: by smtp.corp.redhat.com (Postfix) id 3B5A06A949; Tue, 12 May 2020 11:23:22 +0000 (UTC) Received: from lpt.redhat.com (unknown [10.40.208.84]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6616566071 for ; Tue, 12 May 2020 11:23:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1589282616; 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:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=hBx7zVFc2VZNp0kg3XePhF7PVFPy9xVXi/A5KMMtT2g=; b=dlWeNyynKknIeuZyu86YYBjz/haEdd9VNLxoCftoqxx87YlehsgbOFHRnCXvPaWpo50r4d 15xxZNdQKQSWbt/SAm395r5kBRfo47BoaLeLEGOvcAty+dohuKbtKLrg2CLMI8bOwaaxF8 WxI6NdJfNG6JQspc00uxGgoYSW2YgXE= X-MC-Unique: Q-Y8YCwWPq2lEucvyFG6OQ-1 From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Subject: [libvirt PATCH] qemu: only stop external devices after the domain Date: Tue, 12 May 2020 13:23:13 +0200 Message-Id: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 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.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) A failure in qemuProcessLaunch would lead to qemuExtStopDevices being called twice - once in the cleanup section and then again in qemuProcessStop. However, the first one is called while the QEMU process is still running, which is too soon for the swtpm process, because the swtmp_ioctl command can lock up:: https://bugzilla.redhat.com/show_bug.cgi?id=3D1822523 Remove the first call and only leave the one in qemuProcessStop, which is called after the QEMU process is killed. Signed-off-by: J=C3=A1n Tomko Reviewed-by: Daniel Henrique Barboza Reviewed-by: Erik Skultety --- src/qemu/qemu_process.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index dee3f3fb63..f7f6793113 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -6992,8 +6992,6 @@ qemuProcessLaunch(virConnectPtr conn, ret =3D 0; =20 cleanup: - if (ret < 0) - qemuExtDevicesStop(driver, vm); qemuDomainSecretDestroy(vm); return ret; } --=20 2.25.4