Revision: 14420
http://sourceforge.net/p/edk2/code/14420
Author: jljusten
Date: 2013-06-14 07:41:05 +0000 (Fri, 14 Jun 2013)
Log Message:
-----------
OvmfPkg/VirtioNetDxe: Fix build errors on VS2012 (IA32 & X64)
These changes were needed in addition to the silence.patch
that Laszlo posted on May 28.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jordan Justen <[email protected]>
Signed-off-by: Laszlo Ersek <[email protected]>
Modified Paths:
--------------
trunk/edk2/OvmfPkg/VirtioNetDxe/SnpGetStatus.c
trunk/edk2/OvmfPkg/VirtioNetDxe/SnpReceive.c
trunk/edk2/OvmfPkg/VirtioNetDxe/SnpTransmit.c
Modified: trunk/edk2/OvmfPkg/VirtioNetDxe/SnpGetStatus.c
===================================================================
--- trunk/edk2/OvmfPkg/VirtioNetDxe/SnpGetStatus.c 2013-06-14 07:40:59 UTC
(rev 14419)
+++ trunk/edk2/OvmfPkg/VirtioNetDxe/SnpGetStatus.c 2013-06-14 07:41:05 UTC
(rev 14420)
@@ -4,7 +4,7 @@
any.
Copyright (C) 2013, Red Hat, Inc.
- Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available
under the terms and conditions of the BSD License which accompanies this
@@ -136,12 +136,12 @@
UsedElemIdx = Dev->TxLastUsed++ % Dev->TxRing.QueueSize;
DescIdx = Dev->TxRing.Used.UsedElem[UsedElemIdx].Id;
- ASSERT (DescIdx < 2 * Dev->TxMaxPending - 1);
+ ASSERT (DescIdx < (UINT32) (2 * Dev->TxMaxPending - 1));
//
// report buffer address to caller that has been enqueued by caller
//
- *TxBuf = (VOID *) Dev->TxRing.Desc[DescIdx + 1].Addr;
+ *TxBuf = (VOID *)(UINTN) Dev->TxRing.Desc[DescIdx + 1].Addr;
//
// now this descriptor can be used again to enqueue a transmit buffer
Modified: trunk/edk2/OvmfPkg/VirtioNetDxe/SnpReceive.c
===================================================================
--- trunk/edk2/OvmfPkg/VirtioNetDxe/SnpReceive.c 2013-06-14 07:40:59 UTC
(rev 14419)
+++ trunk/edk2/OvmfPkg/VirtioNetDxe/SnpReceive.c 2013-06-14 07:41:05 UTC
(rev 14420)
@@ -3,7 +3,7 @@
Implementation of the SNP.Receive() function and its private helpers if any.
Copyright (C) 2013, Red Hat, Inc.
- Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available
under the terms and conditions of the BSD License which accompanies this
@@ -142,7 +142,7 @@
*HeaderSize = Dev->Snm.MediaHeaderSize;
}
- RxPtr = (UINT8 *)Dev->RxRing.Desc[DescIdx + 1].Addr;
+ RxPtr = (UINT8 *)(UINTN) Dev->RxRing.Desc[DescIdx + 1].Addr;
CopyMem (Buffer, RxPtr, RxLen);
if (DestAddr != NULL) {
Modified: trunk/edk2/OvmfPkg/VirtioNetDxe/SnpTransmit.c
===================================================================
--- trunk/edk2/OvmfPkg/VirtioNetDxe/SnpTransmit.c 2013-06-14 07:40:59 UTC
(rev 14419)
+++ trunk/edk2/OvmfPkg/VirtioNetDxe/SnpTransmit.c 2013-06-14 07:41:05 UTC
(rev 14420)
@@ -3,7 +3,7 @@
Implementation of the SNP.Transmit() function and its private helpers if any.
Copyright (C) 2013, Red Hat, Inc.
- Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available
under the terms and conditions of the BSD License which accompanies this
@@ -140,7 +140,7 @@
*Ptr++ = (UINT8) (*Protocol >> 8);
*Ptr++ = (UINT8) *Protocol;
- ASSERT (Ptr - (UINT8 *) Buffer == Dev->Snm.MediaHeaderSize);
+ ASSERT ((UINTN) (Ptr - (UINT8 *) Buffer) == Dev->Snm.MediaHeaderSize);
}
//
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits