probably/hopefully fixed auich driver for many systems: note that the codec_access_semaphore will NOT be reset on certain systems if an illegal/non existing register was accessed before. We need to do the access anyway to get such systems working. I hope someone can create a more extensive entry in syslog here to identify the offending access as that can be done AFAICT. This will help improve the driver later on because the non-existing-register accesses could be removed. Anyhow: I think the change I just did should remain, as it makes the driver more fault-tolerant to faults in itself (or hardware). Lowered the wait time to 1mS btw as that should suffice big_time. My Dell Inspiron C610 laptop with ICH3-M and Crystal CS4205 now works perfectly. No sound at all before.. Fix found in Linux-2.6.17/sound/pci/intel8x0m.c. Hope no-one is offended by my 'intrusion' here. Bye.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25852 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
765e53019a
commit
f31163e967
@ -108,13 +108,19 @@ static int
|
||||
auich_codec_wait(device_config *config)
|
||||
{
|
||||
int i;
|
||||
for (i = 0; i < 1100; i++) {
|
||||
/* Anyone holding a semaphore for 1 msec should be 'shot'... */
|
||||
for (i = 0; i < 200; i++) {
|
||||
if ((auich_reg_read_8(config, AUICH_REG_ACC_SEMA) & 0x01) == 0)
|
||||
return B_OK;
|
||||
if (i > 100)
|
||||
snooze(10);
|
||||
}
|
||||
return B_TIMED_OUT;
|
||||
/* access to some forbidden (non existant) ac97 registers will not
|
||||
* reset the semaphore. So even if you don't get the semaphore, still
|
||||
* continue the access. We don't really need the semaphore anyway. */
|
||||
PRINT(("codec semaphore timed out!\n"));
|
||||
|
||||
return B_OK;
|
||||
}
|
||||
|
||||
uint16
|
||||
|
Loading…
Reference in New Issue
Block a user