/* This function returns the current TPL. There is no EFI service to directly retrieve the current TPL. Instead, the RaiseTPL() function is used to raise the TPL to TPL_HIGH_LEVEL. This will return the current TPL. The TPL level can then immediately be restored back to the current TPL level with a call to RestoreTPL(). */
EFI_TPL EFIAPI EfiGetCurrentTpl(VOID)
/* This function returns the current TPL. There is no EFI service to directly retrieve the current TPL. Instead, the RaiseTPL() function is used to raise the TPL to TPL_HIGH_LEVEL. This will return the current TPL. The TPL level can then immediately be restored back to the current TPL level with a call to RestoreTPL(). */
EFI_TPL EFIAPI EfiGetCurrentTpl(VOID)
{
  EFI_TPL  Tpl;
  Tpl = gBS->RaiseTPL (TPL_HIGH_LEVEL);
  gBS->RestoreTPL (Tpl);
  return Tpl;
}