From nobody Thu Dec 26 17:46:21 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+105240+1787277+3901457@groups.io; arc=fail (BodyHash is different from the expected one); dmarc=fail(p=none dis=none) header.from=arm.com Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1684935542619334.6808897496485; Wed, 24 May 2023 06:39:02 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id T6biYY1788612xwVx7jYNoJ5; Wed, 24 May 2023 06:39:02 -0700 X-Received: from EUR02-AM0-obe.outbound.protection.outlook.com (EUR02-AM0-obe.outbound.protection.outlook.com [40.107.247.58]) by mx.groups.io with SMTP id smtpd.web10.9071.1684935540839622631 for ; Wed, 24 May 2023 06:39:01 -0700 X-Received: from AM0PR06CA0087.eurprd06.prod.outlook.com (2603:10a6:208:fa::28) by DBAPR08MB5749.eurprd08.prod.outlook.com (2603:10a6:10:1af::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.29; Wed, 24 May 2023 13:38:56 +0000 X-Received: from AM7EUR03FT024.eop-EUR03.prod.protection.outlook.com (2603:10a6:208:fa:cafe::7d) by AM0PR06CA0087.outlook.office365.com (2603:10a6:208:fa::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6433.15 via Frontend Transport; Wed, 24 May 2023 13:38:56 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+105240+1787277+3901457@groups.io; helo=mail02.groups.io; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; pr=C X-Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM7EUR03FT024.mail.protection.outlook.com (100.127.140.238) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6433.15 via Frontend Transport; Wed, 24 May 2023 13:38:56 +0000 X-Received: ("Tessian outbound 8b05220b4215:v136"); Wed, 24 May 2023 13:38:56 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: ff75ec3936e6539e X-CR-MTA-TID: 64aa7808 X-Received: from 330afea6199a.2 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 8C06E9A3-2AE4-4AA4-988A-9FACE88FBB74.1; Wed, 24 May 2023 13:38:50 +0000 X-Received: from EUR01-HE1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 330afea6199a.2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Wed, 24 May 2023 13:38:50 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ia4J7Tv65mqopVQxgTB+tkEq9rb1BxXt/1IziK9D26aP1wM5bsh5biV4U9rEewuiHkRyzEyb/IjlmHf2FX10ETBFF+5X/vF5CKroPX5juyUYCa0SvKQO4UOfalGUViIM73fQIzGHiAs1x7nSoHSwgvt5zdJplOXvCeIMfJtGmFAQn7MocSdb1K88QInSWg1e1v7LJEQWbQj3efv0Siy4AZSscQRH8ysgVQUM6qeaHHrrJG5a1SGVjwCfT9nFRNe2EueHdMqICVXTMrIebAcmEbPzu/YKr5LRYwopFHJFI0dBxoDzqumSIJaQKC5Tz7S6vzDmcI324qPCX8TatZLCnA== 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=/J2wa26Xp/Fpot5jWcIWu7w5aHVVQnkWuLrRjaXDT4I=; b=Nxt2ahcHjSkQrk/DyJ5Fpj35dOv9JkuP/5iKJ8nm+Bqv7cBntGk1EtjxGHEpONR7QYFBfsUKxhg5i2JtGMB6+UA3cvxSqMdKBGkXSL4ZLV93UcdGH7lT00FzaU+ZtN1Tje4DP8pyGmUqRIkxKayQlBukiaTZeQq1106nJno7Ovln+PCp1Q0QXD4vD7uKldKV/fMhKJLfXwmPoEP10N+x9y6Cck3j2C6Q+FRbyCv2ytLCsxYoV342pOdQRQm80/mKcKFoSHntgYJ8mdH6V0F3cSHA7Em2vutYktpN34L2Fg453yiRDenKp0ly9CSm0s2+8dkzClmwZ7c5aed9wmXRoA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none X-Received: from AS9PR05CA0101.eurprd05.prod.outlook.com (2603:10a6:20b:498::15) by AS4PR08MB7477.eurprd08.prod.outlook.com (2603:10a6:20b:4e4::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6411.27; Wed, 24 May 2023 13:38:46 +0000 X-Received: from AM7EUR03FT059.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:498:cafe::f6) by AS9PR05CA0101.outlook.office365.com (2603:10a6:20b:498::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6433.15 via Frontend Transport; Wed, 24 May 2023 13:38:46 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; pr=C X-Received: from nebula.arm.com (40.67.248.234) by AM7EUR03FT059.mail.protection.outlook.com (100.127.140.215) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6433.14 via Frontend Transport; Wed, 24 May 2023 13:38:46 +0000 X-Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Wed, 24 May 2023 13:38:44 +0000 X-Received: from E114225.Arm.com (10.1.196.36) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.23 via Frontend Transport; Wed, 24 May 2023 13:38:43 +0000 From: "Sami Mujawar" To: CC: Sami Mujawar , , , , , , , , , , Subject: [edk2-devel] [PATCH v2 06/11] ArmPkg: Make variables used for GicInterrupt UINTN Date: Wed, 24 May 2023 14:38:35 +0100 Message-ID: <20230524133840.28612-7-sami.mujawar@arm.com> In-Reply-To: <20230524133840.28612-1-sami.mujawar@arm.com> References: <20230524133840.28612-1-sami.mujawar@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: AM7EUR03FT059:EE_|AS4PR08MB7477:EE_|AM7EUR03FT024:EE_|DBAPR08MB5749:EE_ X-MS-Office365-Filtering-Correlation-Id: d602b634-4540-452d-1d7c-08db5c5c38e7 x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: nmhqEQIyI6zvyhFnzwuhewUU7mnnlgG4sj3AtphHeFneiRC1pSyONol1H2V3g92/GCtaiQbV9uO4PDDwgb7i8eSsnlNmVa/fosEFt/5O5p5ocZ4wb7Jwsdi5dnGhHlL5tpF83lW8F4fPIQq8YvQBkRGhGW4R9n4LWrNKzXPTEWXC0qfUjPqmyBgNVhv4y6nqXl/90a8+i1O3mKcasfjU51dAt1S/NP+6XgAuwl3gMNbSNFXjL+4iOdGR3KMjccgJ3N6DiamNkXYuthXqJwlaKYOVEibtaIKZfFSlCA05NUCSqfuRT0DilggEXwgLLxjPhRq6DJfU707PMNjYm3xYGmylsdnYYKRC+uv8BcVGCQ9PE23tckrXei/DNcDHROOhrow5R1L9TKtbTS/qSSF4uWAoqTEwBF6Zja3QMuLmXZGmk3gdy81GSyzXA/2dV0c+6KxaMy5hNLJj+SkMdIR7BhVOFGMVgGeXcZyTyaE7ySfp2I5orlg8mObx3EZsBMwEg7G8zgZWoynEkR+RuqHySwv3KTiDem+q6sxR1gDNjFzXIzjbn+VW25tp2PnUraeRuw72IV9PvMFc2ZKVruk+48nwRf9tkp4p7iuID+bKwxre2eTV8pkG2FLP/J2SYI+UXk7gSaDJxRCsNTpcwyoUFsx+QI/NXQpxbWKi8lzaNq65cmSIUABwzQe1GBwgo3FdYBQ2iUpgqWAhRvqhJbSFf615Fb3PvCSG23NMs21MlaQpBlYd6Qw3MZc8V3fqxYLg X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:nebula.arm.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230028)(4636009)(136003)(396003)(346002)(376002)(39860400002)(451199021)(36840700001)(46966006)(54906003)(82310400005)(7696005)(41300700001)(478600001)(19627235002)(316002)(4326008)(6916009)(70586007)(6666004)(70206006)(86362001)(5660300002)(8676002)(8936002)(44832011)(2906002)(1076003)(81166007)(26005)(356005)(82740400003)(186003)(426003)(83380400001)(336012)(40480700001)(2616005)(36756003)(36860700001)(47076005)(36900700001);DIR:OUT;SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS4PR08MB7477 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM7EUR03FT024.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 86eec2a5-6c79-4a16-582c-08db5c5c332d X-Microsoft-Antispam-Message-Info: /N41wz/pXRDiqIAg1vGimByXqYxCrxm/K13pOIz4KeKvlJsONe4ZdL7E6+hUrBMKqmvkimL8DzgzTF7Dz+WaCuY7RMcosqlDcWWgZWjnQPBkBhf3AyAJO6tsVjYde4rycO/Ueeg2U+NatwMintpkhQz4gXRC3Qi+jWBVossAFcRQY9oC5ASAthlQ8qZLwjv+wMUfWoXpT3gvp2MI9/hObipm6Tgk9VB1nLGJreRv5fxLxvW0TXc5rS4VAhBnBaQILAeVs1GmdVgcaESVQLUz1QoNpPvKUkiEnmlE5m14o4we0Pc5l7m6xwQzWp0fcFilnQra3QJ41VnZKPABJd28pvZyEOJoSVDLA0F5yDxsh8LMjVuPkWK+8LnVBKJwdTtbA5BlF9XnUEomLgXfCQfC5IuxBc/HqA635CgDb28LpgZnF336IrIwiqYEYYOnzJNt1R9cApc7h3y0QuepoKfv9JUYgmR0F6trPlCW6OrW5ryZphkBk4LbrtAjO/H0bZYaGMCeex5G1Ir7CIoSodtcjgYyVsewRX4C/zNaAZrHggh68w+/fgUXXAWlebb3JzEuYqenAwPIfFKEjHxxQoTprMi+gDyShqz3iEw0VdMOaN8xwS5oCM9xg5pDr/fIku612oyoZicyT3ds77rfJdy4+bOLCPG4ARQod0+LWp6fnf1EBXgzzPzk05HFBmfUPWj1a2zdpKjpghV2O94YZUyZ+kng9AeexMg3rguaPk4tuHrTCw0IG5yRBVT8527AXg5r X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 May 2023 13:38:56.4005 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: d602b634-4540-452d-1d7c-08db5c5c38e7 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[63.35.35.123];Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM7EUR03FT024.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAPR08MB5749 Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,sami.mujawar@arm.com X-Gm-Message-State: VVbL1ZVS0aU6y9C5iDmaFLAyx1787277AA= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1684935542; bh=Qo+mdW4UHx+GbBn5vN9ItweZ6H0o2KvYO6q+diyP1Bo=; h=CC:Content-Type:Date:From:Reply-To:Subject:To; b=RH5qL4mU1d1CiLLbsoroEZSkNZV+04+vIJtT9GdOgiL+DTXiv3t72U0AE90QuDHlaDh wOMuLHRfyAPk2QT59CadQrhOHx+bjx2r63dHgDdv8o2DTYiuYY7cfYeQBDMQiRxdYDnLT ONR1GSJUXkm4t7TKnlZzSlxXoPHd4CONXDU= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1684935544682100009 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Although the maximum interrupt ID on GicV2 is 10bit and for GicV3/4 is 24bit, and that the IAR and EOIR registers of the Gic CPU interface are 32 bit; the typedef HARDWARE_INTERRUPT_SOURCE is defined as UINTN in EmbeddedPkg\Include\Protocol\HardwareInterrupt.h Therefore, use UINTN for Gic Interrupt variables and use appropriate typecasts wherever needed. Signed-off-by: Sami Mujawar --- Notes: v2: - Updated GicV3IrqInterruptHandler () to change [Sami] GicInterrupt to UINTN and added typecast before printing GicInterrupt in both GicV[2|3]IrqInterruptHandler (). ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c | 8 ++++---- ArmPkg/Drivers/ArmGic/GicV3/ArmGicV3Dxe.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c b/ArmPkg/Drivers/Arm= Gic/GicV2/ArmGicV2Dxe.c index a1670021c30f05707d7c37a789fdbacc4ffa9140..cd371cab2a0159b54d8e6f0f5d3= 930e1276cbf7e 100644 --- a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c +++ b/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c @@ -162,7 +162,7 @@ GicV2IrqInterruptHandler ( IN EFI_SYSTEM_CONTEXT SystemContext ) { - UINT32 GicInterrupt; + UINTN GicInterrupt; HARDWARE_INTERRUPT_HANDLER InterruptHandler; =20 GicInterrupt =3D ArmGicV2AcknowledgeInterrupt (mGicInterruptInterfaceBas= e); @@ -179,7 +179,7 @@ GicV2IrqInterruptHandler ( // Call the registered interrupt handler. InterruptHandler (GicInterrupt, SystemContext); } else { - DEBUG ((DEBUG_ERROR, "Spurious GIC interrupt: 0x%x\n", GicInterrupt)); + DEBUG ((DEBUG_ERROR, "Spurious GIC interrupt: 0x%x\n", (UINT32)GicInte= rrupt)); GicV2EndOfInterrupt (&gHardwareInterruptV2Protocol, GicInterrupt); } } @@ -349,8 +349,8 @@ GicV2ExitBootServicesEvent ( IN VOID *Context ) { - UINTN Index; - UINT32 GicInterrupt; + UINTN Index; + UINTN GicInterrupt; =20 // Disable all the interrupts for (Index =3D 0; Index < mGicNumInterrupts; Index++) { diff --git a/ArmPkg/Drivers/ArmGic/GicV3/ArmGicV3Dxe.c b/ArmPkg/Drivers/Arm= Gic/GicV3/ArmGicV3Dxe.c index 719701a67e756c2d2aeae8fc23d50b519a1997aa..41aec70481e05594628fe01cf9a= d5626e4ddbf9b 100644 --- a/ArmPkg/Drivers/ArmGic/GicV3/ArmGicV3Dxe.c +++ b/ArmPkg/Drivers/ArmGic/GicV3/ArmGicV3Dxe.c @@ -156,7 +156,7 @@ GicV3IrqInterruptHandler ( IN EFI_SYSTEM_CONTEXT SystemContext ) { - UINT32 GicInterrupt; + UINTN GicInterrupt; HARDWARE_INTERRUPT_HANDLER InterruptHandler; =20 GicInterrupt =3D ArmGicV3AcknowledgeInterrupt (); @@ -173,7 +173,7 @@ GicV3IrqInterruptHandler ( // Call the registered interrupt handler. InterruptHandler (GicInterrupt, SystemContext); } else { - DEBUG ((DEBUG_ERROR, "Spurious GIC interrupt: 0x%x\n", GicInterrupt)); + DEBUG ((DEBUG_ERROR, "Spurious GIC interrupt: 0x%x\n", (UINT32)GicInte= rrupt)); GicV3EndOfInterrupt (&gHardwareInterruptV3Protocol, GicInterrupt); } } --=20 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#105240): https://edk2.groups.io/g/devel/message/105240 Mute This Topic: https://groups.io/mt/99108670/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-