EFI_PHYSICAL_ADDRESS DmaMemoryTop;\r
BOOLEAN NeedRemap;\r
\r
- DEBUG ((DEBUG_VERBOSE, "IoMmuMap: ==> 0x%08x - 0x%08x (%x)\n", HostAddress, NumberOfBytes, Operation));\r
-\r
- if (HostAddress == NULL || NumberOfBytes == NULL || DeviceAddress == NULL ||\r
+ if (NumberOfBytes == NULL || DeviceAddress == NULL ||\r
Mapping == NULL) {\r
DEBUG ((DEBUG_ERROR, "IoMmuMap: %r\n", EFI_INVALID_PARAMETER));\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
+ DEBUG ((DEBUG_VERBOSE, "IoMmuMap: ==> 0x%08x - 0x%08x (%x)\n", HostAddress, *NumberOfBytes, Operation));\r
+\r
//\r
// Make sure that Operation is valid\r
//\r
if (NeedRemap) {\r
//\r
// Common Buffer operations can not be remapped. If the common buffer\r
- // if above 4GB, then it is not possible to generate a mapping, so return\r
+ // is above 4GB, then it is not possible to generate a mapping, so return\r
// an error.\r
//\r
DEBUG ((DEBUG_ERROR, "IoMmuMap: %r\n", EFI_UNSUPPORTED));\r