From e72a3b3ea82c6520fc195ebc36e198a9ca9ca457 Mon Sep 17 00:00:00 2001 From: qhuang8 Date: Mon, 17 Nov 2008 14:22:23 +0000 Subject: Update SCSI modules to use new macros defined in UefiLib. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6564 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.c | 2 +- MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.h | 4 ---- MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDisk.c | 12 ++++++------ 3 files changed, 7 insertions(+), 11 deletions(-) (limited to 'MdeModulePkg/Bus') diff --git a/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.c b/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.c index 9833f035be..9b9a5d5e14 100644 --- a/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.c +++ b/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.c @@ -1105,7 +1105,7 @@ DiscoverScsiDevice ( Status = ScsiInquiryCommand ( &ScsiIoDevice->ScsiIo, - EFI_SCSI_STALL_SECONDS (1), + EFI_TIMER_PERIOD_SECONDS (1), (VOID *) &SenseData, &SenseDataLength, &HostAdapterStatus, diff --git a/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.h b/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.h index 2775b3fe73..895d48388b 100644 --- a/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.h +++ b/MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBus.h @@ -35,10 +35,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include #include -// -// 1000 * 1000 * 10 -// -#define ONE_SECOND_TIMER 10000000 #define SCSI_IO_DEV_SIGNATURE EFI_SIGNATURE_32 ('s', 'c', 'i', 'o') diff --git a/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDisk.c b/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDisk.c index 9451932cfc..d2a751a8ed 100644 --- a/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDisk.c +++ b/MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDisk.c @@ -876,7 +876,7 @@ ScsiDiskInquiryDevice ( Status = ScsiInquiryCommand ( ScsiDiskDevice->ScsiIo, - EFI_SCSI_STALL_SECONDS (1), + EFI_TIMER_PERIOD_SECONDS (1), NULL, &SenseDataLength, &HostAdapterStatus, @@ -1002,7 +1002,7 @@ ScsiDiskTestUnitReady ( // Status = ScsiTestUnitReadyCommand ( ScsiDiskDevice->ScsiIo, - EFI_SCSI_STALL_SECONDS (1), + EFI_TIMER_PERIOD_SECONDS (1), NULL, &SenseDataLength, &HostAdapterStatus, @@ -1192,7 +1192,7 @@ ScsiDiskReadCapacity ( // CommandStatus = ScsiReadCapacityCommand ( ScsiDiskDevice->ScsiIo, - EFI_SCSI_STALL_SECONDS (1), + EFI_TIMER_PERIOD_SECONDS (1), NULL, &SenseDataLength, &HostAdapterStatus, @@ -1409,7 +1409,7 @@ ScsiDiskRequestSenseKeys ( for (SenseReq = TRUE; SenseReq;) { Status = ScsiRequestSenseCommand ( ScsiDiskDevice->ScsiIo, - EFI_SCSI_STALL_SECONDS (2), + EFI_TIMER_PERIOD_SECONDS (2), PtrSenseData, &SenseDataLength, &HostAdapterStatus, @@ -1567,7 +1567,7 @@ ScsiDiskReadSectors ( } ByteCount = SectorCount * BlockSize; - Timeout = EFI_SCSI_STALL_SECONDS (2); + Timeout = EFI_TIMER_PERIOD_SECONDS (2); MaxRetry = 2; for (Index = 0; Index < MaxRetry; Index++) { @@ -1671,7 +1671,7 @@ ScsiDiskWriteSectors ( } ByteCount = SectorCount * BlockSize; - Timeout = EFI_SCSI_STALL_SECONDS (2); + Timeout = EFI_TIMER_PERIOD_SECONDS (2); MaxRetry = 2; for (Index = 0; Index < MaxRetry; Index++) { Status = ScsiDiskWrite10 ( -- cgit v1.2.3