mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 18:15:11 +00:00
[ISAPNP] Reduce software delay
This commit is contained in:
parent
8ed43b6907
commit
d6dca83baf
1 changed files with 7 additions and 20 deletions
|
@ -292,14 +292,6 @@ ReadMemoryLimit32(
|
||||||
return ReadDoubleWord(ReadDataPort, ISAPNP_MEMLIMIT32(Index));
|
return ReadDoubleWord(ReadDataPort, ISAPNP_MEMLIMIT32(Index));
|
||||||
}
|
}
|
||||||
|
|
||||||
static
|
|
||||||
inline
|
|
||||||
VOID
|
|
||||||
HwDelay(VOID)
|
|
||||||
{
|
|
||||||
KeStallExecutionProcessor(1000);
|
|
||||||
}
|
|
||||||
|
|
||||||
static
|
static
|
||||||
inline
|
inline
|
||||||
UCHAR
|
UCHAR
|
||||||
|
@ -320,7 +312,6 @@ SendKey(VOID)
|
||||||
{
|
{
|
||||||
UCHAR i, Lfsr;
|
UCHAR i, Lfsr;
|
||||||
|
|
||||||
HwDelay();
|
|
||||||
WriteAddress(0x00);
|
WriteAddress(0x00);
|
||||||
WriteAddress(0x00);
|
WriteAddress(0x00);
|
||||||
|
|
||||||
|
@ -347,7 +338,7 @@ PeekByte(
|
||||||
if (ReadStatus(ReadDataPort) & 0x01)
|
if (ReadStatus(ReadDataPort) & 0x01)
|
||||||
return ReadResourceData(ReadDataPort);
|
return ReadResourceData(ReadDataPort);
|
||||||
|
|
||||||
HwDelay();
|
KeStallExecutionProcessor(1000);
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0xFF;
|
return 0xFF;
|
||||||
|
@ -1196,20 +1187,19 @@ TryIsolate(
|
||||||
SendKey();
|
SendKey();
|
||||||
|
|
||||||
ResetCsn();
|
ResetCsn();
|
||||||
HwDelay();
|
KeStallExecutionProcessor(2000);
|
||||||
HwDelay();
|
|
||||||
|
|
||||||
WaitForKey();
|
WaitForKey();
|
||||||
SendKey();
|
SendKey();
|
||||||
Wake(0x00);
|
Wake(0x00);
|
||||||
|
KeStallExecutionProcessor(1000);
|
||||||
|
|
||||||
SetReadDataPort(ReadDataPort);
|
SetReadDataPort(ReadDataPort);
|
||||||
HwDelay();
|
|
||||||
|
|
||||||
while (TRUE)
|
while (TRUE)
|
||||||
{
|
{
|
||||||
EnterIsolationState();
|
EnterIsolationState();
|
||||||
HwDelay();
|
KeStallExecutionProcessor(1000);
|
||||||
|
|
||||||
RtlZeroMemory(&Identifier, sizeof(Identifier));
|
RtlZeroMemory(&Identifier, sizeof(Identifier));
|
||||||
|
|
||||||
|
@ -1220,9 +1210,9 @@ TryIsolate(
|
||||||
for (j = 0; j < 8; j++)
|
for (j = 0; j < 8; j++)
|
||||||
{
|
{
|
||||||
Data = ReadData(ReadDataPort);
|
Data = ReadData(ReadDataPort);
|
||||||
HwDelay();
|
KeStallExecutionProcessor(250);
|
||||||
Data = ((Data << 8) | ReadData(ReadDataPort));
|
Data = ((Data << 8) | ReadData(ReadDataPort));
|
||||||
HwDelay();
|
KeStallExecutionProcessor(250);
|
||||||
Byte >>= 1;
|
Byte >>= 1;
|
||||||
|
|
||||||
if (Data != 0xFFFF)
|
if (Data != 0xFFFF)
|
||||||
|
@ -1269,10 +1259,9 @@ TryIsolate(
|
||||||
Csn++;
|
Csn++;
|
||||||
|
|
||||||
WriteCsn(Csn);
|
WriteCsn(Csn);
|
||||||
HwDelay();
|
KeStallExecutionProcessor(1000);
|
||||||
|
|
||||||
Wake(0x00);
|
Wake(0x00);
|
||||||
HwDelay();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
WaitForKey();
|
WaitForKey();
|
||||||
|
@ -1300,8 +1289,6 @@ DeviceActivation(
|
||||||
else
|
else
|
||||||
DeactivateDevice(IsaDevice->LDN);
|
DeactivateDevice(IsaDevice->LDN);
|
||||||
|
|
||||||
HwDelay();
|
|
||||||
|
|
||||||
WaitForKey();
|
WaitForKey();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue