Changeset 76 for GPL/trunk/alsa-kernel/pci/cs4281.c
- Timestamp:
- Apr 9, 2006, 12:09:39 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GPL/trunk/alsa-kernel/pci/cs4281.c
r34 r76 1092 1092 change = 1; 1093 1093 } 1094 if (ucontrol->value.integer.value[0] != vol L) {1094 if (ucontrol->value.integer.value[0] != volR) { 1095 1095 volR = CS_VOL_MASK - (ucontrol->value.integer.value[1] & CS_VOL_MASK); 1096 1096 snd_cs4281_pokeBA0(chip, regR, volR); … … 1462 1462 { 1463 1463 unsigned int tmp; 1464 int timeout;1464 unsigned long end_time; 1465 1465 int retry_count = 2; 1466 1466 … … 1541 1541 * Wait for the DLL ready signal from the clock logic. 1542 1542 */ 1543 #ifdef TARGET_OS2 1544 // end_time = (jiffies + 1000) + 1; 1545 #else 1546 // end_time = (jiffies + HZ / 4) + 1; 1547 #endif 1548 timeout = HZ; 1543 end_time = jiffies + HZ; 1549 1544 do { 1550 1545 /* … … 1554 1549 if (snd_cs4281_peekBA0(chip, BA0_CLKCR1) & BA0_CLKCR1_DLLRDY) 1555 1550 goto __ok0; 1556 s nd_cs4281_delay_long();1557 } while (time out-- > 0);1551 schedule_timeout_uninterruptible(1); 1552 } while (time_after_eq(end_time, jiffies)); 1558 1553 1559 1554 snd_printk(KERN_ERR "DLLRDY not seen\n"); … … 1572 1567 * Wait for the codec ready signal from the AC97 codec. 1573 1568 */ 1574 #ifdef TARGET_OS2 1575 // end_time = (jiffies + 1000) + 1; 1576 #else 1577 // end_time = (jiffies + (3 * HZ) / 4) + 1; 1578 #endif 1579 timeout = HZ; 1569 end_time = jiffies + HZ; 1580 1570 do { 1581 1571 /* … … 1585 1575 if (snd_cs4281_peekBA0(chip, BA0_ACSTS) & BA0_ACSTS_CRDY) 1586 1576 goto __ok1; 1587 s nd_cs4281_delay_long();1588 } while (time out-- > 0);1577 schedule_timeout_uninterruptible(1); 1578 } while (time_after_eq(end_time, jiffies)); 1589 1579 1590 1580 snd_printk(KERN_ERR "never read codec ready from AC'97 (0x%x)\n", snd_cs4281_peekBA0(chip, BA0_ACSTS)); … … 1593 1583 __ok1: 1594 1584 if (chip->dual_codec) { 1595 timeout =HZ;1585 end_time = jiffies + HZ; 1596 1586 do { 1597 1587 if (snd_cs4281_peekBA0(chip, BA0_ACSTS2) & BA0_ACSTS_CRDY) 1598 1588 goto __codec2_ok; 1599 s nd_cs4281_delay_long();1600 } while (time out-- > 0);1589 schedule_timeout_uninterruptible(1); 1590 } while (time_after_eq(end_time, jiffies)); 1601 1591 snd_printk(KERN_INFO "secondary codec doesn't respond. disable it...\n"); 1602 1592 chip->dual_codec = 0; … … 1615 1605 * the codec is pumping ADC data across the AC-link. 1616 1606 */ 1617 1618 #ifdef TARGET_OS2 1619 // end_time = (jiffies + 5000); 1620 #else 1621 // end_time = (jiffies + (5 * HZ) / 4) + 1; 1622 #endif 1623 timeout = HZ; 1607 end_time = jiffies + HZ; 1624 1608 do { 1625 1609 /* … … 1629 1613 if ((snd_cs4281_peekBA0(chip, BA0_ACISV) & (BA0_ACISV_SLV(3) | BA0_ACISV_SLV(4))) == (BA0_ACISV_SLV(3) | BA0_ACISV_SLV(4))) 1630 1614 goto __ok2; 1631 s nd_cs4281_delay_long();1632 } while (time out-- > 0);1615 schedule_timeout_uninterruptible(1); 1616 } while (time_after_eq(end_time, jiffies)); 1633 1617 1634 1618 if (--retry_count > 0)
Note:
See TracChangeset
for help on using the changeset viewer.