From nobody Sat Nov 23 15:02:26 2024 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; arc=fail (BodyHash is different from the expected one); dmarc=fail(p=none dis=none) header.from=nutanix.com Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1723016345797535.7349350593506; Wed, 7 Aug 2024 00:39:05 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id C34C31280; Wed, 7 Aug 2024 03:39:04 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 0418A12CB; Wed, 7 Aug 2024 03:38:21 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id DE4F9D32; Wed, 7 Aug 2024 03:38:15 -0400 (EDT) Received: from mx0a-002c1b01.pphosted.com (mx0a-002c1b01.pphosted.com [148.163.151.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 46D1FD31 for ; Wed, 7 Aug 2024 03:38:15 -0400 (EDT) Received: from pps.filterd (m0127837.ppops.net [127.0.0.1]) by mx0a-002c1b01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 4774QFUJ007770 for ; Wed, 7 Aug 2024 00:38:14 -0700 Received: from nam04-bn8-obe.outbound.protection.outlook.com (mail-bn8nam04lp2042.outbound.protection.outlook.com [104.47.74.42]) by mx0a-002c1b01.pphosted.com (PPS) with ESMTPS id 40sgf67ub3-2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 07 Aug 2024 00:38:14 -0700 (PDT) Received: from IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) by CO1PR02MB8506.namprd02.prod.outlook.com (2603:10b6:303:159::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7828.23; Wed, 7 Aug 2024 07:38:12 +0000 Received: from IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616]) by IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616%3]) with mapi id 15.20.7828.023; Wed, 7 Aug 2024 07:38:12 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s= proofpoint20171006; bh=MbEc/IMNAIv2z5MOyivYjRvW5lSY+S9JSrf9+d+ht +Y=; b=zwNWS2FB0Eh2VX+4rv+sEdJSQEVVrH57o5rZteZLy+RiTJmI8SUb017i8 zy1I2H7wH24qiLewWcTvi0MoSXI7nzwEEQURX6s5wT0aXUzA6O0dTC90lQDTjn4o YEuR0uYtDw8a5RXTjD5FtEltFS3l+wpMG65lkr5hFiJx7guHBfsc+NaRErE3KbUB xD4D5MMZj+5NNArKOXCwH/vYurkjNB8XbCNt+khOAOahis85saM+TJRdS/zmAZzW lqusALpbEyNjYUS6tH8H3ATvgMBOIjSZoTY7KMadBdcym3cFSJqe3myMaCth3HR+ OeUArZVIcf5MxMrXBmMm13R5BMoXg== ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=al1DmU3a7re/jTNJdAh5W25R6bZrfrQYXCHrwuFBJMXadLY0hr+b1SPWptKEEfCCttXpvGAx1iIUbNKvcB95ard3rBhsvuXItHIkcgf3WJYgCv1c+6rbLBDwCDwYS1UD68DsSo+18ZDjiwdBzc+qI8qn4tQaL2+vPq568aGpYJe4GpImXapCKKHM59Boj84OQ/DC+HDuiwhd4Hg0jHf9C0ne7U0ITBVSH4nGCVvpCLnIIo0FZNL74B+oifqUoBgE+wE0+pIXpH4jRsWjWz8wQkGh3qjAJGNIPuHHxcQEyFdfCq7/1/9X8uCVSHLl3tkDOrKUPYtXPMWBtq9TX96+5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=MbEc/IMNAIv2z5MOyivYjRvW5lSY+S9JSrf9+d+ht+Y=; b=uhFrHHXicNB1FlYlt0kuQfjaFfN0T40BROLXkp9R/SmbiPpokK32f1ogrOQDBWgG6EKe6ODtr7fu8KGW1ZYorLhwz/kfXoy2i5a3k4QhyEvLRmFyIKaBdlhaA2o102TjqZu+2OKz1FNGl602Lsg86IkChz+uh4OdCnPmD4APQlKMIX8f8pABi+TmP50rZHhg3VGwK34piwdif3jKSnXBarWmnkDvNJC1JDq7WfpUar7+3XmcdxEy202yX1Ed7x0wiQG4/I7WS4mMONn0p2Eobpmey3yTfa9x4NV9r9AADRnUOkyE0HCa1BVQ1DMbe/flmXjnIDmjrhlenyJdLiq4RQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nutanix.com; dmarc=pass action=none header.from=nutanix.com; dkim=pass header.d=nutanix.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=MbEc/IMNAIv2z5MOyivYjRvW5lSY+S9JSrf9+d+ht+Y=; b=A+COH/pDLzcCU0GguvdWz8TUQCEyjczy5PyT2QnU6VNPQtRaeHZqUXjrniXpmcbcqA86RK4fMKvc6nDe+GR90UnoKbInaML1UPob3q6z7DCFoEReO+69Mw30wZkb7hxOuHXQn4Zr1HLyqL3oBoebREYx+j3uyXHxdFncV5g1fO1ri4Pnibd9SWfU0cBCzSIntxHXSEJE0b+ZTtullPs1+BW+43nDWPm9MHt5v/cc8jahxtnYQ4v+Iq+CHk85wtOutfZHjVOyKXg+V1ODEjWksCSJNTBHBaik6Wg3WNAcavWjf8nPU0pfFAJ1YlE3hMU9G33dBpB2TebMtcpO1XvJAA== From: Sandesh Patel To: devel@lists.libvirt.org Subject: [PATCH 1/3] Conf: add dma_translation attribute to iommu Date: Wed, 7 Aug 2024 07:37:50 +0000 Message-Id: <20240807073752.64256-2-sandesh.patel@nutanix.com> X-Mailer: git-send-email 2.22.3 In-Reply-To: <20240807073752.64256-1-sandesh.patel@nutanix.com> References: <20240807073752.64256-1-sandesh.patel@nutanix.com> X-ClientProxiedBy: SJ0PR03CA0135.namprd03.prod.outlook.com (2603:10b6:a03:33c::20) To IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: IA1PR02MB9017:EE_|CO1PR02MB8506:EE_ X-MS-Office365-Filtering-Correlation-Id: e56ffd36-2c09-460f-eb23-08dcb6b3e402 x-proofpoint-crosstenant: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|52116014|376014|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?Pko+aqGYmH+uM23O4eUyoY/rOYrHp/Db6XxdyEnrKMYaJCHr/v9SMzTUtiYy?= =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/XY54A3I8dsNqBiLlUmJ36M?= =?us-ascii?Q?4p0LphwCpNxol4HJukY4kOTZmmoFoIao0r7THyffOab2GoOP6qJbm2onGu3w?= =?us-ascii?Q?b+BLD2YDZLvh8PmeOf9Lut/VwqsuEcYlFl192vt7woXW/0eL2DqAqIE2m8TW?= =?us-ascii?Q?uHkZvdTBx3gEYntG7K4dTOiyeQw1R9L+vu22hsr5cH+Cbg16pDo6I46gPOGJ?= =?us-ascii?Q?0Tj1ImV916exgA/CQT0/yVDiZqF20lEbJ+w5jero67RrSi37SsrRyUqMkC4s?= =?us-ascii?Q?blsFkh80kJ+XxbY8TNMTHbQuTGnaLxyjJ/ks2fdRtf/54nTxqD+7SngYH7rk?= =?us-ascii?Q?2NnlicJrQHbp/VCfEVckLXwSgSfMuhIiqvkGri1M50qUMXon1DehA26i4pEB?= =?us-ascii?Q?Xkh71Tzm4UaxNLjvk+DHo3WyZKlZGOAneKNEqGuOT4gxTKZwxIDW/cntPXGo?= =?us-ascii?Q?fz0Uo80NiKgImpD8l9vz2ozj8e16vr9oclyQDiUOowx3RhRjYQ=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:IA1PR02MB9017.namprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(366016)(52116014)(376014)(38350700014);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?CF+yM3GFquUwLmKG+KWVnd9zQMrMuMZ5cZaAOrnrwdvfrcpo8BJRUWRv34bO?= =?us-ascii?Q?GiViX0Zpu0AbgrHRJRS/H0SBK/lMjmHIE/hmSzQy9vOBvWvZN/yy5HCO2yz+?= =?us-ascii?Q?F/EpCjCVB06iQIuSgNOYT+HPgHnIvqwTXFIUTDppa7gn0excmbEwEY4P4p1d?= =?us-ascii?Q?K8C+Un++tQniaDfFQ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+NJJzg3?= =?us-ascii?Q?sYH5LY9WXjpWM73L5ATk+7K9YChlybkALeMGDobMyjX21coX6LsfYRpq29nt?= =?us-ascii?Q?QjM6pDxEC/QoWVvJyJTa40clqwnFmv69GL4B1CzND9l5qvdvjWJSicKUmBGE?= =?us-ascii?Q?TLcmfPnPG+o3TFyt3BAKWLkUJPCO2nA6arFi6ISvjooB4h2cbtXIkOL9gyau?= =?us-ascii?Q?E5XJ/dstbDvA6mByCubqgodKGN9xx9IW3A54ccAFYXE5FbM9Omhv5VKpI1Yo?= =?us-ascii?Q?/H89agtIdcLEvIGt2umZfx4dg9TXEjEh0v8hgRJ4AsmPydY3u9x0uvwGXiOw?= =?us-ascii?Q?zIRbjWwpNpqh2BUGQM18DKvoS4HjX1ovGxwuPL/AY+6jZG0Hni+R53S97G6h?= =?us-ascii?Q?qY62hF4eqxG2AqvwMju6dBfXQilFDUHFtwIK0kVmsu2Nkbw1ZNXd4W1LoHUt?= =?us-ascii?Q?yJqTDb6hw766wLS3bWltNzcqTq18kZnqtN8goy0G2DO787gBztGLcRTCm0i4?= =?us-ascii?Q?c4Yn4JY9egsTfPwK96NlHRyGj/wZslxTwnsitlTE/LsqkmB4f4RCnTQ4S5PZ?= =?us-ascii?Q?Bg=3D=3D?= X-OriginatorOrg: nutanix.com X-MS-Exchange-CrossTenant-Network-Message-Id: e56ffd36-2c09-460f-eb23-08dcb6b3e402 X-MS-Exchange-CrossTenant-AuthSource: IA1PR02MB9017.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Aug 2024 07:38:12.1518 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: bb047546-786f-4de1-bd75-24e5b6f79043 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: a15xtUNLT06Pxxvlp8XJtmp1VGCq1py0E4nBCsKVvPCqA99gD8Hfs6jjpV87fEMQlYxcOvfoc0Pc/0GLy2pDwt75YxySq3mHQ5ft0i8Iba8= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR02MB8506 X-Proofpoint-GUID: 34bjfWTpy9hBNdLfapUNmmgqCCxu5P2z X-Proofpoint-ORIG-GUID: 34bjfWTpy9hBNdLfapUNmmgqCCxu5P2z X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.28.16 definitions=2024-08-07_04,2024-08-06_01,2024-05-17_01 X-Proofpoint-Spam-Reason: safe Content-Transfer-Encoding: quoted-printable Message-ID-Hash: ORO4RG4V6UJPP3IZC46WN5PTCDU7WHS3 X-Message-ID-Hash: ORO4RG4V6UJPP3IZC46WN5PTCDU7WHS3 X-MailFrom: sandesh.patel@nutanix.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: Sandesh Patel X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-ZohoMail-DKIM: fail (found 2 invalid signatures) X-ZM-MESSAGEID: 1723016347863116600 Content-Type: text/plain; charset="utf-8" Add dma_translation attribute to iommu to enable/disable dma traslation for intel-iommu Signed-off-by: Sandesh Patel Reviewed-by: Michal Privoznik > Reviewed-by: Michal Privoznik --- docs/formatdomain.rst | 7 +++++++ src/conf/domain_conf.c | 15 +++++++++++++++ src/conf/domain_conf.h | 1 + src/conf/schemas/domaincommon.rng | 5 +++++ 4 files changed, 28 insertions(+) diff --git a/docs/formatdomain.rst b/docs/formatdomain.rst index c56b739b23..a037ab65e4 100644 --- a/docs/formatdomain.rst +++ b/docs/formatdomain.rst @@ -8611,6 +8611,13 @@ Example: mapping larger iova addresses in the guest. :since:`Since 6.5.0` (QE= MU/KVM only) =20 + ``dma_translation`` + The ``dma_translation`` attribute with possible values ``on`` and ``= off`` can + be used to turn off the dma translation for IOMMU. It is useful when= only + interrupt remapping is required but dma translation overhead is unwa= nted, for + example to efficiently enable more than 255 vCPUs. + :since:`Since 10.6.1` (QEMU/KVM only) + The ``virtio`` IOMMU devices can further have ``address`` element as descr= ibed in `Device addresses`_ (address has to by type of ``pci``). =20 diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 86b563fbfb..d950921667 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -13931,6 +13931,10 @@ virDomainIOMMUDefParseXML(virDomainXMLOption *xmlo= pt, if (virXMLPropUInt(driver, "aw_bits", 10, VIR_XML_PROP_NONE, &iommu->aw_bits) < 0) return NULL; + + if (virXMLPropTristateSwitch(driver, "dma_translation", VIR_XML_PR= OP_NONE, + &iommu->dma_translation) < 0) + return NULL; } =20 if (virDomainDeviceInfoParseXML(xmlopt, node, ctxt, @@ -21467,6 +21471,13 @@ virDomainIOMMUDefCheckABIStability(virDomainIOMMUD= ef *src, dst->aw_bits, src->aw_bits); return false; } + if (src->dma_translation !=3D dst->dma_translation) { + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, + _("Target domain IOMMU device dma translation '%1$s= ' does not match source '%2$s'"), + virTristateSwitchTypeToString(dst->dma_translation), + virTristateSwitchTypeToString(src->dma_translation)= ); + return false; + } =20 return virDomainDeviceInfoCheckABIStability(&src->info, &dst->info); } @@ -27451,6 +27462,10 @@ virDomainIOMMUDefFormat(virBuffer *buf, virBufferAsprintf(&driverAttrBuf, " aw_bits=3D'%d'", iommu->aw_bits); } + if (iommu->dma_translation !=3D VIR_TRISTATE_SWITCH_ABSENT) { + virBufferAsprintf(&driverAttrBuf, " dma_translation=3D'%s'", + virTristateSwitchTypeToString(iommu->dma_transla= tion)); + } =20 virXMLFormatElement(&childBuf, "driver", &driverAttrBuf, NULL); =20 diff --git a/src/conf/domain_conf.h b/src/conf/domain_conf.h index 95ddf5470e..eae621f900 100644 --- a/src/conf/domain_conf.h +++ b/src/conf/domain_conf.h @@ -2928,6 +2928,7 @@ struct _virDomainIOMMUDef { virTristateSwitch iotlb; unsigned int aw_bits; virDomainDeviceInfo info; + virTristateSwitch dma_translation; }; =20 typedef enum { diff --git a/src/conf/schemas/domaincommon.rng b/src/conf/schemas/domaincom= mon.rng index 7d58dce465..05ba697924 100644 --- a/src/conf/schemas/domaincommon.rng +++ b/src/conf/schemas/domaincommon.rng @@ -6100,6 +6100,11 @@ + + + + + --=20 2.22.3 From nobody Sat Nov 23 15:02:26 2024 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; arc=fail (BodyHash is different from the expected one); dmarc=fail(p=none dis=none) header.from=nutanix.com Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1723016370055125.42137133068888; Wed, 7 Aug 2024 00:39:30 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 0DA0B11E2; Wed, 7 Aug 2024 03:39:28 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id B98FD110C; Wed, 7 Aug 2024 03:38:30 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 186BA11E2; Wed, 7 Aug 2024 03:38:26 -0400 (EDT) Received: from mx0a-002c1b01.pphosted.com (mx0a-002c1b01.pphosted.com [148.163.151.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 40045DEE for ; Wed, 7 Aug 2024 03:38:19 -0400 (EDT) Received: from pps.filterd (m0127838.ppops.net [127.0.0.1]) by mx0a-002c1b01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 4770eBG1014082 for ; Wed, 7 Aug 2024 00:38:18 -0700 Received: from nam04-bn8-obe.outbound.protection.outlook.com (mail-bn8nam04lp2047.outbound.protection.outlook.com [104.47.74.47]) by mx0a-002c1b01.pphosted.com (PPS) with ESMTPS id 40sm3vqn68-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 07 Aug 2024 00:38:17 -0700 (PDT) Received: from IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) by CO1PR02MB8506.namprd02.prod.outlook.com (2603:10b6:303:159::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7828.23; Wed, 7 Aug 2024 07:38:15 +0000 Received: from IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616]) by IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616%3]) with mapi id 15.20.7828.023; Wed, 7 Aug 2024 07:38:14 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s= proofpoint20171006; bh=zFBwLIE8ewU3RDymVY+Nv+8NGsLrVZ4DjH2tHQn3R Sw=; b=G1fCmfs0z05w4i09eBBzWhQu6hQsVFUjgaYy3Otr3mwf5viVCcVtCIZ2F TsjGtDs3mbEXIUDiDNDw7PRSP2XQtg5aF2SXYTOU9fNi16hMdPzqYolbLpaIBQ9n M0q5PYxxWZKi8KAwWjFiq/13TY7vTjK6Xpr74QhDFib2ooJBH6FSHjHamgPtZplY +/V1lmS60JD/50Ecnl310Ns6B7TvDdCTiVGz2fOjZX5LaQbGg8QcqH0dxAu5FsaX lvuRtDY/V+9hPcHlNi+ZlqYqs5nszjCZKEn93mxfczVYGMrqZriC0ebfWmsQjtNg K3HThcN0oRIFk20iwu67Exw19Q7Tg== ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=tIQyE1VUb3xuagj2zHPLgI9WiZkx3FT+ygrlh68BDi1xKfUjRKjEhCYiG2SgG+Mje6NOMX7nQMDrSMs1ARA7wSWULAZ5aJ9rdnfqhjYCd6gNze7PzH0kCiirbgZJGnnFd+arXp1v3bfJ3JATTdRbJdCxRD7hgk/yY1CEt/2hjQ+PrcoOY2oK5GMa9V5av69McmyeHZg48Xx61ewhzOwI5uuUpPO2v2Qc/4x6VRQIn4w8q59G/TZ2NDddAMSRpeoidGo1lxnjWPwv6j52oxmxyZQzKq+Z7vSSexii2BCvcNHxXEjb5LvhfLHnHH3+f2EOu690rixXDJzPv0M9CxppAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zFBwLIE8ewU3RDymVY+Nv+8NGsLrVZ4DjH2tHQn3RSw=; b=K9GopcDXW5Nbx4b1j0BtfCsSoPV0KTSgMHG4cjiZEOHNRlHN9BlWHdi3HcTmYKOKUJgoys1MvhHJNGkxzuqSUF8Afm+L8sT28aPC8LihY87I/IAuK+06B6P/9QqRfQVGzS6FBNVpVwVjFYFAQTk7KfRcrsqhL0SdmoBDXBGwnEn+0ux5CJpWfUWtjxM14byCx6j2uqjBQrqJcjXyLLgNW1EGHiUC1a3nTHqvkfiJWq5doOXvsRcRj2zgcaVn9gCZv38j7E7wve6W38lJffDE/X5fscigqpYTwGQodi5JFsRB9TwLk/YTdeARrpIErFPndCoiEJz3DCuVWO9pyndmFw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nutanix.com; dmarc=pass action=none header.from=nutanix.com; dkim=pass header.d=nutanix.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zFBwLIE8ewU3RDymVY+Nv+8NGsLrVZ4DjH2tHQn3RSw=; b=UeimUDjcxi/frw3Sk6shqQTkBzH0Rn8nk+ymnV1aoP56bDDMvH0qZhfATPnnM0AQ8l4t0golySl5OLbZNLBoeHmGb4dOw69/hSUwf1yAsLkaEn8hg3hC7CqldjYcAk5D0FU1Fg3u/IV1MTgq+YIX31hSpo8tsx8ozXMv0SqT5PZkCQxsU5uRig7vi+upc62/EuAB9MGkSe2gTJRJ+5eHA0YUcAoxCSVcyKQptYiCMpfQx+YWgrMxnsxkvLcXiTGlnb4q7KqIE48+cegPHLbMCDVTwUkiLE3iLmHpFNpY/FxrHWcVLMAcF3jwyp0Mawg4GEnmxtvQsTpaPlmU5qNdsg== From: Sandesh Patel To: devel@lists.libvirt.org Subject: [PATCH 2/3] qemu: format dma-translation on intel-iommu command line Date: Wed, 7 Aug 2024 07:37:51 +0000 Message-Id: <20240807073752.64256-3-sandesh.patel@nutanix.com> X-Mailer: git-send-email 2.22.3 In-Reply-To: <20240807073752.64256-1-sandesh.patel@nutanix.com> References: <20240807073752.64256-1-sandesh.patel@nutanix.com> X-ClientProxiedBy: SJ0PR03CA0135.namprd03.prod.outlook.com (2603:10b6:a03:33c::20) To IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: IA1PR02MB9017:EE_|CO1PR02MB8506:EE_ X-MS-Office365-Filtering-Correlation-Id: 4ad44a26-eee4-4087-af15-08dcb6b3e59c x-proofpoint-crosstenant: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|52116014|376014|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?rfeo0x77iNcZhpZNRRkjYRSR/6q6LtNxpGTImX4kqG47UMxWcXdlqVr+a2oK?= =?us-ascii?Q?rUHcRB96LcNtHNdZOqP+3ph4imezb0s0dZ8hU56HoBy7IiNckz/Ha8h1YD4X?= =?us-ascii?Q?Z+li/Ak+tNNjZoOiGIt6TA/yj2MLNJMHvK2/1BcuMqnJUx5JTGM8rxlccJTC?= =?us-ascii?Q?PFJjeUgx9gMVnudA6118muR4daovu1iC6d6ELK/aFFrOsZMG6DuKIitwiZwe?= =?us-ascii?Q?7PaU312oUMGGLoyrwXMpr54BgU5SiiSqzleqF8nTVgGkDdiKPc6Im67vw63B?= =?us-ascii?Q?DJQ3eFW9kbcW+DtWq0aspp0B7mG6SrcmNU17Xz7xjYjviqijL21J+Xz6lpce?= =?us-ascii?Q?jMiAP81hmOsNWDQHZBATTZFxx+5fFA6nwgQ0ajRapfIVC0cPURQ/Nshwz6Bz?= =?us-ascii?Q?NGw8Gd1vR5zw9bUJ/TnilFjBYKi2Qjxpoe2eMImnlpR7DkJheU8rwSnoQVQf?= =?us-ascii?Q?5KoAzAXs8ZTImlqOdHYEOBOQe+jXz3uOSS3KF3r5piIV78DXyXioK3vpSYiX?= =?us-ascii?Q?SQLqkNz8lzu4828lqUl2cv2EvPMPtA6O70CerW9KnHQ7Qompw/x2VqzF73fZ?= =?us-ascii?Q?1Q9Tzi/iJmrvkzZEYD4bILC3//hQvTcUc/z30/7GnP/QfigGt8UWyoNZ/Cmi?= =?us-ascii?Q?ady+InxphtGzWgl/hn0BOo9Hej10ZqwK8VD2YbwR0Lzu/bukR2ZXwES2sIL1?= =?us-ascii?Q?YKCcVLj2ibLj6gS7dZXZeHx3TO2qU502qsZHJPjocxo1hSDTGyV0AKUs27/2?= =?us-ascii?Q?DOvi2kFP59KIzMtjqXCyA5KbgiwJjp1NkfCpAAYg77mPANTYFN/epwwUTZEe?= =?us-ascii?Q?cSfZyk5tEmTSzcZcFD1iVZ3de9iBenftIl6tc/68VPexkryd+IEvPGJ2RiND?= =?us-ascii?Q?zjJTJ8WU7gaYIeL7S2bB1trkS/oxg8d0uGHhLCHZXzPGjGM9DgFvQ5hfK1J6?= =?us-ascii?Q?oCIN+QNfHNPRlKlBF6GmFligD4jLJVZuTtAy9eLYADhP+NR/103L5TZa4K2p?= =?us-ascii?Q?L/jy4cjjGo3gGh0j2/0IvtmiTv75nqfWHa/VTWwhd2z8eK//KXiatHA5DKtU?= =?us-ascii?Q?Xtlp6LGaBYzcJzFhMelyr2cfULpD+An/OnCfCXwJbDl6fPULv0v512Qg0wHw?= =?us-ascii?Q?Eq9GIaJr+knzjyTdzlY4zY5zdyDidwTGEsn3/xGOZlyO2Sj9yYxxY0dBBajd?= =?us-ascii?Q?mbKXhx6f9JiDsZCx96cCSec6neXBDTa+Yw89Qura1qiGHgPlbLxc6TiyTjww?= =?us-ascii?Q?AXXO6yqsU+Evk+lZPL2kjN/j7kwU09IjjlSGpEwW6NeTPDpAFuhHfq18kWRX?= =?us-ascii?Q?2RmlQKKA6B/i6m1W1jtWt3dib7RnFxCaxjDtj96cvLxqbqpRQwoGSqVPPmvG?= =?us-ascii?Q?gLLqAQOvBYKf1ViROEItWnqNC80YYd8d/uFw3XvFDagv3Y5+NQ=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:IA1PR02MB9017.namprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(366016)(52116014)(376014)(38350700014);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?dJKymSwsr0PDE3/dZ/4oiSBTVv+fo8DTMS0C0D5rqTQYEUBKMDDdTMjRhoIU?= =?us-ascii?Q?wqjTkmKfl+IXNP5yrhrktEpkZeMAauX19ZYl8EpCMz1sfqpjcH1RGn5q9l0V?= =?us-ascii?Q?M/ND/w/Oxyrvt8Ihq18akCEGFZpAmj50r2qRoDtQwXbOByeghdTDEQF/VYbz?= =?us-ascii?Q?5O/GIISfge700hi22KHdDooTwsiniIuZXz59NT89rUpSYASecfVeB0CCD263?= =?us-ascii?Q?/yOQec82vGxomMBwQxTUeyBcQbxRhOJZzGSiu1uy190FTsvecT7qr95TC3EG?= =?us-ascii?Q?gP1wmCXjXjcMFUdmfCN+itW1xVzUm4Pzr/F07ShyS6orZtLySM3tRHk7BJ/F?= =?us-ascii?Q?qYaIHfzhe7IR6QEJ17x6R239VdZtId8fiibiiwhejfh0Ras1VotZIW31lDPl?= =?us-ascii?Q?6RLIkHf6CDNpIJz2QXT6ZBNsAT5Bl4kYODvkgIuRiFxOcnDHDvreMj1rSdJz?= =?us-ascii?Q?Alprbecexs/IP83x8VdkGZBqosDRiukAGGTAP5MRWdmGizUs02ZZzyJtsLhY?= =?us-ascii?Q?qYMgvA3W65W3e/ZC3ZQhlwkvqbiU91Ec7OBajm0ORWDlcuqlkNn2w1eS3E6v?= =?us-ascii?Q?yXyfCf7FBJU/9z5IKsQcfptwTc4Rl9ZKRuH1PaU505XLzs4jZ/0d5O2ZwHLD?= =?us-ascii?Q?nOnTR9cgseH7cB5/Gyrr2gCbERBzU3rZSR3jpvhWoBMZm/4KytIztHJT8Jkz?= =?us-ascii?Q?XT/91nL3sv5IxJYf6T2VBZl4ca2hxAFX18E8lCEjmFiRaJpWB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ix.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4ad44a26-eee4-4087-af15-08dcb6b3e59c X-MS-Exchange-CrossTenant-AuthSource: IA1PR02MB9017.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Aug 2024 07:38:14.8194 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: bb047546-786f-4de1-bd75-24e5b6f79043 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: YlUQJOK0dSVa13tD97Gh2MkJeTkstpVGX26aH2YjDR4b32CcsEClA3WhoQFBOnyJXO35/lR4jstAwrbNhPWAQ6/xJBvYQdN0ivq1STcQeiE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR02MB8506 X-Proofpoint-ORIG-GUID: otiTUwRieAt5NRwVl0UKxPkjQ_NSzILd X-Proofpoint-GUID: otiTUwRieAt5NRwVl0UKxPkjQ_NSzILd X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.28.16 definitions=2024-08-07_04,2024-08-06_01,2024-05-17_01 X-Proofpoint-Spam-Reason: safe Content-Transfer-Encoding: quoted-printable Message-ID-Hash: ZGJJYZJ6RCPEVLWB4OGJ534NSSA7PUWN X-Message-ID-Hash: ZGJJYZJ6RCPEVLWB4OGJ534NSSA7PUWN X-MailFrom: sandesh.patel@nutanix.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: Sandesh Patel X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-ZohoMail-DKIM: fail (found 2 invalid signatures) X-ZM-MESSAGEID: 1723016371949116600 Content-Type: text/plain; charset="utf-8" Add dma-translation attribute to qemu command line if specified in domain conf. Signed-off-by: Sandesh Patel Reviewed-by: Michal Privoznik > Reviewed-by: Michal Privoznik --- src/qemu/qemu_capabilities.c | 2 ++ src/qemu/qemu_capabilities.h | 1 + src/qemu/qemu_command.c | 1 + src/qemu/qemu_validate.c | 6 ++++++ 4 files changed, 10 insertions(+) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 29dfe8d35a..2f66a49711 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -713,6 +713,7 @@ VIR_ENUM_IMPL(virQEMUCaps, "sev-snp-guest", /* QEMU_CAPS_SEV_SNP_GUEST */ "netdev.user", /* QEMU_CAPS_NETDEV_USER */ "acpi-erst", /* QEMU_CAPS_DEVICE_ACPI_ERST */ + "intel-iommu.dma-translation", /* QEMU_CAPS_INTEL_IOMMU_DMA_= TRANSLATION */ ); =20 =20 @@ -1516,6 +1517,7 @@ static struct virQEMUCapsDevicePropsFlags virQEMUCaps= DevicePropsIntelIOMMU[] =3D { { "eim", QEMU_CAPS_INTEL_IOMMU_EIM, NULL }, { "device-iotlb", QEMU_CAPS_INTEL_IOMMU_DEVICE_IOTLB, NULL }, { "aw-bits", QEMU_CAPS_INTEL_IOMMU_AW_BITS, NULL }, + { "dma-translation", QEMU_CAPS_INTEL_IOMMU_DMA_TRANSLATION, NULL }, }; =20 static struct virQEMUCapsDevicePropsFlags virQEMUCapsDevicePropsMCH[] =3D { diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 51d951771d..edeb870e01 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -692,6 +692,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for = syntax-check */ QEMU_CAPS_SEV_SNP_GUEST, /* -object sev-snp-guest */ QEMU_CAPS_NETDEV_USER, /* -netdev user */ QEMU_CAPS_DEVICE_ACPI_ERST, /* -device acpi-erst */ + QEMU_CAPS_INTEL_IOMMU_DMA_TRANSLATION, /* intel-iommu.dma-translation = */ =20 QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags; diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index f15e6bda1e..28914c9c34 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -6209,6 +6209,7 @@ qemuBuildIOMMUCommandLine(virCommand *cmd, "S:eim", qemuOnOffAuto(iommu->eim), "T:device-iotlb", iommu->iotlb, "z:aw-bits", iommu->aw_bits, + "T:dma-translation", iommu->dma_translat= ion, NULL) < 0) return -1; =20 diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c index 0e8f0f977f..b885fe7c77 100644 --- a/src/qemu/qemu_validate.c +++ b/src/qemu/qemu_validate.c @@ -5094,6 +5094,12 @@ qemuValidateDomainDeviceDefIOMMU(const virDomainIOMM= UDef *iommu, _("iommu: aw_bits is not supported with this QEMU b= inary")); return -1; } + if (iommu->dma_translation !=3D VIR_TRISTATE_SWITCH_ABSENT && + !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_DMA_TRANSLATION)) = { + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", + _("iommu: updating dma translation is not supported= with this QEMU binary")); + return -1; + } =20 return 0; } --=20 2.22.3 From nobody Sat Nov 23 15:02:26 2024 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; arc=fail (BodyHash is different from the expected one); dmarc=fail(p=none dis=none) header.from=nutanix.com Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1723016412226515.6819500507096; Wed, 7 Aug 2024 00:40:12 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 3DDCEA63; Wed, 7 Aug 2024 03:40:11 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id C4DED124C; Wed, 7 Aug 2024 03:38:38 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id AC29412DC; Wed, 7 Aug 2024 03:38:34 -0400 (EDT) Received: from mx0a-002c1b01.pphosted.com (mx0a-002c1b01.pphosted.com [148.163.151.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id 4974C12DC for ; Wed, 7 Aug 2024 03:38:21 -0400 (EDT) Received: from pps.filterd (m0127840.ppops.net [127.0.0.1]) by mx0a-002c1b01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 476LvQUq003982 for ; Wed, 7 Aug 2024 00:38:20 -0700 Received: from nam04-bn8-obe.outbound.protection.outlook.com (mail-bn8nam04lp2045.outbound.protection.outlook.com [104.47.74.45]) by mx0a-002c1b01.pphosted.com (PPS) with ESMTPS id 40sgvrquh7-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 07 Aug 2024 00:38:20 -0700 (PDT) Received: from IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) by CO1PR02MB8506.namprd02.prod.outlook.com (2603:10b6:303:159::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7828.23; Wed, 7 Aug 2024 07:38:17 +0000 Received: from IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616]) by IA1PR02MB9017.namprd02.prod.outlook.com ([fe80::d569:fbdf:590c:d616%3]) with mapi id 15.20.7828.023; Wed, 7 Aug 2024 07:38:17 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s= proofpoint20171006; bh=0kczlHk0plavNjm8N+5lqJC912y4O/x3jn6QOZQ5+ Cc=; b=v1TQrVl7bMfLRjimLOWTyLkOVlA0EXbnWk6gU0gAxiNegwZZvQn88K7XS fxxTDAzAySlZZ0fJDf/vJ65NbUnGATfGj/z2kck6/4YYjXKz4bWkSyhUfW74m4qa YoV8nOVyEIgbJe+f0vyV5dl1BIbX9UmyW8Br9KF/VGRiZDDE5m2R9roZoOsv61aV 6u6QwyjT4ow+wjkmO7FRjHks/b/GsVle0PD/89q1GL+yCymBmnMguJt5iHvbJDX2 RorIL12m6O/dhBUSLgCklvCEnGfGN29XSzZFdI217EGfYtr/xtjNLu0Qs4a1bMIT f1t2K8YzXUMZDmzQd+KjmXkhsgzWA== ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ghaCHWP/pOE2NvMxukPmwqnU5r04s0tMfWgX0C5HSsKVANBiHNNK12qto/Re7Lfm41JRkH9BczeK7edUf96eUKbTGHe8l4mDGkc7ol9iuYLTUEy96peHaRDFEFk/Fov6HpQhQdMSEgEP8GYOjSB+BqUN8UaJY57Y92ZpXsOqvt88+ey/1bS9JLqNumovOxL13bKZrDy8Qtp74NQyDZkNdkuP2wuHUsFYazAerQSTNALGjLOzOsoSZ6iBkt8zYTD4SX1h0Su0x7gN+CUAItF0UASv8tmhSceTrBzoOh1bg11Q8/jJcSg6L3Lah8y2drgFlxsUDlITJzvKYpK6gZ6vnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=0kczlHk0plavNjm8N+5lqJC912y4O/x3jn6QOZQ5+Cc=; b=BZfNxjBpflOr37TCUO0o9ljiK5JXOyPYnsYYq9YdR5zaYWNuKDLu74QYoqNuE06Ag4ouULmdm13OPHmv++CPpXjZ4sSb4sgQY6cYfwmaFzR4K4jQrxy5I2McrFhkGYaCBOg71WJGnmJmOxZv32+nG9xvvcKf4RGfHTe/a8MfySq0q9ayYAKkeflnVRug5F9xD9j2N9g1FydxocHZAH8tAL1+HswwsY8lPLSfq1tmaGIE70/OlVsTyc5/7hbZOJtMu7WMeer//zR0Yc4MZNskqUBb2EIenu7XYhlCWsdGGGYTiFgu85R8B9CNhGa+gcgCjhNtvIQTXvLCMUQwI8Mphg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nutanix.com; dmarc=pass action=none header.from=nutanix.com; dkim=pass header.d=nutanix.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nutanix.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0kczlHk0plavNjm8N+5lqJC912y4O/x3jn6QOZQ5+Cc=; b=PbHOFi1rIxgzGgHmg1/aTxrwZkB7iLWEkrQBSqEVeFhqrsB8IH1eoYoKtQUFulEUnEIM21K5QjfY06wnvuWdB2d3QMkDEmpYzQm68mjoLMe70yox+pQApNP8xG/5v3pEuxlFzWXNycraHkyKSH2yfzlJoFcBjbl/rHNFR8acDjWwTx7odwxfBp36/qKBlW5Yw9MMBiKfPdG3ayy/CAr+CB7lYuHovppDMk/Lf8JveFCpwt5KAQvb2xDwdYFjhEKBGIV3Lq8pvrJjpjVGkeaMXtS8+xL3VsKPKHBkLuQxU79OXO6OlP80JfHYagZeBT1bI1PQk9FnzdtZp3sBqeX0zw== From: Sandesh Patel To: devel@lists.libvirt.org Subject: [PATCH 3/3] tests: add test for intel-iommu dma-translation attribute Date: Wed, 7 Aug 2024 07:37:52 +0000 Message-Id: <20240807073752.64256-4-sandesh.patel@nutanix.com> X-Mailer: git-send-email 2.22.3 In-Reply-To: <20240807073752.64256-1-sandesh.patel@nutanix.com> References: <20240807073752.64256-1-sandesh.patel@nutanix.com> X-ClientProxiedBy: SJ0PR03CA0135.namprd03.prod.outlook.com (2603:10b6:a03:33c::20) To IA1PR02MB9017.namprd02.prod.outlook.com (2603:10b6:208:3ab::12) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: IA1PR02MB9017:EE_|CO1PR02MB8506:EE_ X-MS-Office365-Filtering-Correlation-Id: 8df5219e-8588-41ac-9fe1-08dcb6b3e723 x-proofpoint-crosstenant: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|1800799024|366016|52116014|376014|38350700014; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?QjQRoKrUA5xSpTOzd2SIAU7GSzijIRSOIW13hCJyHPj6+TUPL67vEJsP99eF?= =?us-ascii?Q?ZmLHNxAbAUInCLbzGA50IEpgkMIytQvEVbYIoD6OeG4HKJmXRXA1Xx4r6jla?= =?us-ascii?Q?OFiOsJD7ZVTWp1HzYfenQY6InF0Qeul2I2/wcyrjEyXlsuAz6a7CY5F5sBFY?= =?us-ascii?Q?KHsmhZhfUvbFJx5a4oFs3SRMrf8Yfs11PpQNKMhavQtrcGdxVfyZTEW7Wrzf?= =?us-ascii?Q?z8c37SY0hP0YH/xK01LzKSesXAoByhjnDbxf1j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5qoT4Nb2PXIB0pZHIALrGaclYNO28tI+OiLO4RWu?= =?us-ascii?Q?4KZ21degw18pz6keu4P9aCIj+rMZ5vZr02tg0dVgxiGtcJ+ql+lbKqON34Sa?= =?us-ascii?Q?noi01GcT2VegPWPEQztYhrq4iVdK5yaPdWEdhEDrx3r+dMEP849qosKYj9YZ?= =?us-ascii?Q?gVvZup9jEzx5N76YWCR3ElukrVnRqcKBGX+1apN7znPurFb85RdyyhoUNxzo?= =?us-ascii?Q?gvFDqIsE+IaeEUOPzKipS8JHE4I8fAqm2vAcCq/4Ne7Obf2CGw=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:IA1PR02MB9017.namprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(1800799024)(366016)(52116014)(376014)(38350700014);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?xp5xkCFspfRbnZKSfvcvmsmvdOhtlZ4u51qBcUMTRdUxJVnoEL2MlBfL05Lr?= =?us-ascii?Q?uhhdcT6s4kMCvbqwLwaAZmZE4ukyy0gIkphJjExdwHClPVaUmydPTjD0aslp?= =?us-ascii?Q?T6dPPeebWXiUVtd/qA7599hvaHeVfGasDO8X4lBz1mJGRle51/45ztWEaJOa?= =?us-ascii?Q?ZM7x4FBgEydCSwieIwgYkiP/tWvyvyEujypogUW020fWSWwSvhsQES8kk8d6?= =?us-ascii?Q?vMaMXdjCrJ4jTvprYI1jFkmn5H6+hvnpTA+FJ27HillTpElOs7yyssoadsLA?= =?us-ascii?Q?YwIy/hBSWc8l740jVjJkZ9COcDuVKRNEVg9kBWNa5uyhBiHW9NHh3KWSwBSg?= =?us-ascii?Q?BdlVHtrAFEAVYf8OnAPF4YrSKza4ur2GAc/Jd8lRZ0JuufigRCtlgAbqc8h2?= =?us-ascii?Q?s1cNW41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?= =?us-ascii?Q?kJaD7cy8XztFEEQNWvThk/vKGbsUvhuP7yThxx7+BQr2JKE/zCykh9Hbv0VZ?= =?us-ascii?Q?gH2mozJrDHzrShxg2IOmzql30BZ2b2RTtMainHyMizR5sLQP0UckgNiOHJsj?= =?us-ascii?Q?R3PPlTd43ODznQ7uUGz8YO5zSBeI2CZBYWN0hgwFt1ubK9aHaj8FBmGFoIZH?= =?us-ascii?Q?KYEZgDJLl5J2NwF6dxa4iKsoP+ikkwxgQ1Sbjg0XIMx3zCMVoKefKmrqCZIz?= =?us-ascii?Q?4idg+xEJwvMkROc4ULcXwcEn27PjDw4vI7DVIE6AwFd8N5HCoy1DogTWq8tB?= =?us-ascii?Q?gw=3D=3D?= X-OriginatorOrg: nutanix.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8df5219e-8588-41ac-9fe1-08dcb6b3e723 X-MS-Exchange-CrossTenant-AuthSource: IA1PR02MB9017.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Aug 2024 07:38:17.3992 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: bb047546-786f-4de1-bd75-24e5b6f79043 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: DLhmz4QjkA8fQjnVJFezN97C84LUP4mGUjfMonxmrnrVur2X/YxgmB0l4EeNGQbhRsUB5xxAq9+2ktx7xgHIBhStjXzOlt1rGcfecvIMvk0= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR02MB8506 X-Proofpoint-GUID: SESnsq_Sx_urkYCit_HWKtGFjS1M18ur X-Proofpoint-ORIG-GUID: SESnsq_Sx_urkYCit_HWKtGFjS1M18ur X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.28.16 definitions=2024-08-07_04,2024-08-06_01,2024-05-17_01 X-Proofpoint-Spam-Reason: safe Content-Transfer-Encoding: quoted-printable Message-ID-Hash: 3VMT2GGWRJUPDQENQSTAQE5GKCZ64WBY X-Message-ID-Hash: 3VMT2GGWRJUPDQENQSTAQE5GKCZ64WBY X-MailFrom: sandesh.patel@nutanix.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header CC: Sandesh Patel X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-ZohoMail-DKIM: fail (found 2 invalid signatures) X-ZM-MESSAGEID: 1723016414077116600 Content-Type: text/plain; charset="utf-8" Test data for the intel-iommu dma-translation attribute added previously Signed-off-by: Sandesh Patel Reviewed-by: Michal Privoznik > Reviewed-by: Michal Privoznik --- .../caps_7.1.0_x86_64.xml | 1 + .../caps_7.2.0_x86_64+hvf.xml | 1 + .../caps_7.2.0_x86_64.xml | 1 + .../caps_8.0.0_x86_64.xml | 1 + .../caps_8.1.0_x86_64.xml | 1 + .../caps_8.2.0_x86_64.xml | 1 + .../caps_9.0.0_x86_64.xml | 1 + .../caps_9.1.0_x86_64.xml | 1 + .../migration-out-nbd-bitmaps-in.xml | 1 + ...l-iommu-dma-translation.x86_64-latest.args | 34 +++++++++++++++++ ...el-iommu-dma-translation.x86_64-latest.xml | 1 + .../intel-iommu-dma-translation.xml | 37 +++++++++++++++++++ tests/qemuxmlconftest.c | 1 + 13 files changed, 82 insertions(+) create mode 100644 tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_6= 4-latest.args create mode 120000 tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_6= 4-latest.xml create mode 100644 tests/qemuxmlconfdata/intel-iommu-dma-translation.xml diff --git a/tests/qemucapabilitiesdata/caps_7.1.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_7.1.0_x86_64.xml index 555120e958..9737e3d083 100644 --- a/tests/qemucapabilitiesdata/caps_7.1.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_7.1.0_x86_64.xml @@ -192,6 +192,7 @@ + 7001000 43100244 v7.1.0 diff --git a/tests/qemucapabilitiesdata/caps_7.2.0_x86_64+hvf.xml b/tests/q= emucapabilitiesdata/caps_7.2.0_x86_64+hvf.xml index ca25a5549e..55dcbf203e 100644 --- a/tests/qemucapabilitiesdata/caps_7.2.0_x86_64+hvf.xml +++ b/tests/qemucapabilitiesdata/caps_7.2.0_x86_64+hvf.xml @@ -196,6 +196,7 @@ + 7002000 43100245 v7.2.0 diff --git a/tests/qemucapabilitiesdata/caps_7.2.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_7.2.0_x86_64.xml index 8b835e6187..1253c860ee 100644 --- a/tests/qemucapabilitiesdata/caps_7.2.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_7.2.0_x86_64.xml @@ -196,6 +196,7 @@ + 7002000 43100245 v7.2.0 diff --git a/tests/qemucapabilitiesdata/caps_8.0.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_8.0.0_x86_64.xml index 3ac9e96066..d3901fef05 100644 --- a/tests/qemucapabilitiesdata/caps_8.0.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_8.0.0_x86_64.xml @@ -200,6 +200,7 @@ + 8000000 43100244 v8.0.0 diff --git a/tests/qemucapabilitiesdata/caps_8.1.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_8.1.0_x86_64.xml index 476195d147..f8a9993ede 100644 --- a/tests/qemucapabilitiesdata/caps_8.1.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_8.1.0_x86_64.xml @@ -202,6 +202,7 @@ + 8001000 43100245 v8.1.0 diff --git a/tests/qemucapabilitiesdata/caps_8.2.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_8.2.0_x86_64.xml index 25cb22aafc..43d7105c2d 100644 --- a/tests/qemucapabilitiesdata/caps_8.2.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_8.2.0_x86_64.xml @@ -205,6 +205,7 @@ + 8002000 43100246 v8.2.0 diff --git a/tests/qemucapabilitiesdata/caps_9.0.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_9.0.0_x86_64.xml index b646377dec..e96af86a92 100644 --- a/tests/qemucapabilitiesdata/caps_9.0.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_9.0.0_x86_64.xml @@ -207,6 +207,7 @@ + 9000000 43100245 v9.0.0 diff --git a/tests/qemucapabilitiesdata/caps_9.1.0_x86_64.xml b/tests/qemuc= apabilitiesdata/caps_9.1.0_x86_64.xml index dc548583a5..e17c22d776 100644 --- a/tests/qemucapabilitiesdata/caps_9.1.0_x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_9.1.0_x86_64.xml @@ -205,6 +205,7 @@ + 9000050 43100246 v9.0.0-1388-g80e8f06021-dirty diff --git a/tests/qemustatusxml2xmldata/migration-out-nbd-bitmaps-in.xml b= /tests/qemustatusxml2xmldata/migration-out-nbd-bitmaps-in.xml index 4ee44ffbd4..15fa35620d 100644 --- a/tests/qemustatusxml2xmldata/migration-out-nbd-bitmaps-in.xml +++ b/tests/qemustatusxml2xmldata/migration-out-nbd-bitmaps-in.xml @@ -261,6 +261,7 @@ + diff --git a/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-lates= t.args b/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-latest.ar= gs new file mode 100644 index 0000000000..cc7f819f5c --- /dev/null +++ b/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-latest.args @@ -0,0 +1,34 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/var/lib/libvirt/qemu/domain--1-QEMUGuest1 \ +USER=3Dtest \ +LOGNAME=3Dtest \ +XDG_DATA_HOME=3D/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=3D/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=3D/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.config \ +/usr/bin/qemu-system-x86_64 \ +-name guest=3DQEMUGuest1,debug-threads=3Don \ +-S \ +-object '{"qom-type":"secret","id":"masterKey0","format":"raw","file":"/va= r/lib/libvirt/qemu/domain--1-QEMUGuest1/master-key.aes"}' \ +-machine q35,usb=3Doff,kernel_irqchip=3Dsplit,dump-guest-core=3Doff,memory= -backend=3Dpc.ram,acpi=3Doff \ +-accel kvm \ +-cpu qemu64 \ +-m size=3D219136k \ +-object '{"qom-type":"memory-backend-ram","id":"pc.ram","size":224395264}'= \ +-overcommit mem-lock=3Doff \ +-smp 1,sockets=3D1,cores=3D1,threads=3D1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,fd=3D1729,server=3Don,wait=3Doff \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ +-rtc base=3Dutc \ +-no-shutdown \ +-boot strict=3Don \ +-device '{"driver":"intel-iommu","id":"iommu0","intremap":"on","dma-transl= ation":false}' \ +-audiodev '{"id":"audio1","driver":"none"}' \ +-global ICH9-LPC.noreboot=3Doff \ +-watchdog-action reset \ +-sandbox on,obsolete=3Ddeny,elevateprivileges=3Ddeny,spawn=3Ddeny,resource= control=3Ddeny \ +-msg timestamp=3Don diff --git a/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-lates= t.xml b/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-latest.xml new file mode 120000 index 0000000000..a35a254f7a --- /dev/null +++ b/tests/qemuxmlconfdata/intel-iommu-dma-translation.x86_64-latest.xml @@ -0,0 +1 @@ +intel-iommu-dma-translation.xml \ No newline at end of file diff --git a/tests/qemuxmlconfdata/intel-iommu-dma-translation.xml b/tests/= qemuxmlconfdata/intel-iommu-dma-translation.xml new file mode 100644 index 0000000000..9b4debca0a --- /dev/null +++ b/tests/qemuxmlconfdata/intel-iommu-dma-translation.xml @@ -0,0 +1,37 @@ + + QEMUGuest1 + c7a5fdbd-edaf-9455-926a-d65c16db1809 + 219100 + 219100 + 1 + + hvm + + + + + + + qemu64 + + + destroy + restart + destroy + + /usr/bin/qemu-system-x86_64 + + + +
+ + + +