mirror of
https://github.com/reactos/reactos.git
synced 2025-08-07 08:23:00 +00:00
[HDAUDBUS] Add a timeout into HDA_SendVerbs
This function may stuck during device installation if there are issues with interrupts (or with a device itself). This fixes the boot on my testing ThinkPad x60s
This commit is contained in:
parent
da4ee18cc9
commit
48b3c61b5d
1 changed files with 14 additions and 5 deletions
|
@ -176,11 +176,20 @@ HDA_SendVerbs(
|
||||||
|
|
||||||
while (Queued--)
|
while (Queued--)
|
||||||
{
|
{
|
||||||
KeWaitForSingleObject(&Codec->ResponseSemaphore,
|
LARGE_INTEGER Timeout;
|
||||||
Executive,
|
Timeout.QuadPart = -1000LL * 10000; // 1 sec
|
||||||
KernelMode,
|
|
||||||
FALSE,
|
NTSTATUS waitStatus = KeWaitForSingleObject(&Codec->ResponseSemaphore,
|
||||||
NULL);
|
Executive,
|
||||||
|
KernelMode,
|
||||||
|
FALSE,
|
||||||
|
&Timeout);
|
||||||
|
|
||||||
|
if (waitStatus == STATUS_TIMEOUT)
|
||||||
|
{
|
||||||
|
DPRINT1("HDA_SendVerbs: timeout! Queued: %u\n", Queued);
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Responses != NULL) {
|
if (Responses != NULL) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue