From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.nue.novell.com (smtp.nue.novell.com [195.135.221.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 949841A1E2F for ; Thu, 28 Jul 2016 20:26:10 -0700 (PDT) Received: from GaryWorkstation.apac.novell.com (ip-203-192-156-9.asianetcom.net [203.192.156.9]) by smtp.nue.novell.com with ESMTP (NOT encrypted); Fri, 29 Jul 2016 05:26:06 +0200 From: Gary Lin To: edk2-devel@lists.01.org Cc: David Wei , "Lu, ShifeiX A" Date: Fri, 29 Jul 2016 11:25:25 +0800 Message-Id: <20160729032538.17730-7-glin@suse.com> X-Mailer: git-send-email 2.9.2 In-Reply-To: <20160729032538.17730-1-glin@suse.com> References: <20160729032538.17730-1-glin@suse.com> Subject: [PATCH v2 06/19] Vlv2TbltDevicePkg/PlatformInitPei: Remove the unused variables X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Jul 2016 03:26:11 -0000 Fix the following errors from gcc: Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c: In function 'IchRcrbInit': Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c:513:36: error: variable 'PlatformCpuInfo' set but not used [-Werror=unused-but-set-variable] Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c:512:35: error: variable 'LpcRevisionID' set but not used [-Werror=unused-but-set-variable] Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c: In function 'EndOfPeiPpiNotifyCallback': Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c:64:31: error: variable 'MemoryTop' set but not used [-Werror=unused-but-set-variable] v2: Also remove the variable, Hob, in PchInitPeim.c:IchRcrbInit() since no one really uses it. Cc: David Wei Cc: "Lu, ShifeiX A" Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gary Lin --- Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c | 2 -- Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c | 12 ------------ 2 files changed, 14 deletions(-) diff --git a/Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c b/Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c index 31cc88a..9d9c0e5 100644 --- a/Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c +++ b/Vlv2TbltDevicePkg/PlatformInitPei/MemoryCallback.c @@ -52,7 +52,6 @@ EndOfPeiPpiNotifyCallback ( ) { EFI_STATUS Status; - UINT64 MemoryTop; UINT64 LowUncableBase; EFI_PLATFORM_INFO_HOB *PlatformInfo; UINT32 HecBaseHigh; @@ -100,7 +99,6 @@ EndOfPeiPpiNotifyCallback ( LowUncableBase = PlatformInfo->MemData.MemMaxTolm; LowUncableBase &= (0x0FFF00000); - MemoryTop = (0x100000000); if (BootMode != BOOT_ON_S3_RESUME) { // diff --git a/Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c b/Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c index 30f87c1..18ecda4 100644 --- a/Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c +++ b/Vlv2TbltDevicePkg/PlatformInitPei/PchInitPeim.c @@ -500,18 +500,8 @@ IchRcrbInit ( IN SYSTEM_CONFIGURATION *SystemConfiguration ) { - UINT8 LpcRevisionID; - EFI_PLATFORM_CPU_INFO *PlatformCpuInfo; - EFI_PEI_HOB_POINTERS Hob; EFI_BOOT_MODE BootMode; - // - // Get Platform Info HOB - // - Hob.Raw = GetFirstGuidHob (&gEfiPlatformCpuInfoGuid); - ASSERT (Hob.Raw != NULL); - PlatformCpuInfo = GET_GUID_HOB_DATA(Hob.Raw); - (*PeiServices)->GetBootMode(PeiServices, &BootMode); // @@ -530,8 +520,6 @@ IchRcrbInit ( // // Initial RCBA according to the PeiRCBA table // - LpcRevisionID = PchLpcPciCfg8 (R_PCH_LPC_RID_CC); - if ((BootMode == BOOT_ON_S3_RESUME)) { // // We are resuming from S3 -- 2.9.2