/* Similar to GetVariable, the first call can be made with a 0 size and it will return the size of the buffer required to hold the entire table. */
EFI_STATUS EFIAPI DumpVariablePolicy(OUT UINT8 *Policy, IN OUT UINT32 *Size)
/* Similar to GetVariable, the first call can be made with a 0 size and it will return the size of the buffer required to hold the entire table. */
EFI_STATUS EFIAPI DumpVariablePolicy(OUT UINT8 *Policy, IN OUT UINT32 *Size)
{
  if (!IsVariablePolicyLibInitialized ()) {
    return EFI_NOT_READY;
  }
  if ((Size == NULL) || ((*Size > 0) && (Policy == NULL))) {
    return EFI_INVALID_PARAMETER;
  }
  if (*Size < mCurrentTableUsage) {
    *Size = mCurrentTableUsage;
    return EFI_BUFFER_TOO_SMALL;
  }
  CopyMem (Policy, mPolicyTable, mCurrentTableUsage);
  *Size = mCurrentTableUsage;
  return EFI_SUCCESS;
}