From nobody Mon Sep 8 20:25:33 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=1756998924; cv=none; d=zohomail.com; s=zohoarc; b=gRqcsc/dJPlNMIFxATXkIP1dw5o1GYIPcfeK6QFD4zlvXtEOeRn9sOB0n0BlmiBRY1SuOViPezzGzeaoCuL6BMqoHXtMaD2sXahxg9d+B0Xxp9pNGEKsrwb1R8KNTEimFucnauam8/DlSdAuTpQU9AHIs4kgmy0DxnsWlrjsgl0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1756998924; 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=g0KGAfdr57DC/wbGkEp2YoUsFm9XaGq8uhd/kbKtr8E=; b=I5FKzlnLFwwPuDOc7Cj4vwPC119MG8VIovzC/1WKDKr0n/7TM6CzD4VwvHDkouotNNFUnrFFbuDhtnwug980oLjrOlILHRmXoGb7NE9/ENF0LrnaPjgvUCDYD4ZoMbCEI+kVt8hkCEOeMTsIQ02c8P8UrYtYj2zZ9KXr5jTOH/U= 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 1756998924229379.3268570529543; Thu, 4 Sep 2025 08:15:24 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 993) id 4379B44361; Thu, 4 Sep 2025 11:15:23 -0400 (EDT) Received: from [172.19.199.3] (lists.libvirt.org [8.43.85.245]) by lists.libvirt.org (Postfix) with ESMTP id BD26C44355; Thu, 4 Sep 2025 10:50:13 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 993) id E293344386; Thu, 4 Sep 2025 10:50:03 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.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 184B6443DC for ; Thu, 4 Sep 2025 10:47:33 -0400 (EDT) Received: from mx-prod-mc-02.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-630-EKKHG5mxMWOFVsnvtJAQwg-1; Thu, 04 Sep 2025 10:47:31 -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-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id E685E19560B6 for ; Thu, 4 Sep 2025 14:47:29 +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 74E253002D28 for ; Thu, 4 Sep 2025 14:47:29 +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=-3.1 required=5.0 tests=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=1756997252; 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=g0KGAfdr57DC/wbGkEp2YoUsFm9XaGq8uhd/kbKtr8E=; b=VqDTscUOahL+qKCNbnU5+c+Gvod/molXReOOLOqdPuTh0Q3aNj/Jihav9SnhnWKTrovUNP 0IOlHt+O/MQM2Ye5SuzEHs19a6qgX1LOjF7jN3brX+bOwCSkQg49xB3tmE63llQf+aXAxh VebsdBtoLob3zJSUk35+khP10FInmes= X-MC-Unique: EKKHG5mxMWOFVsnvtJAQwg-1 X-Mimecast-MFC-AGG-ID: EKKHG5mxMWOFVsnvtJAQwg_1756997250 To: devel@lists.libvirt.org Subject: [PATCH 11/14] qemu: Always fetch disabled features in qemuMonitorJSONGetGuestCPU Date: Thu, 4 Sep 2025 16:46:59 +0200 Message-ID: <717013cc45bd6e469c03889abeb06ed52bb3c357.1756996034.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: 94s6BRmVv2jQUsc1piPi-aYFAuPMyUtIDN7AEo53C_g_1756997250 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: ZBO4SJTCDCYPWAK5WLIJI3VXE5VZ7P2B X-Message-ID-Hash: ZBO4SJTCDCYPWAK5WLIJI3VXE5VZ7P2B 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: 1756998926621116600 Content-Type: text/plain; charset="utf-8" From: Jiri Denemark The function is always called with both enabled and disabled pointers set. Signed-off-by: Jiri Denemark Reviewed-by: Peter Krempa --- src/qemu/qemu_monitor_json.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index 6fa2f447db..06e0f3794e 100644 --- a/src/qemu/qemu_monitor_json.c +++ b/src/qemu/qemu_monitor_json.c @@ -6784,13 +6784,11 @@ qemuMonitorJSONGetGuestCPU(qemuMonitor *mon, if (qemuMonitorJSONCPUDataAddFeatures(cpuEnabled, propsEnabled, transl= ate) < 0) return -1; =20 - if (disabled && - qemuMonitorJSONGetCPUDataDisabled(mon, cpuQOMPath, translate, cpuD= isabled) < 0) + if (qemuMonitorJSONGetCPUDataDisabled(mon, cpuQOMPath, translate, cpuD= isabled) < 0) return -1; =20 *enabled =3D g_steal_pointer(&cpuEnabled); - if (disabled) - *disabled =3D g_steal_pointer(&cpuDisabled); + *disabled =3D g_steal_pointer(&cpuDisabled); =20 return 0; } --=20 2.51.0