From: AJFISH Date: Fri, 15 Jan 2010 18:33:26 +0000 (+0000) Subject: Minor update to move array into function to dead strip better on release builds X-Git-Tag: edk2-stable201903~16546 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=79b9790fb89909640536c90f7e30acd1737d705f Minor update to move array into function to dead strip better on release builds git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9778 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/ArmPkg/Drivers/CpuDxe/Exception.c b/ArmPkg/Drivers/CpuDxe/Exception.c index bc67fc44ce..f0b682d18d 100644 --- a/ArmPkg/Drivers/CpuDxe/Exception.c +++ b/ArmPkg/Drivers/CpuDxe/Exception.c @@ -164,20 +164,6 @@ typedef struct { CHAR8 Char; } CPSR_CHAR; -CPSR_CHAR gCpsrChar[] = { - { 31, 'n' }, - { 30, 'z' }, - { 29, 'c' }, - { 28, 'v' }, - { 27, 'q' }, - - { 8, 'a' }, - { 7, 'i' }, - { 6, 'f' }, - { 5, 't' }, - { 0, '?' } -}; - VOID CpsrString ( @@ -188,10 +174,23 @@ CpsrString ( UINTN Index; CHAR8 *Str = ReturnStr; CHAR8 *ModeStr; + CPSR_CHAR CpsrChar[] = { + { 31, 'n' }, + { 30, 'z' }, + { 29, 'c' }, + { 28, 'v' }, + + { 9, 'e' }, + { 8, 'a' }, + { 7, 'i' }, + { 6, 'f' }, + { 5, 't' }, + { 0, '?' } + }; - for (Index = 0; gCpsrChar[Index].Bit != 0; Index++, Str++) { - *Str = gCpsrChar[Index].Char; - if ((Cpsr & (1 << gCpsrChar[Index].Bit)) != 0) { + for (Index = 0; CpsrChar[Index].Bit != 0; Index++, Str++) { + *Str = CpsrChar[Index].Char; + if ((Cpsr & (1 << CpsrChar[Index].Bit)) != 0) { // Concert to upper case if bit is set *Str &= ~0x20; }