From 35f910f08b58e978bc9251872635075d6f422e48 Mon Sep 17 00:00:00 2001 From: Randy Pawell Date: Thu, 4 Dec 2014 00:32:24 +0000 Subject: MdeModulePkg: Source fixes and cleanup for ARMGCC compiles - Fix EFI_IPv4_ADDRESS usages to use a macro to copy the structure instead of direct assignment, to avoid runtime alignment errors. - Fix a EFI_INPUT_KEY usage in TerminalDxe to use CopyMem() to copy the structure instead of direct assignment, to avoid runtime alignment error. - Delete excess local variables that are initialized but otherwise unused. - CompilerIntrinsicsLib library now imported for AARCH64, as well as ARM. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Randy Pawell Reviewed-by: Olivier Martin Reviewed-by: Feng Tian git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16471 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'MdeModulePkg/Library/DxeIpIoLib') diff --git a/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c b/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c index 837a1dba4d..cc93c2b89c 100644 --- a/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c +++ b/MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.c @@ -1,6 +1,7 @@ /** @file IpIo Library. +(C) Copyright 2014 Hewlett-Packard Development Company, L.P.
Copyright (c) 2005 - 2009, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License @@ -703,7 +704,7 @@ IpIoCreateSndEntry ( Ip4TxData = &TxData->Ip4TxData; - CopyMem (&Ip4TxData->DestinationAddress, Dest, sizeof (EFI_IPv4_ADDRESS)); + IP4_COPY_ADDRESS (&Ip4TxData->DestinationAddress, Dest); Ip4TxData->OverrideData = &OverrideData->Ip4OverrideData; Ip4TxData->OptionsLength = 0; @@ -1765,8 +1766,8 @@ IpIoConfigIp ( NULL ); - ((EFI_IP4_CONFIG_DATA*) IpConfigData)->StationAddress = Ip4ModeData.ConfigData.StationAddress; - ((EFI_IP4_CONFIG_DATA*) IpConfigData)->SubnetMask = Ip4ModeData.ConfigData.SubnetMask; + IP4_COPY_ADDRESS (&((EFI_IP4_CONFIG_DATA*) IpConfigData)->StationAddress, &Ip4ModeData.ConfigData.StationAddress); + IP4_COPY_ADDRESS (&((EFI_IP4_CONFIG_DATA*) IpConfigData)->SubnetMask, &Ip4ModeData.ConfigData.SubnetMask); } CopyMem ( -- cgit v1.2.3