/* Convert the mac address into a hexadecimal encoded "-" separated string. */
VOID IScsiMacAddrToStr(IN EFI_MAC_ADDRESS *Mac, IN UINT32 Len, IN UINT16 VlanId, OUT CHAR16 *Str)
/* Convert the mac address into a hexadecimal encoded "-" separated string. */
VOID IScsiMacAddrToStr(IN EFI_MAC_ADDRESS *Mac, IN UINT32 Len, IN UINT16 VlanId, OUT CHAR16 *Str)
{
  UINT32  Index;
  CHAR16  *String;
  for (Index = 0; Index < Len; Index++) {
    Str[3 * Index]     = (CHAR16)IScsiHexString[(Mac->Addr[Index] >> 4) & 0x0F];
    Str[3 * Index + 1] = (CHAR16)IScsiHexString[Mac->Addr[Index] & 0x0F];
    Str[3 * Index + 2] = L':';
  }
  String = &Str[3 * Index - 1];
  if (VlanId != 0) {
    String += UnicodeSPrint (String, 6 * sizeof (CHAR16), L"\\%04x", (UINTN)VlanId);
  }
  *String = L'\0';
}