/* Check sense key to find if media presents. */
BOOLEAN ScsiDiskIsNoMedia(IN EFI_SCSI_SENSE_DATA *SenseData, IN UINTN SenseCounts)
/* Check sense key to find if media presents. */
BOOLEAN ScsiDiskIsNoMedia(IN EFI_SCSI_SENSE_DATA *SenseData, IN UINTN SenseCounts)
{
  EFI_SCSI_SENSE_DATA  *SensePtr;
  UINTN                Index;
  BOOLEAN              IsNoMedia;
  IsNoMedia = FALSE;
  SensePtr  = SenseData;
  for (Index = 0; Index < SenseCounts; Index++) {
    if ((SensePtr->Sense_Key == EFI_SCSI_SK_NOT_READY) &&
        (SensePtr->Addnl_Sense_Code == EFI_SCSI_ASC_NO_MEDIA))
    {
      IsNoMedia = TRUE;
    }
    SensePtr++;
  }
  return IsNoMedia;
}