From nobody Mon Nov 25 09:57:58 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass header.i=@eviden.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; arc=pass (i=1 dmarc=pass fromdomain=eviden.com); dmarc=pass(p=reject dis=none) header.from=eviden.com ARC-Seal: i=2; a=rsa-sha256; t=1716297172; cv=pass; d=zohomail.com; s=zohoarc; b=M3PTs9wH6tj+xy6FGTSzibNk4Zl1wh/nrh3FlCRAX20babb8PHu5ldhvGqs9PDoNlBeRImT+so/93u+I4iiwQ8dyH+EEXREVw2u49afA+3+iYZ0zBgPlaRYsp2uYHg3MqOu4wqKxf9YayY0dWQKCkYI1rg5Re/idN82Ul3fuRto= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1716297172; h=Content-ID:Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=OYW6nDkzOmyJAYhlc9/fa1EDVXZlqVKe7EKbL9TNrZk=; b=IfnmTbGOYiTL5YuzD2ykkWZE0LqOL7njzqklJuZbX6EiviseufkjzjjSF1VK+zs3lPijYRnO32qg58mTEmoHlpHUXcYoY7MSh9BYdjLbvQWJaVqeLgnH6AGhS+wJcf3lVcjYUj+sQoHKn5RVssZ1LetHyPfwgqb7gaOzDrfheU4= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass header.i=@eviden.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; arc=pass (i=1 dmarc=pass fromdomain=eviden.com); dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1716297172716475.72098555129014; Tue, 21 May 2024 06:12:52 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s9PIH-0000ip-Rp; Tue, 21 May 2024 09:12:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s9PHk-00080J-RX for qemu-devel@nongnu.org; Tue, 21 May 2024 09:12:09 -0400 Received: from smarthost2.eviden.com ([80.78.11.83]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s9PHX-0001a9-Kt for qemu-devel@nongnu.org; Tue, 21 May 2024 09:12:08 -0400 Received: from mail-dbaeur03lp2169.outbound.protection.outlook.com (HELO EUR03-DBA-obe.outbound.protection.outlook.com) ([104.47.51.169]) by smarthost2.eviden.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 May 2024 15:11:54 +0200 Received: from AM8PR07MB7602.eurprd07.prod.outlook.com (2603:10a6:20b:24b::7) by DB8PR07MB6249.eurprd07.prod.outlook.com (2603:10a6:10:140::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7587.27; Tue, 21 May 2024 13:11:53 +0000 Received: from AM8PR07MB7602.eurprd07.prod.outlook.com ([fe80::fbd7:ca71:b636:6f9d]) by AM8PR07MB7602.eurprd07.prod.outlook.com ([fe80::fbd7:ca71:b636:6f9d%5]) with mapi id 15.20.7587.035; Tue, 21 May 2024 13:11:53 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=eviden.com; i=@eviden.com; q=dns/txt; s=mail; t=1716297115; x=1747833115; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-id:content-transfer-encoding: mime-version; bh=OYW6nDkzOmyJAYhlc9/fa1EDVXZlqVKe7EKbL9TNrZk=; b=DmXLKpuYbMHb5wNrlo7W+hIlfo6d4b4wEdDQMOHy1eqaaFaJ2QKCdvTJ b8UbawVlJsLAFQAbsbKqncQsGInfklkvsGrmUSRj05nK4AW04p7TLFfX5 vQki8ZZKmdDBmUQewBN+8pz/oySYb+RbXPR8v35hRA+KyqSGdreUbY4dC AEx0OsA3yxBjR7MZH5CwxrHMxw88maIOHI0OCbvrYITO5FNLLkV4huEeR fKEc9X0JO9HY8vQxLJPCT9aPx5u+Z2z9eDRlVvoxQJTX3jjQyCFr3ASWC Oq5f+09yF7TTfhh0+fOhDEVcy+A2ao/3BeDqZ3iE4EWKvtiA5RNSP1nRg w==; X-IronPort-AV: E=Sophos;i="6.08,177,1712613600"; d="scan'208";a="13011538" X-MGA-submission: =?us-ascii?q?MDFXN0FrgkUGvL6RFU9+0ZjBjEznCVzp8ehWHn?= =?us-ascii?q?5K4xQlObfTmn5H4npf1weu0fAp2s2+yZ+R7PVbG2aeYCRVsmUZV7Rrk/?= =?us-ascii?q?Z0AzBRwctD+VdwGq+yVixnLy5OxSPYB4nKpyXwUojyQSNFRAujevSzGm?= =?us-ascii?q?GPfsppAn1uQW2fzLEFQ3haUA=3D=3D?= ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KRwQuYaF/hXovTJ5LZ9Nkv9wWtjdndcBcNrbHEKapDH/LMczQOlOx2QQTrBCyLUpT9iuh5Soz0086/hjYbzl0eL08/zmErVIJyD7KxDtKk5NKoC16Yzwvn9lfjfBJ/0D8Q1ZL9Uxx+gZkuuvolCrE9MksclnMr49WntGCF6PsQUdBiTYyYEFUxRyRHcYmceFonUWYv8uVwtIXEyAtW2tZ+zdOrAkQ4TUrTeq/zlmmuLltG2j8r6Bnb3TVDTfQv0ZZkMdUK9DJajAVzBfDllJpXb+stCX/GVbYqzPTcx1h3EMVW+1wB78FR7T1PB1rP245GcF0NZpUUXR9+G1O6wu9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=OYW6nDkzOmyJAYhlc9/fa1EDVXZlqVKe7EKbL9TNrZk=; b=gSVQhUKHsBPtQ/PPVXD1Cfraaq37QY19QWYykYuHzqvU/g25xQM6rT2cgq1ddoI4kaO3W9juillbjtKS/IqJzwDBW4Hb7fsZyF44nhNJ0gebelYX8Bex7hI2UrRKgi5BWl9TKXKdatR99rcsfr0BDhptHBpJkvoSE/Zo0aWpOxbwNVEX2ypxNNR/USteiQm2s56q804HmC1EMPTaiMo9dxMKf48UzvPYy10KdIEedwGl3ulXCepOyWocXVi+4rwCrl+qmE/yGnPKtRlLqSkftcVcm0SS9jiNxlvubB8vnrN7vJxs0kiWLE7lhe1GazAXfOx6XlXh3erI/4+DazI6ag== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=eviden.com; dmarc=pass action=none header.from=eviden.com; dkim=pass header.d=eviden.com; arc=none From: CLEMENT MATHIEU--DRIF To: "qemu-devel@nongnu.org" CC: "jasowang@redhat.com" , "zhenzhong.duan@intel.com" , "kevin.tian@intel.com" , "yi.l.liu@intel.com" , "joao.m.martins@oracle.com" , "peterx@redhat.com" , CLEMENT MATHIEU--DRIF Subject: [PATCH ats_vtd 21/22] intel_iommu: set the address mask even when a translation fails Thread-Topic: [PATCH ats_vtd 21/22] intel_iommu: set the address mask even when a translation fails Thread-Index: AQHaq4Bz7Ru33W1vwk2nGsDl0E/tfg== Date: Tue, 21 May 2024 13:11:53 +0000 Message-ID: <20240521130946.117849-22-clement.mathieu--drif@eviden.com> References: <20240521130946.117849-1-clement.mathieu--drif@eviden.com> In-Reply-To: <20240521130946.117849-1-clement.mathieu--drif@eviden.com> Accept-Language: en-GB, fr-FR, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=eviden.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: AM8PR07MB7602:EE_|DB8PR07MB6249:EE_ x-ms-office365-filtering-correlation-id: 86b9ede9-775f-49bc-6050-08dc79979593 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; ARA:13230031|366007|1800799015|376005|38070700009; x-microsoft-antispam-message-info: =?utf-8?B?bitxaytCYXpWNlVza0ZieVU2OW1OSGVYT3BwWHBkQzd0YWVaWWFBblpsbVB1?= =?utf-8?B?WUxYL0F6TEtyUCs0djc0T2FKUXFTZGZsS2cxNmFEV0I3QTFmWFNNekFORXJJ?= =?utf-8?B?U3NmQXdhWFM1SXR6SmlFNmlxc0cwcStZWlZ6aGdadlByZ2doLzJJay96cCtR?= =?utf-8?B?Y1pWSlp6VVo4MEpiRGluTG1pcFhhNEhJem5QWGtmOWNvY0UramsxbHppNVd2?= =?utf-8?B?d09FaTJOY201SFF2Y2wyRHl4eC85RzdCTnczUWtkektKY2VZQjl5SFgyUkJQ?= =?utf-8?B?dHE5TkEzNWtIbXVoS3pGb2dLVFVTUXhINmQ0TXJzaGtoYTVkKzR5TjhVdXgv?= =?utf-8?B?djZTSVNURlVQQXBoT3F1SDNSc09qd3dTbXNRSTl4YUxFZ2VWY0tSNU04cnlR?= =?utf-8?B?d1l3WVArUHprTVlicXVFR0ZUNEdMOFpNVnRrdVVQRUYrSHdqSDlPQS93b2Ny?= =?utf-8?B?NjM0cnBCTlFvYlV2cjh4T0I3SVdyV2NIeW95ZTB3N2U4MUdHK3lCRU5iU2lU?= =?utf-8?B?YVcwUWFuYWRCRk00eVlkcTF6WENlcDJhTlNMeUQyUEc4VG51ZFB6QkJWN0ZD?= =?utf-8?B?RGFYM3pldGFVbXlaSXJVUG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B?ekdobnJrZmdsWWdOVFlselRwdDYwUWFTbVQ2eTBuR1VGbW83d0txVVZ3d25o?= =?utf-8?B?T2RsbzcyYXJtc1RrREFyb29lQkh6V0UyWHdicHg1bDBPVHhXZzY1aGVUR1lZ?= =?utf-8?B?ZUJ6R2JrZWJPUWE0QVk4OU9ic0p6ZFNKNXl5dGl5cGI0SDV1YjFZd0RJUU5l?= =?utf-8?B?cFJPRThYSUtrSytLRTV2cGFJL0ZQeEN0aU5sdmJvSGZ2MFFxOGY4b1dEK3dx?= =?utf-8?B?NCtrbWZ0Z1B0T3lSM0VmeGdrb09JWU5Oc3pzaTV5blVYdDFkSmY2djEybm1D?= =?utf-8?B?WU5MaEpOQlVWRjBpbHlnUT09?= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM8PR07MB7602.eurprd07.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(366007)(1800799015)(376005)(38070700009); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?utf-8?B?MXlYUXc3ZHZYeXRyaUo1SXl4dGMvMjZmbU1YdTFwN09nQUwwQ3ZnMkZaaWlz?= =?utf-8?B?SktHUVhCVzM4ZFlxOFMvaFRxR2U1Qm16elRHeG41MkMyTFlGRGFqNkNpaTRv?= =?utf-8?B?SXFjZ0ZOb0lDanpWbkJPQ2tMaXFXNU5laW9kb0x3bWM2VUNyd3lqM3N6c3hp?= =?utf-8?B?dEE1Z01Bc1ViOEFBenR3NGxUSC93UlprTDFRZjJjQktOQ2xaZjFDb3lKbUQ2?= =?utf-8?B?N3dIRE1MaTVMQWZpZUVOK093dzFta3pNVEozUTVOZlI1d2xlOVdVV1N6aW1M?= =?utf-8?B?elFOK09LSzkxVFBaS1VzV09CL2NNTjFuU0EzOVcya1IzWDVxWVlsSXhSMW0x?= =?utf-8?B?c2s4dGVhd0ZQTGZqM1BwZX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xekRTYUFF?= =?utf-8?Q?pScfYiDlIqntluKwjT7lPd8=3D?= Content-Type: text/plain; charset="utf-8" Content-ID: <7A0A7C391FD5994FACA7E7235A4942D0@eurprd07.prod.outlook.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: eviden.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: AM8PR07MB7602.eurprd07.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 86b9ede9-775f-49bc-6050-08dc79979593 X-MS-Exchange-CrossTenant-originalarrivaltime: 21 May 2024 13:11:53.6044 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 7d1c7785-2d8a-437d-b842-1ed5d8fbe00a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: vqI2dHeXg0p5H8vyyXC9OnxCiCe53T8uy4ROpK9Svni4IOi+IL70VlhMWTxpvN5S4Gl+rYo3b3/H32TDp7IxUEnQ684wivDR8asXYLoJ/MyD6LGveF0L6CSWWYMJPod9 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR07MB6249 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=80.78.11.83; envelope-from=clement.mathieu--drif@eviden.com; helo=smarthost2.eviden.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @eviden.com) X-ZM-MESSAGEID: 1716297174469100029 Implements the behavior defined in section 10.2.3.5 of PCIe spec rev 5. This is needed by devices that support ATS. Signed-off-by: Cl=C3=A9ment Mathieu--Drif --- hw/i386/intel_iommu.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c index f08c3e8f00..496bed9447 100644 --- a/hw/i386/intel_iommu.c +++ b/hw/i386/intel_iommu.c @@ -2169,7 +2169,8 @@ static bool vtd_do_iommu_translate(VTDAddressSpace *v= td_as, PCIBus *bus, uint8_t bus_num =3D pci_bus_num(bus); VTDContextCacheEntry *cc_entry; uint64_t pte, page_mask; - uint32_t level, pasid =3D vtd_as->pasid; + uint32_t level =3D UINT32_MAX; + uint32_t pasid =3D vtd_as->pasid; uint16_t source_id =3D PCI_BUILD_BDF(bus_num, devfn); int ret_fr; bool is_fpd_set =3D false; @@ -2314,7 +2315,12 @@ error: vtd_iommu_unlock(s); entry->iova =3D 0; entry->translated_addr =3D 0; - entry->addr_mask =3D 0; + /* + * Set the mask for ATS (the range must be present even when the + * translation fails : PCIe rev 5 10.2.3.5) + */ + entry->addr_mask =3D (level !=3D UINT32_MAX) ? + (~vtd_slpt_level_page_mask(level)) : (~VTD_PAGE_MAS= K_4K); entry->perm =3D IOMMU_NONE; entry->pasid =3D PCI_NO_PASID; return false; --=20 2.44.0