From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=q7eVqORP; spf=pass (domain: arm.com, ip: 40.107.5.74, mailfrom: sami.mujawar@arm.com) Received: from EUR03-VE1-obe.outbound.protection.outlook.com (EUR03-VE1-obe.outbound.protection.outlook.com [40.107.5.74]) by groups.io with SMTP; Thu, 27 Jun 2019 06:12:31 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0D+XMeWHpc/4h+ZDmrHgHrYruJC7CsTcZVqhXCgxNg0=; b=q7eVqORPkY//LgjFYQjQeFsDoL0+f0GlamJQPxSFQnv2iZZSeYnUvuFpY3xg3PhVR2+7peEbfiUonwUu4Ec44bM9w2BnaYU1St7nQLcn8fbjOau4LdL41cI6+EIiZP3/tRMMNN4qzwvf6hMzprOCN52mUl8IKjtJGZQoLiyABTo= Received: from VI1PR0802CA0026.eurprd08.prod.outlook.com (2603:10a6:800:a9::12) by VE1PR08MB5037.eurprd08.prod.outlook.com (2603:10a6:803:115::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2008.16; Thu, 27 Jun 2019 13:12:27 +0000 Received: from VE1EUR03FT057.eop-EUR03.prod.protection.outlook.com (2a01:111:f400:7e09::207) by VI1PR0802CA0026.outlook.office365.com (2603:10a6:800:a9::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.2008.16 via Frontend Transport; Thu, 27 Jun 2019 13:12:27 +0000 Authentication-Results: spf=temperror (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=temperror action=none header.from=arm.com; Received-SPF: TempError (protection.outlook.com: error in processing during lookup of arm.com: DNS Timeout) Received: from nebula.arm.com (40.67.248.234) by VE1EUR03FT057.mail.protection.outlook.com (10.152.19.123) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.2032.15 via Frontend Transport; Thu, 27 Jun 2019 13:12:25 +0000 Received: from AZ-NEU-EX03.Arm.com (10.251.24.31) 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.1415.2; Thu, 27 Jun 2019 13:12:21 +0000 Received: from E107187.Arm.com (10.1.195.55) by mail.arm.com (10.251.24.31) with Microsoft SMTP Server id 15.1.1415.2 via Frontend Transport; Thu, 27 Jun 2019 13:12:20 +0000 From: "Sami Mujawar" To: CC: Sami Mujawar , , , , , Subject: [PATCH edk2-platforms 1/2] Platform/ARM: Juno: Fix usage of deprecated macros Date: Thu, 27 Jun 2019 14:12:12 +0100 Message-ID: <20190627131213.10972-2-sami.mujawar@arm.com> X-Mailer: git-send-email 2.11.0.windows.3 In-Reply-To: <20190627131213.10972-1-sami.mujawar@arm.com> References: <20190627131213.10972-1-sami.mujawar@arm.com> Return-Path: Sami.Mujawar@arm.com MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:40.67.248.234;IPV:NLI;CTRY:IE;EFV:NLI;SFV:NSPM;SFS:(10009020)(376002)(136003)(39860400002)(346002)(396003)(2980300002)(199004)(189003)(2616005)(6916009)(51416003)(72206003)(86362001)(70206006)(7696005)(478600001)(53936002)(47776003)(305945005)(6666004)(76176011)(44832011)(53416004)(81166006)(50226002)(5660300002)(1076003)(68736007)(54906003)(2906002)(4326008)(2351001)(446003)(356004)(16586007)(77096007)(126002)(426003)(63350400001)(336012)(63370400001)(8936002)(48376002)(486006)(26005)(81156014)(8676002)(316002)(50466002)(186003)(70586007)(36756003)(11346002)(476003);DIR:OUT;SFP:1101;SCL:1;SRVR:VE1PR08MB5037;H:nebula.arm.com;FPR:;SPF:TempError;LANG:en;PTR:InfoDomainNonexistent;A:1;MX:1; X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 765e5081-c977-473f-e1d8-08d6fb011929 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(2017052603328);SRVR:VE1PR08MB5037; X-MS-TrafficTypeDiagnostic: VE1PR08MB5037: NoDisclaimer: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1728; X-Forefront-PRVS: 008184426E X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Message-Info: QdUHxK80Ht2Bdg95q1HBr+oONcaq7XTzJ/pVZ+AsxeYZYBtBqjrf0BDcWcGwI0Ymv1KYst9lKHukPFR8OuBuzD9yjA4r4XUlt6e3swurWG2HckxKY7dO1CnMPZLLtJPQSEhcXYw+eAPymmYp8O7e/U70kAX3kD88Qy4NExwJB/XWzUBF4hLOqpTs+Fk1h1ksKEvLB+bmmWWoUjKsMbC7ufvZXx/ikKaEbSl5T5GuOB6sO7ph2sg+enTH/56FwMU4i25qAS3SAp5OPj1GV7vSOZVONrasJaOLpnK84s372EYTIbDwhyLBmwioMwX3/0exuJvg44UDLW/7pxgIljRVl6/bF74BA/SOIonODK149hBE61GDf665VVmm5AJ+cNCCSUyNqkENefWrurRYRW6BC2w7LuakNS9w1nMout/3cPM= X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Jun 2019 13:12:25.3656 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 765e5081-c977-473f-e1d8-08d6fb011929 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[40.67.248.234];Helo=[nebula.arm.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR08MB5037 Content-Type: text/plain Replaced the use of unsafe/deprecated macros with alternate safe options. Signed-off-by: Sami Mujawar --- Notes: v1: - Replace unsafe/deprecated macros with alternate safe options. [SAMI] Platform/ARM/JunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Platform/ARM/JunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.c b/Platform/ARM/JunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.c index c5967f5b7112fbf794573a6040711a9f1cc14c9f..ea7591d704439cd4216f3e3d7155df2b4d2482b3 100644 --- a/Platform/ARM/JunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.c +++ b/Platform/ARM/JunoPkg/Drivers/ArmJunoDxe/ArmJunoDxe.c @@ -1,6 +1,6 @@ /** @file * -* Copyright (c) 2013-2017, ARM Limited. All rights reserved. +* Copyright (c) 2013-2019, ARM Limited. All rights reserved. * * SPDX-License-Identifier: BSD-2-Clause-Patent * @@ -407,7 +407,6 @@ ArmJunoEntryPoint ( EFI_PHYSICAL_ADDRESS HypBase; CHAR16 *TextDevicePath; UINTN TextDevicePathSize; - VOID *Buffer; UINT32 JunoRevision; EFI_EVENT EndOfDxeEvent; @@ -495,7 +494,7 @@ ArmJunoEntryPoint ( // if (JunoRevision != JUNO_REVISION_R0) { // Enable PCI enumeration - PcdSetBool (PcdPciDisableBusEnumeration, FALSE); + PcdSetBoolS (PcdPciDisableBusEnumeration, FALSE); // // Create an event belonging to the "gEfiEndOfDxeEventGroupGuid" group. @@ -531,8 +530,11 @@ ArmJunoEntryPoint ( TextDevicePath = (CHAR16*)FixedPcdGetPtr (PcdJunoFdtDevicePath); if (TextDevicePath != NULL) { TextDevicePathSize = StrSize (TextDevicePath); - Buffer = PcdSetPtr (PcdFdtDevicePaths, &TextDevicePathSize, TextDevicePath); - Status = (Buffer != NULL) ? EFI_SUCCESS : EFI_BUFFER_TOO_SMALL; + Status = PcdSetPtrS ( + PcdFdtDevicePaths, + &TextDevicePathSize, + TextDevicePath + ); } else { Status = EFI_NOT_FOUND; } -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'