/* Converts a text device path node to BMC device path structure. */
EFI_DEVICE_PATH_PROTOCOL* DevPathFromTextBmc(IN CHAR16 *TextDeviceNode)
/* Converts a text device path node to BMC device path structure. */
EFI_DEVICE_PATH_PROTOCOL* DevPathFromTextBmc(IN CHAR16 *TextDeviceNode)
{
  CHAR16           *InterfaceTypeStr;
  CHAR16           *BaseAddressStr;
  BMC_DEVICE_PATH  *BmcDp;
  InterfaceTypeStr = GetNextParamStr (&TextDeviceNode);
  BaseAddressStr   = GetNextParamStr (&TextDeviceNode);
  BmcDp            = (BMC_DEVICE_PATH *)CreateDeviceNode (
                                          HARDWARE_DEVICE_PATH,
                                          HW_BMC_DP,
                                          (UINT16)sizeof (BMC_DEVICE_PATH)
                                          );
  BmcDp->InterfaceType = (UINT8)Strtoi (InterfaceTypeStr);
  WriteUnaligned64 (
    (UINT64 *)(&BmcDp->BaseAddress),
    StrHexToUint64 (BaseAddressStr)
    );
  return (EFI_DEVICE_PATH_PROTOCOL *)BmcDp;
}