/* Compute the ASL NameString/path size from NameString information (Root, ParentPrefix, SegCount). */
UINT32 EFIAPI AslComputeNameStringSize(IN UINT32 Root, IN UINT32 ParentPrefix, IN UINT32 SegCount)
/* Compute the ASL NameString/path size from NameString information (Root, ParentPrefix, SegCount). */
UINT32 EFIAPI AslComputeNameStringSize(IN UINT32 Root, IN UINT32 ParentPrefix, IN UINT32 SegCount)
{
  UINT32  TotalSize;
  if (!AmlIsNameString (Root, ParentPrefix, SegCount)) {
    ASSERT (0);
    return 0;
  }
  TotalSize = Root + ParentPrefix;
  TotalSize += (SegCount * AML_NAME_SEG_SIZE);
  TotalSize += (SegCount > 1) ? (SegCount - 1) : 0;
  TotalSize += 1;
  return TotalSize;
}