]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Nt32Pkg/CpuRuntimeDxe/CpuIo.c
We enabled X64 native version NT32, and made it works on Windows 7 X64 OS.
[mirror_edk2.git] / Nt32Pkg / CpuRuntimeDxe / CpuIo.c
index 7f171e6094f4ef9d78c5b980b3500ffb5adab656..9c3478f0a384a7cdf5fc1c1febdcb2054877204a 100644 (file)
@@ -1,6 +1,6 @@
 /**@file\r
 \r
-Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials                          \r
 are licensed and made available under the terms and conditions of the BSD License         \r
 which accompanies this distribution.  The full text of the license may be found at        \r
@@ -326,11 +326,11 @@ Returns:
   }\r
 \r
   Width = (EFI_CPU_IO_PROTOCOL_WIDTH)(Width & 0x03);\r
-  if (Address - 1 + (1 << Width) * Count > Limit) {\r
+  if (Address - 1 + ((UINTN)1 << Width) * Count > Limit) {\r
     return EFI_UNSUPPORTED;\r
   }\r
 \r
-  AlignMask = (1 << Width) - 1;\r
+  AlignMask = ((UINTN)1 << Width) - 1;\r
   if ((UINTN) Buffer & AlignMask) {\r
     return EFI_UNSUPPORTED;\r
   }\r