From nobody Mon Feb 9 10:57:20 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1682332934; cv=none; d=zohomail.com; s=zohoarc; b=VJ4O79R5fgEnIlXf7vwaSTQJe5YRV3p4QBAucHzMAXWtNFt8kQ6/fCpvNYjVa9hMc4Gl7NgPPPYSDj3D7iqyFEpUNUcG2fhLBJbbyROPsHtUr27RycoMfRdwUPEf82KhLaTuOewg9SWC998TgOoVrZvYMkhPzmwEOufI1q8BizM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1682332934; 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=vi9OmbPvLZRWlOibnodRgxv94w3riimZo5EHYCnfyCM=; b=WGeHmJXMz/Yl5PG2Z496DDE0JRIB/N46CoGygJ0QWnSX79YSTPzBFLjUxEYz6Jf/dYZh0xNWn6AwZQk08RHmJSynLevzg3xjHpjnIv0YHteu4xhBFJ4R9fVFjmSBSLFKHCIpeS/bLUxNMzyMsa9Uj4wxwXVfGr5g1QIqT7aRt6M= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1682332934022256.2879337622154; Mon, 24 Apr 2023 03:42:14 -0700 (PDT) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-592-lZSj7w0gPZeRnhFWm37quA-1; Mon, 24 Apr 2023 06:42:03 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 320AC83FC85; Mon, 24 Apr 2023 10:41:57 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1F8752166B2B; Mon, 24 Apr 2023 10:41:57 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 7CB221946A6C; Mon, 24 Apr 2023 10:41:56 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 3175D1946A46 for ; Mon, 24 Apr 2023 10:41:55 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 16C411121319; Mon, 24 Apr 2023 10:41:55 +0000 (UTC) Received: from localhost.localdomain (unknown [10.43.2.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id B2B741121318 for ; Mon, 24 Apr 2023 10:41:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1682332933; 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=vi9OmbPvLZRWlOibnodRgxv94w3riimZo5EHYCnfyCM=; b=e2bAldLbfQhaLTqoUf25SSi5JFlX4ZERljHsZHtDMNxBqpz9vgiMGcFOfxtYDKhRzXDkwg cKipSRuXu6C+NzmcNOkmiOqyihLz7Kjc+Y7+mG8/pIVqTOikELN5kJlBamAI29IbFtMQgk HxHFZAGOb1b2yerNXU/5z/OF9OWlLK0= X-MC-Unique: lZSj7w0gPZeRnhFWm37quA-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH v2 9/9] qemu: Stop virQEMUCaps propagation into qemuHostdevPreparePCIDevices() Date: Mon, 24 Apr 2023 12:41:48 +0200 Message-Id: <5c04f3e02396d93413f540b158417ac751612d54.1682332714.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.3 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1682332935405100001 Content-Type: text/plain; charset="utf-8"; x-default="true" After previous cleanups, qemuHostdevPreparePCIDevices() no longer needs virQEMUCaps. Drop its passing from callers. Signed-off-by: Michal Privoznik Reviewed-by: Martin Kletzander --- src/qemu/qemu_hostdev.c | 5 +---- src/qemu/qemu_hostdev.h | 2 -- src/qemu/qemu_hotplug.c | 4 ++-- src/qemu/qemu_process.c | 3 +-- 4 files changed, 4 insertions(+), 10 deletions(-) diff --git a/src/qemu/qemu_hostdev.c b/src/qemu/qemu_hostdev.c index 49347019ea..f329442f8c 100644 --- a/src/qemu/qemu_hostdev.c +++ b/src/qemu/qemu_hostdev.c @@ -181,7 +181,6 @@ qemuHostdevPreparePCIDevices(virQEMUDriver *driver, const unsigned char *uuid, virDomainHostdevDef **hostdevs, int nhostdevs, - virQEMUCaps *qemuCaps G_GNUC_UNUSED, unsigned int flags) { return virHostdevPreparePCIDevices(driver->hostdevMgr, @@ -261,7 +260,6 @@ qemuHostdevPrepareMediatedDevices(virQEMUDriver *driver, int qemuHostdevPrepareDomainDevices(virQEMUDriver *driver, virDomainDef *def, - virQEMUCaps *qemuCaps, unsigned int flags) { if (!def->nhostdevs && !def->ndisks) @@ -271,8 +269,7 @@ qemuHostdevPrepareDomainDevices(virQEMUDriver *driver, return -1; =20 if (qemuHostdevPreparePCIDevices(driver, def->name, def->uuid, - def->hostdevs, def->nhostdevs, - qemuCaps, flags) < 0) + def->hostdevs, def->nhostdevs, flags)= < 0) return -1; =20 if (qemuHostdevPrepareUSBDevices(driver, def->name, diff --git a/src/qemu/qemu_hostdev.h b/src/qemu/qemu_hostdev.h index 2d484db878..3e9adc57a9 100644 --- a/src/qemu/qemu_hostdev.h +++ b/src/qemu/qemu_hostdev.h @@ -52,7 +52,6 @@ int qemuHostdevPreparePCIDevices(virQEMUDriver *driver, const unsigned char *uuid, virDomainHostdevDef **hostdevs, int nhostdevs, - virQEMUCaps *qemuCaps, unsigned int flags); int qemuHostdevPrepareUSBDevices(virQEMUDriver *driver, const char *name, @@ -73,7 +72,6 @@ int qemuHostdevPrepareMediatedDevices(virQEMUDriver *driv= er, int nhostdevs); int qemuHostdevPrepareDomainDevices(virQEMUDriver *driver, virDomainDef *def, - virQEMUCaps *qemuCaps, unsigned int flags); =20 void qemuHostdevReAttachOneNVMeDisk(virQEMUDriver *driver, diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index bf9d16e82b..b8b0a107aa 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -1473,8 +1473,8 @@ qemuDomainAttachHostPCIDevice(virQEMUDriver *driver, =20 if (!cfg->relaxedACS) flags |=3D VIR_HOSTDEV_STRICT_ACS_CHECK; - if (qemuHostdevPreparePCIDevices(driver, vm->def->name, vm->def->uuid, - &hostdev, 1, priv->qemuCaps, flags) <= 0) + if (qemuHostdevPreparePCIDevices(driver, vm->def->name, + vm->def->uuid, &hostdev, 1, flags) < = 0) return -1; =20 if (qemuDomainAdjustMaxMemLockHostdev(vm, hostdev) < 0) diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index 75a1d88cd7..8d7fd28e37 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -7164,8 +7164,7 @@ qemuProcessPrepareHost(virQEMUDriver *driver, hostdev_flags |=3D VIR_HOSTDEV_STRICT_ACS_CHECK; if (flags & VIR_QEMU_PROCESS_START_NEW) hostdev_flags |=3D VIR_HOSTDEV_COLD_BOOT; - if (qemuHostdevPrepareDomainDevices(driver, vm->def, priv->qemuCaps, - hostdev_flags) < 0) + if (qemuHostdevPrepareDomainDevices(driver, vm->def, hostdev_flags) < = 0) return -1; =20 VIR_DEBUG("Preparing chr device backends"); --=20 2.39.2