From nobody Mon Feb 9 16:35:18 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; 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; dmarc=pass(p=reject dis=none) header.from=oracle.com ARC-Seal: i=1; a=rsa-sha256; t=1748547151; cv=none; d=zohomail.com; s=zohoarc; b=SZizqcfuSSomFpWB31G0XiYpl+vhVDgTd9PE6Rb6bBE2bbaGkmYRKlmWNxKpOoSfRxoXvq/pa95qmFW5V5FlqFAMwgX1TziQqoaT41ybO5VupkaqzA+UmS3NBy6PSr9grm+H43/YXPfbZgb//ku0Hv9FOG8TLRmxz7GthkG8C70= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1748547151; h=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=+IzyZWe4Dth+7UIPZZsjEeVCKcuiOXMbHTkTOc62ePE=; b=hC4hwGsHhjPmXesyf4WlIf2dQzeeIZNFAsK9kXHoxs8NPXHOMOWRmFCU+i+Ac4tVELnKwKYuBsPO4sEg1BKiWcOCtnX1YLG7ZZBZ84jZFm4PENREaVkZpR2VjFlXAD0MrwFPGugHQMg+r2YoFzEPlBNGfHp73PEpOKkDSQVjGxg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; 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; 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 174854715112817.594915829262504; Thu, 29 May 2025 12:32:31 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1uKixd-0001VG-V5; Thu, 29 May 2025 15:30:42 -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 1uKixZ-0001Nk-S3 for qemu-devel@nongnu.org; Thu, 29 May 2025 15:30:38 -0400 Received: from mx0a-00069f02.pphosted.com ([205.220.165.32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1uKixV-0001F1-Bf for qemu-devel@nongnu.org; Thu, 29 May 2025 15:30:34 -0400 Received: from pps.filterd (m0246617.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 54TGftHF009747; Thu, 29 May 2025 19:30:27 GMT Received: from iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta01.appoci.oracle.com [130.35.100.223]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 46v46u105s-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 29 May 2025 19:30:27 +0000 (GMT) Received: from pps.filterd (iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (8.18.1.2/8.18.1.2) with ESMTP id 54TJLtB3019193; Thu, 29 May 2025 19:30:25 GMT Received: from pps.reinject (localhost [127.0.0.1]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTPS id 46u4jccryq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 29 May 2025 19:30:25 +0000 Received: from iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 54TJUOV7005039; Thu, 29 May 2025 19:30:25 GMT Received: from alaljimee5bm-ol9-20250405.osdevelopmeniad.oraclevcn.com (alaljimee5bm-ol9-20250405.allregionaliads.osdevelopmeniad.oraclevcn.com [100.100.254.235]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTP id 46u4jccrx6-2; Thu, 29 May 2025 19:30:25 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=cc :content-transfer-encoding:date:from:in-reply-to:message-id :mime-version:references:subject:to; s=corp-2025-04-25; bh=+IzyZ We4Dth+7UIPZZsjEeVCKcuiOXMbHTkTOc62ePE=; b=gBPiM9yikeh8joGmq7AT2 AXU62bNvMBduEwpZwgl8m3LWufumlvuyfr0qlb/+mDaBPP2nzbMaDUzSKAL1Jcfv ykMMEvjYtjmZLSDiDyO48wYVJK3IC+ouE+9j9/9P7Qut2hzC3/y7Y7LxqdRBpK1a qHGYxUeRlTHfIHueKgmWu63GKlrBUp2jlwUQK3CNkfLbPG6S3wKdDuLoluMyJXRn NmS2w4y5sby/0fMvbOtpJqbD92PqrmPNSjdC5FYfH4XWXml4k5JeH6cwPA3AX2uS Nxb0s0cxXVXOIwWeC2brwoNBc30f2rsU5FqL0nxonMqqwzP2rReqkJdw3TLGanS7 Q== From: Alejandro Jimenez To: qemu-devel@nongnu.org Cc: mst@redhat.com, pbonzini@redhat.com, mjt@tls.msk.ru, marcel.apfelbaum@gmail.com, richard.henderson@linaro.org, eduardo@habkost.net, vasant.hegde@amd.com, suravee.suthikulpanit@amd.com, santosh.shukla@amd.com, sarunkod@amd.com, brijesh.singh@amd.com, joao.m.martins@oracle.com, boris.ostrovsky@oracle.com, alejandro.j.jimenez@oracle.com Subject: [PATCH v3 1/7] amd_iommu: Fix Miscellaneous Information Register 0 offsets Date: Thu, 29 May 2025 19:30:17 +0000 Message-ID: <20250529193023.3590780-2-alejandro.j.jimenez@oracle.com> X-Mailer: git-send-email 2.43.5 In-Reply-To: <20250529193023.3590780-1-alejandro.j.jimenez@oracle.com> References: <20250529193023.3590780-1-alejandro.j.jimenez@oracle.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1099,Hydra:6.0.736,FMLib:17.12.80.40 definitions=2025-05-29_09,2025-05-29_01,2025-03-28_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 malwarescore=0 adultscore=0 spamscore=0 suspectscore=0 bulkscore=0 phishscore=0 mlxlogscore=999 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2505160000 definitions=main-2505290190 X-Proofpoint-GUID: UiCQWzVts88gES5hyksAcODjlhHOfx5S X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUwNTI5MDE5MCBTYWx0ZWRfX9hGCxTMGzR2j Q0HV9BBFgtKsM14aaqqOdIZF/x+y6H4ybeb5+U/2w33iu7w9jjn0hum3Yq+PkI0xaH4hfujMPKu 5WqjABgtIl5504nd5OWIctKpGNb60U7by79ucnsb+/0hYdJ6WQvOUkLbTdouYHYXAEKMPpBKsDi sctKE3G+b5uZnh5KM3dJtVX0SH3NCOq0bdN8NSX1e1vtibMPPRCf88AOoPQXJ8kTw6vz29/t1w6 +pm9wiNGEvopQjXb2r+xkY5haMA6+56cEghaTCuMIBSm/gq9A9q5rM2MdJovSDFK8F/sHv8/6uZ hHrzVW/hH+VUFUP94s4zQhK2F/xzr2hOyuTTiu31WIf9QBrFUseRwP50PoaDZf3k7j2IeEZoSY2 yPhoK3JFhTMTbZ8//U3oCPuPvJEni9v3wKIv4LfMx3JR478Afhg3dNt/L58FNfjB/Ay/glTK X-Authority-Analysis: v=2.4 cv=VskjA/2n c=1 sm=1 tr=0 ts=6838b5d3 b=1 cx=c_pps a=zPCbziy225d3KhSqZt3L1A==:117 a=zPCbziy225d3KhSqZt3L1A==:17 a=dt9VzEwgFbYA:10 a=69wJf7TsAAAA:8 a=yPCof4ZbAAAA:8 a=zd2uoN0lAAAA:8 a=wxXrq957UH6JcMcBEt4A:9 a=Fg1AiH1G6rFz08G2ETeA:22 cc=ntf awl=host:13206 X-Proofpoint-ORIG-GUID: UiCQWzVts88gES5hyksAcODjlhHOfx5S 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=205.220.165.32; envelope-from=alejandro.j.jimenez@oracle.com; helo=mx0a-00069f02.pphosted.com X-Spam_score_int: -32 X-Spam_score: -3.3 X-Spam_bar: --- X-Spam_report: (-3.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_MED=-0.499, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=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 @oracle.com) X-ZM-MESSAGEID: 1748547151501116600 Content-Type: text/plain; charset="utf-8" The definitions encoding the maximum Virtual, Physical, and Guest Virtual Address sizes supported by the IOMMU are using incorrect offsets i.e. the VASize and GVASize offsets are switched. Cc: qemu-stable@nongnu.org Fixes: d29a09ca6842 ("hw/i386: Introduce AMD IOMMU") Signed-off-by: Alejandro Jimenez Reviewed-by: Vasant Hegde --- hw/i386/amd_iommu.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/i386/amd_iommu.h b/hw/i386/amd_iommu.h index 5672bdef89071..75a01eff468f5 100644 --- a/hw/i386/amd_iommu.h +++ b/hw/i386/amd_iommu.h @@ -196,9 +196,9 @@ #define AMDVI_PAGE_SHIFT_4K 12 #define AMDVI_PAGE_MASK_4K (~((1ULL << AMDVI_PAGE_SHIFT_4K) - 1)) =20 -#define AMDVI_MAX_VA_ADDR (48UL << 5) -#define AMDVI_MAX_PH_ADDR (40UL << 8) -#define AMDVI_MAX_GVA_ADDR (48UL << 15) +#define AMDVI_MAX_GVA_ADDR (48UL << 5) +#define AMDVI_MAX_PH_ADDR (40UL << 8) +#define AMDVI_MAX_VA_ADDR (48UL << 15) =20 /* Completion Wait data size */ #define AMDVI_COMPLETION_DATA_SIZE 8 --=20 2.43.5