From nobody Fri Dec 12 15:16:36 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=reject dis=none) header.from=lists.libvirt.org ARC-Seal: i=1; a=rsa-sha256; t=1761827535; cv=none; d=zohomail.com; s=zohoarc; b=dWK4ZuiL0AHy7UkN2vlBHjFa52LO+3lRMRvylSjRPdkFnBLilNGKcg6hkhMtQFMw3I6G0EUQoZ00kwU7kpwQY+wDTG6yvtkc/o2asUzHbvnc4GZPBcBBYwTc6kKpu+HC/Rp0spYO7bzH7F/xInnTR8kzTESuNC/qhZ4nKS4C9/E= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1761827535; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Owner:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:References:Subject:Subject:To:To:Message-Id:Cc; bh=PzaK+LB0mfouURSjWZBfcLHySrCfZ+SHPb9P9ZiPRIs=; b=eXXxTCw9lWt/J6qoDWoE0BHswiPjnGwLjFFwqR4d7LRu4465Km59TA3HtjK+7gkWh+8DeFC3vPEMy8HFuVahiOkZ0kz+h6+au1MRrOIvdFQXPWIMJHPvtSj4VigbZN0COrIC2yLBBgKJ2VHAbpQ/FXrR0lvrt1+5rR4svWc59K4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1761827535731862.4738619676514; Thu, 30 Oct 2025 05:32:15 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 993) id 09B1541AEA; Thu, 30 Oct 2025 08:32:14 -0400 (EDT) Received: from [172.19.199.29] (lists.libvirt.org [8.43.85.245]) by lists.libvirt.org (Postfix) with ESMTP id A005E43E97; Thu, 30 Oct 2025 08:28:00 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 993) id 8418841AFC; Thu, 30 Oct 2025 08:27:40 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (3072 bits) server-digest SHA256) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 0C9AF41B17 for ; Thu, 30 Oct 2025 08:27:29 -0400 (EDT) Received: from mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-15-QPE0S53NMfWJM9fdujG4rw-1; Thu, 30 Oct 2025 08:27:25 -0400 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 1B366180A23C for ; Thu, 30 Oct 2025 12:27:25 +0000 (UTC) Received: from orkuz (unknown [10.43.3.115]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 9CE4D30001A1 for ; Thu, 30 Oct 2025 12:27:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-5.0 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_PASS autolearn=unavailable autolearn_force=no version=4.0.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1761827248; h=from:from: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; bh=PzaK+LB0mfouURSjWZBfcLHySrCfZ+SHPb9P9ZiPRIs=; b=gEOHjCdm3U1QShThzt6fmbDd05ToAjUYj5nTK/aGnNmx6wJzng2OkoanWMOHWPgC/ge+0Y +WfRsQ15VcIP7Hu0/5tdDaickzfnmoQxOUTA1cKJfkA4oXCalk6zG+H2p++SnguQrEOl8V TGXLoXA9hR/qf4Ql7De/Ohx5/c9ID90= X-MC-Unique: QPE0S53NMfWJM9fdujG4rw-1 X-Mimecast-MFC-AGG-ID: QPE0S53NMfWJM9fdujG4rw_1761827245 To: devel@lists.libvirt.org Subject: [PATCH 4/6] qemu_process: Always fix CPUs on reconnect Date: Thu, 30 Oct 2025 13:27:12 +0100 Message-ID: <34c79635361f53db6aaecf51825c9f7a172011c4.1761827183.git.jdenemar@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: IlFCklPFvUeMxWCBr2fdMwkeMsCa_eQroCqz7Wzfavk_1761827245 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: JZ7JQZ43F6OBCZEDWCKOAE3GRZ5VCSJJ X-Message-ID-Hash: JZ7JQZ43F6OBCZEDWCKOAE3GRZ5VCSJJ X-MailFrom: jdenemar@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-devel.lists.libvirt.org-0; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Jiri Denemark via Devel Reply-To: Jiri Denemark X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1761827538702154101 Content-Type: text/plain; charset="utf-8" From: Jiri Denemark We fix CPUs (i.e., remove ignored CPU features) only when libvirt/QEMU combo used to start the domain is very old and doesn't support query-cpu-model-expansion, in which case the CPU definition may contain features that are unknown to QEMU. But even if both libvirt and QEMU are new enough, we still want to remove features that do nothing to minimize confusion or to avoid false migration issues. Signed-off-by: Jiri Denemark Reviewed-by: J=C3=A1n Tomko --- src/qemu/qemu_process.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index 330519fd2e..d93ea4058d 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -9511,12 +9511,7 @@ qemuProcessRefreshCPU(virQEMUDriver *driver, =20 if (qemuProcessUpdateCPU(vm, VIR_ASYNC_JOB_NONE) < 0) return -1; - } else if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_QUERY_CPU_MODEL_E= XPANSION)) { - /* We only try to fix CPUs when the libvirt/QEMU combo used to sta= rt - * the domain did not know about query-cpu-model-expansion in which - * case the host-model is known to not contain features which QEMU - * doesn't know about. - */ + } else { qemuDomainFixupCPUs(vm, priv->origCPU); } =20 --=20 2.51.0