From nobody Mon Feb 9 17:57:53 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 216.205.24.124 as permitted sender) client-ip=216.205.24.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 216.205.24.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=1634735030; cv=none; d=zohomail.com; s=zohoarc; b=S/ETuObrN5is24+Zo60pPoUVdI5AkdeMV499EMc2Q8kZ8veXVr13AP8F/j6Q3Ncr6tcCxqxXwibH98LEPP7OytVkn4NF4dkyOvBYlr2b8ukdyi+3vWLkWWtc7Mr8T2Afq23uZlJa8UBYuHHjgEBr4QlTz5o1XTGXUwcbbYII5AI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1634735030; 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=ZSCM7yrZBJM5+Fc5HNKddWTKf1oxyQj6P0fkfoTJd4Y=; b=kW94f2u3UD2vxcUwzMluttu7WDxJiV6HA+8GWWl9D6/dd0FLOtAu7vpq+zY70nDUZyHZ05q+l7j2Un33Lp26Cmw/RM5MuOH1XG1mxGbX3PzAdCPQgOCmz65TCMdA3S6mqyC3Jvc8YRY/iS1jJA/9GKTp1xe9Vrh1f4JdfH8JOyk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 216.205.24.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 [216.205.24.124]) by mx.zohomail.com with SMTPS id 1634735030765259.2231967667951; Wed, 20 Oct 2021 06:03:50 -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-153-4XbzauuhOWGRJ52qEh0Vnw-1; Wed, 20 Oct 2021 09:03:45 -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 C9197CC624; Wed, 20 Oct 2021 13:03:39 +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 A1F3219729; Wed, 20 Oct 2021 13:03:39 +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 425AA4EA37; Wed, 20 Oct 2021 13:03:39 +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 19KD3SeF029694 for ; Wed, 20 Oct 2021 09:03:28 -0400 Received: by smtp.corp.redhat.com (Postfix) id 57382652AC; Wed, 20 Oct 2021 13:03:28 +0000 (UTC) Received: from kinshicho.usersys.redhat.com.homenet.telecomitalia.it (unknown [10.40.195.155]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9A1F160657 for ; Wed, 20 Oct 2021 13:03:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1634735029; 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=ZSCM7yrZBJM5+Fc5HNKddWTKf1oxyQj6P0fkfoTJd4Y=; b=CS70GrRQ5pcVtz++B5jIwSQvzocC9eEBhNzDXs+KJ1aVddhyKzyrKlCQH6Q+tAvweSoHMe LapiED0ZNuQ8E8SoUd2LM9ZFta8sAsC3CgQg+pltrrKUhfuTCqKKOWAfA/lyyVYq/f2ccx wi4A6WNsOOIivutQZdX+PzqioDbegj4= X-MC-Unique: 4XbzauuhOWGRJ52qEh0Vnw-1 From: Andrea Bolognani To: libvir-list@redhat.com Subject: [libvirt PATCH v2 05/22] conf: Add IOMMU support to virDomainDeviceDefCopy() Date: Wed, 20 Oct 2021 15:02:40 +0200 Message-Id: <20211020130257.534296-6-abologna@redhat.com> In-Reply-To: <20211020130257.534296-1-abologna@redhat.com> References: <20211020130257.534296-1-abologna@redhat.com> 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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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: 1634735046109100003 Content-Type: text/plain; charset="utf-8" There doesn't seem to be a reason for IOMMUs not to be handled by this function. Signed-off-by: Andrea Bolognani --- src/conf/domain_conf.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index a3f0a27058..0618343b79 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -29708,6 +29708,10 @@ virDomainDeviceDefCopy(virDomainDeviceDef *src, virDomainShmemDefFormat(&buf, src->data.shmem, flags); rc =3D 0; break; + case VIR_DOMAIN_DEVICE_IOMMU: + virDomainIOMMUDefFormat(&buf, src->data.iommu); + rc =3D 0; + break; case VIR_DOMAIN_DEVICE_VSOCK: virDomainVsockDefFormat(&buf, src->data.vsock); rc =3D 0; @@ -29720,7 +29724,6 @@ virDomainDeviceDefCopy(virDomainDeviceDef *src, case VIR_DOMAIN_DEVICE_SMARTCARD: case VIR_DOMAIN_DEVICE_MEMBALLOON: case VIR_DOMAIN_DEVICE_NVRAM: - case VIR_DOMAIN_DEVICE_IOMMU: case VIR_DOMAIN_DEVICE_LAST: virReportError(VIR_ERR_INTERNAL_ERROR, _("Copying definition of '%d' type " --=20 2.31.1