/* Map virtual memory address for DMA. This field can be set to zero if there is no mapping service. */
UINTN MapIt(IN NIC_DATA *Nic, IN UINT64 MemAddr, IN UINT32 Size, IN UINT32 Direction, OUT UINT64 MappedAddr)
/* Map virtual memory address for DMA. This field can be set to zero if there is no mapping service. */
UINTN MapIt(IN NIC_DATA *Nic, IN UINT64 MemAddr, IN UINT32 Size, IN UINT32 Direction, OUT UINT64 MappedAddr)
{
  UINT64  *PhyAddr;
  PhyAddr = (UINT64 *)(UINTN)MappedAddr;
  if (Nic->PxeStart.Map_Mem == 0) {
    *PhyAddr = MemAddr;
  } else {
    ((void (*)(UINT64, UINT64, UINT32, UINT32, UINT64))(UINTN) Nic->PxeStart.Map_Mem)(
  Nic->PxeStart.Unique_ID,
  MemAddr,
  Size,
  Direction,
  MappedAddr
  );
  }
  return PXE_STATCODE_SUCCESS;
}