From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (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 B24288208D for ; Sun, 18 Dec 2016 23:20:55 -0800 (PST) Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga104.jf.intel.com with ESMTP; 18 Dec 2016 23:20:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,372,1477983600"; d="scan'208";a="44357783" Received: from shwdeopenpsi114.ccr.corp.intel.com ([10.239.157.135]) by fmsmga005.fm.intel.com with ESMTP; 18 Dec 2016 23:20:54 -0800 From: Dandan Bi To: edk2-devel@lists.01.org Cc: Jiewen Yao Date: Mon, 19 Dec 2016 15:20:19 +0800 Message-Id: <1482132023-10416-5-git-send-email-dandan.bi@intel.com> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1482132023-10416-1-git-send-email-dandan.bi@intel.com> References: <1482132023-10416-1-git-send-email-dandan.bi@intel.com> Subject: [patch 4/8] MdeModulePkg/EbcDxe: Make variable name follow rules 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: Mon, 19 Dec 2016 07:20:55 -0000 For variable name, it should contain lower case characters. Cc: Jiewen Yao Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi --- .../Universal/EbcDxe/EbcDebugger/EdbCmdSymbol.c | 8 ++++---- MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCommon.h | 2 +- MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c | 18 +++++++++--------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCmdSymbol.c b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCmdSymbol.c index 9c5707e..ba62c6a 100644 --- a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCmdSymbol.c +++ b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCmdSymbol.c @@ -164,21 +164,21 @@ DebuggerDisplaySymbolAccrodingToAddress ( EDBPrint (L" Address Type Symbol\n"); EDBPrint (L" ================== ==== ========\n"); // EDBPrint (L" 0xFFFFFFFF00000000 ( F) TestMain\n"); EDBPrint ( L" 0x%016lx %s %a\n", - (UINT64)Entry->RVA + Object->BaseAddress, + (UINT64)Entry->Rva + Object->BaseAddress, EdbSymbolTypeToStr (Entry->Type), Entry->Name ); } else { EDBPrint (L" Address Type Symbol\n"); EDBPrint (L" ========== ==== ========\n"); // EDBPrint (L" 0xFFFF0000 ( F) TestMain\n"); EDBPrint ( L" 0x%08x %s %a\n", - Entry->RVA + Object->BaseAddress, + Entry->Rva + Object->BaseAddress, EdbSymbolTypeToStr (Entry->Type), Entry->Name ); } @@ -271,19 +271,19 @@ DebuggerDisplaySymbolAccrodingToName ( } if (sizeof(UINTN) == sizeof(UINT64)) { EDBPrint ( L" 0x%016lx %s %a (%a)\n", - (UINT64)Entry->RVA + Object->BaseAddress, + (UINT64)Entry->Rva + Object->BaseAddress, EdbSymbolTypeToStr (Entry->Type), Entry->Name, Entry->ObjName ); } else { EDBPrint ( L" 0x%08x %s %a (%a)\n", - Entry->RVA + Object->BaseAddress, + Entry->Rva + Object->BaseAddress, EdbSymbolTypeToStr (Entry->Type), Entry->Name, Entry->ObjName ); } diff --git a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCommon.h b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCommon.h index 2a54be1..d452b2b 100644 --- a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCommon.h +++ b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbCommon.h @@ -88,11 +88,11 @@ typedef enum { EfiDebuggerSymbolTypeMax, } EFI_DEBUGGER_SYMBOL_TYPE; typedef struct { CHAR8 Name[EFI_DEBUGGER_SYMBOL_NAME_MAX]; - UINTN RVA; + UINTN Rva; EFI_DEBUGGER_SYMBOL_TYPE Type; CHAR8 ObjName[EFI_DEBUGGER_SYMBOL_NAME_MAX]; CHAR8 *CodBuffer; UINTN CodBufferSize; UINTN FuncOffsetBase; diff --git a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c index e6a677d..4e640ea 100644 --- a/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c +++ b/MdeModulePkg/Universal/EbcDxe/EbcDebugger/EdbSymbol.c @@ -65,11 +65,11 @@ EdbLoadSymbolSingleEntry ( // AsciiStrnCpyS (Entry->Name, sizeof(Entry->Name), Name, sizeof(Entry->Name) - 1); if (ObjName != NULL) { AsciiStrnCpyS (Entry->ObjName, sizeof(Entry->ObjName), ObjName, sizeof(Entry->ObjName) - 1); } - Entry->RVA = Address % EFI_DEBUGGER_DEFAULT_LINK_IMAGEBASE; + Entry->Rva = Address % EFI_DEBUGGER_DEFAULT_LINK_IMAGEBASE; Entry->Type = Type; // // Increase Count // @@ -513,29 +513,29 @@ EbdFindSymbolAddress ( // // Go through each entry // Entry = Object->Entry; for (SubIndex = 0; SubIndex < Object->EntryCount; SubIndex++, Entry++) { - if (Address != Entry->RVA + Object->BaseAddress) { + if (Address != Entry->Rva + Object->BaseAddress) { // // Check for nearest address // - if (Address > Entry->RVA + Object->BaseAddress) { + if (Address > Entry->Rva + Object->BaseAddress) { // // Record it if Current RVA < Address // - if (CandidateLowerAddress < Entry->RVA + Object->BaseAddress) { - CandidateLowerAddress = Entry->RVA + Object->BaseAddress; + if (CandidateLowerAddress < Entry->Rva + Object->BaseAddress) { + CandidateLowerAddress = Entry->Rva + Object->BaseAddress; LowEntry = Entry; LowObject = Object; } } else { // // Record it if Current RVA > Address // - if (CandidateUpperAddress > Entry->RVA + Object->BaseAddress) { - CandidateUpperAddress = Entry->RVA + Object->BaseAddress; + if (CandidateUpperAddress > Entry->Rva + Object->BaseAddress) { + CandidateUpperAddress = Entry->Rva + Object->BaseAddress; UpperEntry = Entry; UpperObject = Object; } } continue; @@ -1710,11 +1710,11 @@ FindSymbolStr ( Entry = Object[ObjectIndex].Entry; for (EntryIndex = 0; EntryIndex < Object[ObjectIndex].EntryCount; EntryIndex++) { // // if Address match, return Name // - if (Address == (Entry[EntryIndex].RVA + Object[ObjectIndex].BaseAddress)) { + if (Address == (Entry[EntryIndex].Rva + Object[ObjectIndex].BaseAddress)) { return Entry[EntryIndex].Name; } } } @@ -2217,11 +2217,11 @@ Symboltoi ( return EFI_NO_MAPPING; } else { // // record Address // - *Address = (Entry[EntryIndex].RVA + Object[ObjectIndex].BaseAddress); + *Address = (Entry[EntryIndex].Rva + Object[ObjectIndex].BaseAddress); } } } } -- 1.9.5.msysgit.1