diff options
Diffstat (limited to 'sound/pci/ice1712/aureon.c')
-rw-r--r-- | sound/pci/ice1712/aureon.c | 104 |
1 files changed, 84 insertions, 20 deletions
diff --git a/sound/pci/ice1712/aureon.c b/sound/pci/ice1712/aureon.c index 9492f3d2455..9e76cebd2d2 100644 --- a/sound/pci/ice1712/aureon.c +++ b/sound/pci/ice1712/aureon.c | |||
@@ -60,6 +60,7 @@ | |||
60 | #include "ice1712.h" | 60 | #include "ice1712.h" |
61 | #include "envy24ht.h" | 61 | #include "envy24ht.h" |
62 | #include "aureon.h" | 62 | #include "aureon.h" |
63 | #include <sound/tlv.h> | ||
63 | 64 | ||
64 | /* WM8770 registers */ | 65 | /* WM8770 registers */ |
65 | #define WM_DAC_ATTEN 0x00 /* DAC1-8 analog attenuation */ | 66 | #define WM_DAC_ATTEN 0x00 /* DAC1-8 analog attenuation */ |
@@ -660,6 +661,12 @@ static int aureon_ac97_mmute_put(struct snd_kcontrol *kcontrol, struct snd_ctl_e | |||
660 | return change; | 661 | return change; |
661 | } | 662 | } |
662 | 663 | ||
664 | static DECLARE_TLV_DB_SCALE(db_scale_wm_dac, -12700, 100, 1); | ||
665 | static DECLARE_TLV_DB_SCALE(db_scale_wm_pcm, -6400, 50, 1); | ||
666 | static DECLARE_TLV_DB_SCALE(db_scale_wm_adc, -1200, 100, 0); | ||
667 | static DECLARE_TLV_DB_SCALE(db_scale_ac97_master, -4650, 150, 0); | ||
668 | static DECLARE_TLV_DB_SCALE(db_scale_ac97_gain, -3450, 150, 0); | ||
669 | |||
663 | /* | 670 | /* |
664 | * Logarithmic volume values for WM8770 | 671 | * Logarithmic volume values for WM8770 |
665 | * Computed as 20 * Log10(255 / x) | 672 | * Computed as 20 * Log10(255 / x) |
@@ -1409,10 +1416,13 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1409 | }, | 1416 | }, |
1410 | { | 1417 | { |
1411 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1418 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1419 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1420 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1412 | .name = "Master Playback Volume", | 1421 | .name = "Master Playback Volume", |
1413 | .info = wm_master_vol_info, | 1422 | .info = wm_master_vol_info, |
1414 | .get = wm_master_vol_get, | 1423 | .get = wm_master_vol_get, |
1415 | .put = wm_master_vol_put | 1424 | .put = wm_master_vol_put, |
1425 | .tlv = { .p = db_scale_wm_dac } | ||
1416 | }, | 1426 | }, |
1417 | { | 1427 | { |
1418 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1428 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1424,11 +1434,14 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1424 | }, | 1434 | }, |
1425 | { | 1435 | { |
1426 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1436 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1437 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1438 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1427 | .name = "Front Playback Volume", | 1439 | .name = "Front Playback Volume", |
1428 | .info = wm_vol_info, | 1440 | .info = wm_vol_info, |
1429 | .get = wm_vol_get, | 1441 | .get = wm_vol_get, |
1430 | .put = wm_vol_put, | 1442 | .put = wm_vol_put, |
1431 | .private_value = (2 << 8) | 0 | 1443 | .private_value = (2 << 8) | 0, |
1444 | .tlv = { .p = db_scale_wm_dac } | ||
1432 | }, | 1445 | }, |
1433 | { | 1446 | { |
1434 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1447 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1440,11 +1453,14 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1440 | }, | 1453 | }, |
1441 | { | 1454 | { |
1442 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1455 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1456 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1457 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1443 | .name = "Rear Playback Volume", | 1458 | .name = "Rear Playback Volume", |
1444 | .info = wm_vol_info, | 1459 | .info = wm_vol_info, |
1445 | .get = wm_vol_get, | 1460 | .get = wm_vol_get, |
1446 | .put = wm_vol_put, | 1461 | .put = wm_vol_put, |
1447 | .private_value = (2 << 8) | 2 | 1462 | .private_value = (2 << 8) | 2, |
1463 | .tlv = { .p = db_scale_wm_dac } | ||
1448 | }, | 1464 | }, |
1449 | { | 1465 | { |
1450 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1466 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1456,11 +1472,14 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1456 | }, | 1472 | }, |
1457 | { | 1473 | { |
1458 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1474 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1475 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1476 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1459 | .name = "Center Playback Volume", | 1477 | .name = "Center Playback Volume", |
1460 | .info = wm_vol_info, | 1478 | .info = wm_vol_info, |
1461 | .get = wm_vol_get, | 1479 | .get = wm_vol_get, |
1462 | .put = wm_vol_put, | 1480 | .put = wm_vol_put, |
1463 | .private_value = (1 << 8) | 4 | 1481 | .private_value = (1 << 8) | 4, |
1482 | .tlv = { .p = db_scale_wm_dac } | ||
1464 | }, | 1483 | }, |
1465 | { | 1484 | { |
1466 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1485 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1472,11 +1491,14 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1472 | }, | 1491 | }, |
1473 | { | 1492 | { |
1474 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1493 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1494 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1495 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1475 | .name = "LFE Playback Volume", | 1496 | .name = "LFE Playback Volume", |
1476 | .info = wm_vol_info, | 1497 | .info = wm_vol_info, |
1477 | .get = wm_vol_get, | 1498 | .get = wm_vol_get, |
1478 | .put = wm_vol_put, | 1499 | .put = wm_vol_put, |
1479 | .private_value = (1 << 8) | 5 | 1500 | .private_value = (1 << 8) | 5, |
1501 | .tlv = { .p = db_scale_wm_dac } | ||
1480 | }, | 1502 | }, |
1481 | { | 1503 | { |
1482 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1504 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1488,11 +1510,14 @@ static struct snd_kcontrol_new aureon_dac_controls[] __devinitdata = { | |||
1488 | }, | 1510 | }, |
1489 | { | 1511 | { |
1490 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1512 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1513 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1514 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1491 | .name = "Side Playback Volume", | 1515 | .name = "Side Playback Volume", |
1492 | .info = wm_vol_info, | 1516 | .info = wm_vol_info, |
1493 | .get = wm_vol_get, | 1517 | .get = wm_vol_get, |
1494 | .put = wm_vol_put, | 1518 | .put = wm_vol_put, |
1495 | .private_value = (2 << 8) | 6 | 1519 | .private_value = (2 << 8) | 6, |
1520 | .tlv = { .p = db_scale_wm_dac } | ||
1496 | } | 1521 | } |
1497 | }; | 1522 | }; |
1498 | 1523 | ||
@@ -1506,10 +1531,13 @@ static struct snd_kcontrol_new wm_controls[] __devinitdata = { | |||
1506 | }, | 1531 | }, |
1507 | { | 1532 | { |
1508 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1533 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1534 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1535 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1509 | .name = "PCM Playback Volume", | 1536 | .name = "PCM Playback Volume", |
1510 | .info = wm_pcm_vol_info, | 1537 | .info = wm_pcm_vol_info, |
1511 | .get = wm_pcm_vol_get, | 1538 | .get = wm_pcm_vol_get, |
1512 | .put = wm_pcm_vol_put | 1539 | .put = wm_pcm_vol_put, |
1540 | .tlv = { .p = db_scale_wm_pcm } | ||
1513 | }, | 1541 | }, |
1514 | { | 1542 | { |
1515 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1543 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1520,10 +1548,13 @@ static struct snd_kcontrol_new wm_controls[] __devinitdata = { | |||
1520 | }, | 1548 | }, |
1521 | { | 1549 | { |
1522 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1550 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1551 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1552 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1523 | .name = "Capture Volume", | 1553 | .name = "Capture Volume", |
1524 | .info = wm_adc_vol_info, | 1554 | .info = wm_adc_vol_info, |
1525 | .get = wm_adc_vol_get, | 1555 | .get = wm_adc_vol_get, |
1526 | .put = wm_adc_vol_put | 1556 | .put = wm_adc_vol_put, |
1557 | .tlv = { .p = db_scale_wm_adc } | ||
1527 | }, | 1558 | }, |
1528 | { | 1559 | { |
1529 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1560 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1567,11 +1598,14 @@ static struct snd_kcontrol_new ac97_controls[] __devinitdata = { | |||
1567 | }, | 1598 | }, |
1568 | { | 1599 | { |
1569 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1600 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1601 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1602 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1570 | .name = "AC97 Playback Volume", | 1603 | .name = "AC97 Playback Volume", |
1571 | .info = aureon_ac97_vol_info, | 1604 | .info = aureon_ac97_vol_info, |
1572 | .get = aureon_ac97_vol_get, | 1605 | .get = aureon_ac97_vol_get, |
1573 | .put = aureon_ac97_vol_put, | 1606 | .put = aureon_ac97_vol_put, |
1574 | .private_value = AC97_MASTER|AUREON_AC97_STEREO | 1607 | .private_value = AC97_MASTER|AUREON_AC97_STEREO, |
1608 | .tlv = { .p = db_scale_ac97_master } | ||
1575 | }, | 1609 | }, |
1576 | { | 1610 | { |
1577 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1611 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1583,11 +1617,14 @@ static struct snd_kcontrol_new ac97_controls[] __devinitdata = { | |||
1583 | }, | 1617 | }, |
1584 | { | 1618 | { |
1585 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1619 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1620 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1621 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1586 | .name = "CD Playback Volume", | 1622 | .name = "CD Playback Volume", |
1587 | .info = aureon_ac97_vol_info, | 1623 | .info = aureon_ac97_vol_info, |
1588 | .get = aureon_ac97_vol_get, | 1624 | .get = aureon_ac97_vol_get, |
1589 | .put = aureon_ac97_vol_put, | 1625 | .put = aureon_ac97_vol_put, |
1590 | .private_value = AC97_CD|AUREON_AC97_STEREO | 1626 | .private_value = AC97_CD|AUREON_AC97_STEREO, |
1627 | .tlv = { .p = db_scale_ac97_gain } | ||
1591 | }, | 1628 | }, |
1592 | { | 1629 | { |
1593 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1630 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1599,11 +1636,14 @@ static struct snd_kcontrol_new ac97_controls[] __devinitdata = { | |||
1599 | }, | 1636 | }, |
1600 | { | 1637 | { |
1601 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1638 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1639 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1640 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1602 | .name = "Aux Playback Volume", | 1641 | .name = "Aux Playback Volume", |
1603 | .info = aureon_ac97_vol_info, | 1642 | .info = aureon_ac97_vol_info, |
1604 | .get = aureon_ac97_vol_get, | 1643 | .get = aureon_ac97_vol_get, |
1605 | .put = aureon_ac97_vol_put, | 1644 | .put = aureon_ac97_vol_put, |
1606 | .private_value = AC97_AUX|AUREON_AC97_STEREO | 1645 | .private_value = AC97_AUX|AUREON_AC97_STEREO, |
1646 | .tlv = { .p = db_scale_ac97_gain } | ||
1607 | }, | 1647 | }, |
1608 | { | 1648 | { |
1609 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1649 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1615,11 +1655,14 @@ static struct snd_kcontrol_new ac97_controls[] __devinitdata = { | |||
1615 | }, | 1655 | }, |
1616 | { | 1656 | { |
1617 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1657 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1658 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1659 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1618 | .name = "Line Playback Volume", | 1660 | .name = "Line Playback Volume", |
1619 | .info = aureon_ac97_vol_info, | 1661 | .info = aureon_ac97_vol_info, |
1620 | .get = aureon_ac97_vol_get, | 1662 | .get = aureon_ac97_vol_get, |
1621 | .put = aureon_ac97_vol_put, | 1663 | .put = aureon_ac97_vol_put, |
1622 | .private_value = AC97_LINE|AUREON_AC97_STEREO | 1664 | .private_value = AC97_LINE|AUREON_AC97_STEREO, |
1665 | .tlv = { .p = db_scale_ac97_gain } | ||
1623 | }, | 1666 | }, |
1624 | { | 1667 | { |
1625 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1668 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1631,11 +1674,14 @@ static struct snd_kcontrol_new ac97_controls[] __devinitdata = { | |||
1631 | }, | 1674 | }, |
1632 | { | 1675 | { |
1633 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1676 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1677 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1678 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1634 | .name = "Mic Playback Volume", | 1679 | .name = "Mic Playback Volume", |
1635 | .info = aureon_ac97_vol_info, | 1680 | .info = aureon_ac97_vol_info, |
1636 | .get = aureon_ac97_vol_get, | 1681 | .get = aureon_ac97_vol_get, |
1637 | .put = aureon_ac97_vol_put, | 1682 | .put = aureon_ac97_vol_put, |
1638 | .private_value = AC97_MIC | 1683 | .private_value = AC97_MIC, |
1684 | .tlv = { .p = db_scale_ac97_gain } | ||
1639 | }, | 1685 | }, |
1640 | { | 1686 | { |
1641 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1687 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1657,11 +1703,14 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1657 | }, | 1703 | }, |
1658 | { | 1704 | { |
1659 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1705 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1706 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1707 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1660 | .name = "AC97 Playback Volume", | 1708 | .name = "AC97 Playback Volume", |
1661 | .info = aureon_ac97_vol_info, | 1709 | .info = aureon_ac97_vol_info, |
1662 | .get = aureon_ac97_vol_get, | 1710 | .get = aureon_ac97_vol_get, |
1663 | .put = aureon_ac97_vol_put, | 1711 | .put = aureon_ac97_vol_put, |
1664 | .private_value = AC97_MASTER|AUREON_AC97_STEREO | 1712 | .private_value = AC97_MASTER|AUREON_AC97_STEREO, |
1713 | .tlv = { .p = db_scale_ac97_master } | ||
1665 | }, | 1714 | }, |
1666 | { | 1715 | { |
1667 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1716 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1673,11 +1722,14 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1673 | }, | 1722 | }, |
1674 | { | 1723 | { |
1675 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1724 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1725 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1726 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1676 | .name = "CD Playback Volume", | 1727 | .name = "CD Playback Volume", |
1677 | .info = aureon_ac97_vol_info, | 1728 | .info = aureon_ac97_vol_info, |
1678 | .get = aureon_ac97_vol_get, | 1729 | .get = aureon_ac97_vol_get, |
1679 | .put = aureon_ac97_vol_put, | 1730 | .put = aureon_ac97_vol_put, |
1680 | .private_value = AC97_AUX|AUREON_AC97_STEREO | 1731 | .private_value = AC97_AUX|AUREON_AC97_STEREO, |
1732 | .tlv = { .p = db_scale_ac97_gain } | ||
1681 | }, | 1733 | }, |
1682 | { | 1734 | { |
1683 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1735 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1685,15 +1737,18 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1685 | .info = aureon_ac97_mute_info, | 1737 | .info = aureon_ac97_mute_info, |
1686 | .get = aureon_ac97_mute_get, | 1738 | .get = aureon_ac97_mute_get, |
1687 | .put = aureon_ac97_mute_put, | 1739 | .put = aureon_ac97_mute_put, |
1688 | .private_value = AC97_CD, | 1740 | .private_value = AC97_CD |
1689 | }, | 1741 | }, |
1690 | { | 1742 | { |
1691 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1743 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1744 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1745 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1692 | .name = "Phono Playback Volume", | 1746 | .name = "Phono Playback Volume", |
1693 | .info = aureon_ac97_vol_info, | 1747 | .info = aureon_ac97_vol_info, |
1694 | .get = aureon_ac97_vol_get, | 1748 | .get = aureon_ac97_vol_get, |
1695 | .put = aureon_ac97_vol_put, | 1749 | .put = aureon_ac97_vol_put, |
1696 | .private_value = AC97_CD|AUREON_AC97_STEREO | 1750 | .private_value = AC97_CD|AUREON_AC97_STEREO, |
1751 | .tlv = { .p = db_scale_ac97_gain } | ||
1697 | }, | 1752 | }, |
1698 | { | 1753 | { |
1699 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1754 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1705,11 +1760,14 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1705 | }, | 1760 | }, |
1706 | { | 1761 | { |
1707 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1762 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1763 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1764 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1708 | .name = "Line Playback Volume", | 1765 | .name = "Line Playback Volume", |
1709 | .info = aureon_ac97_vol_info, | 1766 | .info = aureon_ac97_vol_info, |
1710 | .get = aureon_ac97_vol_get, | 1767 | .get = aureon_ac97_vol_get, |
1711 | .put = aureon_ac97_vol_put, | 1768 | .put = aureon_ac97_vol_put, |
1712 | .private_value = AC97_LINE|AUREON_AC97_STEREO | 1769 | .private_value = AC97_LINE|AUREON_AC97_STEREO, |
1770 | .tlv = { .p = db_scale_ac97_gain } | ||
1713 | }, | 1771 | }, |
1714 | { | 1772 | { |
1715 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1773 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1721,11 +1779,14 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1721 | }, | 1779 | }, |
1722 | { | 1780 | { |
1723 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1781 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1782 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1783 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1724 | .name = "Mic Playback Volume", | 1784 | .name = "Mic Playback Volume", |
1725 | .info = aureon_ac97_vol_info, | 1785 | .info = aureon_ac97_vol_info, |
1726 | .get = aureon_ac97_vol_get, | 1786 | .get = aureon_ac97_vol_get, |
1727 | .put = aureon_ac97_vol_put, | 1787 | .put = aureon_ac97_vol_put, |
1728 | .private_value = AC97_MIC | 1788 | .private_value = AC97_MIC, |
1789 | .tlv = { .p = db_scale_ac97_gain } | ||
1729 | }, | 1790 | }, |
1730 | { | 1791 | { |
1731 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1792 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
@@ -1744,11 +1805,14 @@ static struct snd_kcontrol_new universe_ac97_controls[] __devinitdata = { | |||
1744 | }, | 1805 | }, |
1745 | { | 1806 | { |
1746 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1807 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |
1808 | .access = (SNDRV_CTL_ELEM_ACCESS_READWRITE | | ||
1809 | SNDRV_CTL_ELEM_ACCESS_TLV_READ), | ||
1747 | .name = "Aux Playback Volume", | 1810 | .name = "Aux Playback Volume", |
1748 | .info = aureon_ac97_vol_info, | 1811 | .info = aureon_ac97_vol_info, |
1749 | .get = aureon_ac97_vol_get, | 1812 | .get = aureon_ac97_vol_get, |
1750 | .put = aureon_ac97_vol_put, | 1813 | .put = aureon_ac97_vol_put, |
1751 | .private_value = AC97_VIDEO|AUREON_AC97_STEREO | 1814 | .private_value = AC97_VIDEO|AUREON_AC97_STEREO, |
1815 | .tlv = { .p = db_scale_ac97_gain } | ||
1752 | }, | 1816 | }, |
1753 | { | 1817 | { |
1754 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, | 1818 | .iface = SNDRV_CTL_ELEM_IFACE_MIXER, |