From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by mx.groups.io with SMTP id smtpd.web10.13814.1590677296508927530 for ; Thu, 28 May 2020 07:48:16 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@nuviainc-com.20150623.gappssmtp.com header.s=20150623 header.b=GOtWNUls; spf=pass (domain: nuviainc.com, ip: 209.85.221.68, mailfrom: leif@nuviainc.com) Received: by mail-wr1-f68.google.com with SMTP id x14so22836970wrp.2 for ; Thu, 28 May 2020 07:48:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nuviainc-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=bSQp+81yGq3KUe2pYsElKTwNIp1Z/eFJuiJGH/6wJhU=; b=GOtWNUlskiUKADytkHx25uz+MB2RyEHOZ8PcSDxQKrbtM3eVzmuL2H8EWNXeUzt3ju yzfxjWuVCxkRUGXXpSASi7BISmN3ltMPmH1tdAU5lPlVXp40uOpm2vj//wIdgSq48zpK x54gdKCyPznzLeBKNF94oV5d/+96FgnoijR4MeQPOrXLfAfAwn3glSBSb4DeADas/ZoW Au/PUoSVCr4KwB0WxpOHPip0PGP84iqibb9MNROuRmlC/zBIGXqrsh18lI1x7/I8TBu/ qR6Il+83Wf57LLKJD/6RfOkQn0EmvoqvXUHVVeoPJwZkDsKdsX2n8QfFwDI34xGHm9pZ kBVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=bSQp+81yGq3KUe2pYsElKTwNIp1Z/eFJuiJGH/6wJhU=; b=WJiVZ8a65jL/uV3+mCG+Hzi/7UbbHPpo5FFYG3CL5Les/imVkNUA5UhYRuhyf7oaAh DzD9tf5a4ETIJxN8RZQLA10K93SDY0Z05reVuA8d3OceW2+rIfixoxdwlpY4gefMbtb9 xDFRB04rQlGSx2vPj+bVGhhG2X1sVvxwDM7+8s1FvD2296K7tXOhovCr43qx6Nl7FARY v5er/lV5Qa4PAXOhkDh8ZmZTXopSrVAqgG18jYGzRdCUOOSqaIxiZded3KjbifpaIrdi EUa2Tf9oaakKs0NfbXqd8jKHb/Wv/Od4h4U7xFHACGGoC3E+WhXN+qCovFYEUXEo+Hvd nQGw== X-Gm-Message-State: AOAM530aDYfRxpKwnNZ+UlLJCqfrjcwMQUqTsd179DQP2RmZENp0/iju B7o2frwqLP0H2BcnY4QWxk7QHg== X-Google-Smtp-Source: ABdhPJwHX0t/G+M63EX7KPSKq5dTMuKMR1YwM47yaSEUn7H/V6rRsd9SKnBIr5Xoez+ohAgLXJU8wg== X-Received: by 2002:a5d:630f:: with SMTP id i15mr3764427wru.309.1590677294977; Thu, 28 May 2020 07:48:14 -0700 (PDT) Return-Path: Received: from vanye ([2001:470:1f09:12f0:b26e:bfff:fea9:f1b8]) by smtp.gmail.com with ESMTPSA id j4sm4662420wma.7.2020.05.28.07.48.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 May 2020 07:48:14 -0700 (PDT) Date: Thu, 28 May 2020 15:48:12 +0100 From: "Leif Lindholm" To: Pankaj Bansal Cc: Meenakshi Aggarwal , Michael D Kinney , devel@edk2.groups.io, Varun Sethi , Samer El-Haj-Mahmoud , Jon Nettleton , Ard Biesheuvel Subject: Re: [PATCH edk2-platforms v2 3/9] Silicon/NXP: Use edk2 recommended compilation flags Message-ID: <20200528144812.GF1923@vanye> References: <20200527085135.16717-1-pankaj.bansal@oss.nxp.com> <20200527085135.16717-4-pankaj.bansal@oss.nxp.com> MIME-Version: 1.0 In-Reply-To: <20200527085135.16717-4-pankaj.bansal@oss.nxp.com> User-Agent: Mutt/1.10.1 (2018-07-13) Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit On Wed, May 27, 2020 at 14:21:29 +0530, Pankaj Bansal wrote: > From: Pankaj Bansal > > edk2 recommends to use MDEPKG_NDEBUG for release builds and to use > DISABLE_NEW_DEPRECATED_INTERFACES for all new platforms. > > Therefore, enable these flags for NXP platforms as well > > Signed-off-by: Pankaj Bansal Unfortunately, this patch now causes the RELEASE build to fail with /work/git/edk2-platforms/Silicon/NXP/Library/PciHostBridgeLib/PciHostBridgeLib.c:172:9: error: ‘mPciHostBridgeLibAcpiAddressSpaceTypeStr’ defined but not used [-Werror=unused-variable] CHAR16 *mPciHostBridgeLibAcpiAddressSpaceTypeStr[] = { ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This was caused by 5068692c82b7a ("Silicon/NXP: Implement PciHostBridgeLib support") being merged between v1 and v2. So we need another patch that does --- a/Silicon/NXP/Library/PciHostBridgeLib/PciHostBridgeLib.c +++ b/Silicon/NXP/Library/PciHostBridgeLib/PciHostBridgeLib.c @@ -167,11 +167,13 @@ STATIC CONST EFI_PCI_ROOT_BRIDGE_DEVICE_PATH mEfiPciRootBridgeDevicePath[] = { } }; +#ifndef MDEPKG_NDEBUG STATIC GLOBAL_REMOVE_IF_UNREFERENCED CHAR16 *mPciHostBridgeLibAcpiAddressSpaceTypeStr[] = { L"Mem", L"I/O", L"Bus" }; +#endif preceding this one. Best Regards, Leif > --- > > Notes: > V2: > - No change > > Silicon/NXP/NxpQoriqLs.dsc.inc | 7 ++++++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/Silicon/NXP/NxpQoriqLs.dsc.inc b/Silicon/NXP/NxpQoriqLs.dsc.inc > index 12e2b89fac58..ee639d552483 100644 > --- a/Silicon/NXP/NxpQoriqLs.dsc.inc > +++ b/Silicon/NXP/NxpQoriqLs.dsc.inc > @@ -173,7 +173,12 @@ > NULL|ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf > > [BuildOptions] > - RVCT:*_*_ARM_PLATFORM_FLAGS == --cpu cortex-a9 > + GCC:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG > + > + # > + # Disable deprecated APIs. > + # > + GCC:*_*_*_CC_FLAGS = -DDISABLE_NEW_DEPRECATED_INTERFACES > > [BuildOptions.common.EDKII.DXE_RUNTIME_DRIVER] > GCC:*_*_ARM_DLINK_FLAGS = -z common-page-size=0x1000 > -- > 2.17.1 >