From nobody Sat Nov 23 18:08:55 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/6q6LtNxp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WU7gaYIeL7S2bB1trkS/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/Oxyrvt8Ihq18akCEGFZpAmj50r2qRoDtQwXbOBye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RA5aI41F6vK4XIR9UCh4UKuMh3/m?= =?us-ascii?Q?C0poyRvsm3KRCHT9tAZUuCqtDgXrelb1kbMl/acYvl+oksSJMwE906A70rYm?= =?us-ascii?Q?ccQuxwj4BhnkM3TYl3Z6LxWUXbnbU+9MAa+u/NRd1b2GhdaYlA5vc7BpOnMA?= =?us-ascii?Q?zVxGXhnPmN2HeTm00f2XzNncIn7HgmY6izSMg0MXSloc4zVADBXTCPfamcat?= =?us-ascii?Q?bIyB0y2R2I6RnEM66vAratzcz57cPAhg4SNvEDMUNpGwXjyXu90XVrCGuL3P?= =?us-ascii?Q?0+bcHiPVpCmTuEbtOt8VQU9sD4MyIedDJm7YiwtrgBA6UW5fqCCsA+E88zlR?= =?us-ascii?Q?ejbLLR3qb/WnaUSrCaQ5civZVEjRWpu++QFnYqKTzlyTFlVJ49YXnTeoGXe+?= =?us-ascii?Q?/0QtzG0Kq5mO5Qul8CHEYD+08JHyq3GDldTcd5tI7bitL1+osrWjHwRORabm?= =?us-ascii?Q?GcqJz7pF4/0XQteK7+cfaS42EF2JL8DFJmyhXR2v/plAT/Nk4bfAPPKDYjDD?= =?us-ascii?Q?WQY1ETSgT1Bua1LShSH3fSQ+qMHfb1GP9/g/dkbH4XyXVDOOvFqsKqCb2BSt?= =?us-ascii?Q?vA=3D=3D?= X-OriginatorOrg: nutanix.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 --- 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