summaryrefslogtreecommitdiffstats
path: root/sound/x86
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2017-04-27 12:02:29 -0400
committerVille Syrjälä <ville.syrjala@linux.intel.com>2017-05-03 09:23:56 -0400
commitb4eb0d522fcba0ee819f955fd3279ff4682b8b33 (patch)
tree6be766a5b782538d224456b62893b66fa06a8f21 /sound/x86
parentbb4ac5a0ecaeeef0229c69f6c935be2ee70abfec (diff)
ALSA: x86: Split snd_intelhad into card and PCM specific structures
To allow multiple PCM devices to be registered for the LPE audio card, split the private data into card and PCM specific chunks. For now we'll stick to just one PCM device as before. v2: Rework to do a pcm device per port instead of per pipe Cc: Takashi Iwai <tiwai@suse.de> Cc: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/20170427160231.13337-11-ville.syrjala@linux.intel.com Reviewed-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/x86')
-rw-r--r--sound/x86/intel_hdmi_audio.c227
-rw-r--r--sound/x86/intel_hdmi_audio.h15
2 files changed, 142 insertions, 100 deletions
diff --git a/sound/x86/intel_hdmi_audio.c b/sound/x86/intel_hdmi_audio.c
index 69e10845633a..12fae26e70bb 100644
--- a/sound/x86/intel_hdmi_audio.c
+++ b/sound/x86/intel_hdmi_audio.c
@@ -42,6 +42,9 @@
42#include <drm/intel_lpe_audio.h> 42#include <drm/intel_lpe_audio.h>
43#include "intel_hdmi_audio.h" 43#include "intel_hdmi_audio.h"
44 44
45#define for_each_port(card_ctx, port) \
46 for ((port) = 0; (port) < (card_ctx)->num_ports; (port)++)
47
45/*standard module options for ALSA. This module supports only one card*/ 48/*standard module options for ALSA. This module supports only one card*/
46static int hdmi_card_index = SNDRV_DEFAULT_IDX1; 49static int hdmi_card_index = SNDRV_DEFAULT_IDX1;
47static char *hdmi_card_id = SNDRV_DEFAULT_STR1; 50static char *hdmi_card_id = SNDRV_DEFAULT_STR1;
@@ -192,12 +195,12 @@ static void had_substream_put(struct snd_intelhad *intelhaddata)
192/* Register access functions */ 195/* Register access functions */
193static u32 had_read_register_raw(struct snd_intelhad *ctx, u32 reg) 196static u32 had_read_register_raw(struct snd_intelhad *ctx, u32 reg)
194{ 197{
195 return ioread32(ctx->mmio_start + ctx->had_config_offset + reg); 198 return ioread32(ctx->card_ctx->mmio_start + ctx->had_config_offset + reg);
196} 199}
197 200
198static void had_write_register_raw(struct snd_intelhad *ctx, u32 reg, u32 val) 201static void had_write_register_raw(struct snd_intelhad *ctx, u32 reg, u32 val)
199{ 202{
200 iowrite32(val, ctx->mmio_start + ctx->had_config_offset + reg); 203 iowrite32(val, ctx->card_ctx->mmio_start + ctx->had_config_offset + reg);
201} 204}
202 205
203static void had_read_register(struct snd_intelhad *ctx, u32 reg, u32 *val) 206static void had_read_register(struct snd_intelhad *ctx, u32 reg, u32 *val)
@@ -1519,22 +1522,27 @@ static const struct snd_kcontrol_new had_controls[] = {
1519 */ 1522 */
1520static irqreturn_t display_pipe_interrupt_handler(int irq, void *dev_id) 1523static irqreturn_t display_pipe_interrupt_handler(int irq, void *dev_id)
1521{ 1524{
1522 struct snd_intelhad *ctx = dev_id; 1525 struct snd_intelhad_card *card_ctx = dev_id;
1523 u32 audio_stat; 1526 int port;
1524 1527
1525 /* use raw register access to ack IRQs even while disconnected */ 1528 for_each_port(card_ctx, port) {
1526 audio_stat = had_read_register_raw(ctx, AUD_HDMI_STATUS); 1529 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1530 u32 audio_stat;
1527 1531
1528 if (audio_stat & HDMI_AUDIO_UNDERRUN) { 1532 /* use raw register access to ack IRQs even while disconnected */
1529 had_write_register_raw(ctx, AUD_HDMI_STATUS, 1533 audio_stat = had_read_register_raw(ctx, AUD_HDMI_STATUS);
1530 HDMI_AUDIO_UNDERRUN); 1534
1531 had_process_buffer_underrun(ctx); 1535 if (audio_stat & HDMI_AUDIO_UNDERRUN) {
1532 } 1536 had_write_register_raw(ctx, AUD_HDMI_STATUS,
1537 HDMI_AUDIO_UNDERRUN);
1538 had_process_buffer_underrun(ctx);
1539 }
1533 1540
1534 if (audio_stat & HDMI_AUDIO_BUFFER_DONE) { 1541 if (audio_stat & HDMI_AUDIO_BUFFER_DONE) {
1535 had_write_register_raw(ctx, AUD_HDMI_STATUS, 1542 had_write_register_raw(ctx, AUD_HDMI_STATUS,
1536 HDMI_AUDIO_BUFFER_DONE); 1543 HDMI_AUDIO_BUFFER_DONE);
1537 had_process_buffer_done(ctx); 1544 had_process_buffer_done(ctx);
1545 }
1538 } 1546 }
1539 1547
1540 return IRQ_HANDLED; 1548 return IRQ_HANDLED;
@@ -1545,9 +1553,14 @@ static irqreturn_t display_pipe_interrupt_handler(int irq, void *dev_id)
1545 */ 1553 */
1546static void notify_audio_lpe(struct platform_device *pdev) 1554static void notify_audio_lpe(struct platform_device *pdev)
1547{ 1555{
1548 struct snd_intelhad *ctx = platform_get_drvdata(pdev); 1556 struct snd_intelhad_card *card_ctx = platform_get_drvdata(pdev);
1557 int port;
1558
1559 for_each_port(card_ctx, port) {
1560 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1549 1561
1550 schedule_work(&ctx->hdmi_audio_wq); 1562 schedule_work(&ctx->hdmi_audio_wq);
1563 }
1551} 1564}
1552 1565
1553/* the work to handle monitor hot plug/unplug */ 1566/* the work to handle monitor hot plug/unplug */
@@ -1618,7 +1631,8 @@ static int had_create_jack(struct snd_intelhad *ctx,
1618 snprintf(hdmi_str, sizeof(hdmi_str), 1631 snprintf(hdmi_str, sizeof(hdmi_str),
1619 "HDMI/DP,pcm=%d", pcm->device); 1632 "HDMI/DP,pcm=%d", pcm->device);
1620 1633
1621 err = snd_jack_new(ctx->card, hdmi_str, SND_JACK_AVOUT, &ctx->jack, 1634 err = snd_jack_new(ctx->card_ctx->card, hdmi_str,
1635 SND_JACK_AVOUT, &ctx->jack,
1622 true, false); 1636 true, false);
1623 if (err < 0) 1637 if (err < 0)
1624 return err; 1638 return err;
@@ -1632,13 +1646,18 @@ static int had_create_jack(struct snd_intelhad *ctx,
1632 1646
1633static int hdmi_lpe_audio_runtime_suspend(struct device *dev) 1647static int hdmi_lpe_audio_runtime_suspend(struct device *dev)
1634{ 1648{
1635 struct snd_intelhad *ctx = dev_get_drvdata(dev); 1649 struct snd_intelhad_card *card_ctx = dev_get_drvdata(dev);
1636 struct snd_pcm_substream *substream; 1650 int port;
1637 1651
1638 substream = had_substream_get(ctx); 1652 for_each_port(card_ctx, port) {
1639 if (substream) { 1653 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1640 snd_pcm_suspend(substream); 1654 struct snd_pcm_substream *substream;
1641 had_substream_put(ctx); 1655
1656 substream = had_substream_get(ctx);
1657 if (substream) {
1658 snd_pcm_suspend(substream);
1659 had_substream_put(ctx);
1660 }
1642 } 1661 }
1643 1662
1644 return 0; 1663 return 0;
@@ -1646,12 +1665,12 @@ static int hdmi_lpe_audio_runtime_suspend(struct device *dev)
1646 1665
1647static int __maybe_unused hdmi_lpe_audio_suspend(struct device *dev) 1666static int __maybe_unused hdmi_lpe_audio_suspend(struct device *dev)
1648{ 1667{
1649 struct snd_intelhad *ctx = dev_get_drvdata(dev); 1668 struct snd_intelhad_card *card_ctx = dev_get_drvdata(dev);
1650 int err; 1669 int err;
1651 1670
1652 err = hdmi_lpe_audio_runtime_suspend(dev); 1671 err = hdmi_lpe_audio_runtime_suspend(dev);
1653 if (!err) 1672 if (!err)
1654 snd_power_change_state(ctx->card, SNDRV_CTL_POWER_D3hot); 1673 snd_power_change_state(card_ctx->card, SNDRV_CTL_POWER_D3hot);
1655 return err; 1674 return err;
1656} 1675}
1657 1676
@@ -1663,29 +1682,34 @@ static int hdmi_lpe_audio_runtime_resume(struct device *dev)
1663 1682
1664static int __maybe_unused hdmi_lpe_audio_resume(struct device *dev) 1683static int __maybe_unused hdmi_lpe_audio_resume(struct device *dev)
1665{ 1684{
1666 struct snd_intelhad *ctx = dev_get_drvdata(dev); 1685 struct snd_intelhad_card *card_ctx = dev_get_drvdata(dev);
1667 1686
1668 hdmi_lpe_audio_runtime_resume(dev); 1687 hdmi_lpe_audio_runtime_resume(dev);
1669 snd_power_change_state(ctx->card, SNDRV_CTL_POWER_D0); 1688 snd_power_change_state(card_ctx->card, SNDRV_CTL_POWER_D0);
1670 return 0; 1689 return 0;
1671} 1690}
1672 1691
1673/* release resources */ 1692/* release resources */
1674static void hdmi_lpe_audio_free(struct snd_card *card) 1693static void hdmi_lpe_audio_free(struct snd_card *card)
1675{ 1694{
1676 struct snd_intelhad *ctx = card->private_data; 1695 struct snd_intelhad_card *card_ctx = card->private_data;
1677 struct intel_hdmi_lpe_audio_pdata *pdata = ctx->dev->platform_data; 1696 struct intel_hdmi_lpe_audio_pdata *pdata = card_ctx->dev->platform_data;
1697 int port;
1678 1698
1679 spin_lock_irq(&pdata->lpe_audio_slock); 1699 spin_lock_irq(&pdata->lpe_audio_slock);
1680 pdata->notify_audio_lpe = NULL; 1700 pdata->notify_audio_lpe = NULL;
1681 spin_unlock_irq(&pdata->lpe_audio_slock); 1701 spin_unlock_irq(&pdata->lpe_audio_slock);
1682 1702
1683 cancel_work_sync(&ctx->hdmi_audio_wq); 1703 for_each_port(card_ctx, port) {
1704 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1705
1706 cancel_work_sync(&ctx->hdmi_audio_wq);
1707 }
1684 1708
1685 if (ctx->mmio_start) 1709 if (card_ctx->mmio_start)
1686 iounmap(ctx->mmio_start); 1710 iounmap(card_ctx->mmio_start);
1687 if (ctx->irq >= 0) 1711 if (card_ctx->irq >= 0)
1688 free_irq(ctx->irq, ctx); 1712 free_irq(card_ctx->irq, card_ctx);
1689} 1713}
1690 1714
1691/* 1715/*
@@ -1697,12 +1721,12 @@ static void hdmi_lpe_audio_free(struct snd_card *card)
1697static int hdmi_lpe_audio_probe(struct platform_device *pdev) 1721static int hdmi_lpe_audio_probe(struct platform_device *pdev)
1698{ 1722{
1699 struct snd_card *card; 1723 struct snd_card *card;
1700 struct snd_intelhad *ctx; 1724 struct snd_intelhad_card *card_ctx;
1701 struct snd_pcm *pcm; 1725 struct snd_pcm *pcm;
1702 struct intel_hdmi_lpe_audio_pdata *pdata; 1726 struct intel_hdmi_lpe_audio_pdata *pdata;
1703 int irq; 1727 int irq;
1704 struct resource *res_mmio; 1728 struct resource *res_mmio;
1705 int i, ret; 1729 int port, ret;
1706 1730
1707 pdata = pdev->dev.platform_data; 1731 pdata = pdev->dev.platform_data;
1708 if (!pdata) { 1732 if (!pdata) {
@@ -1725,39 +1749,30 @@ static int hdmi_lpe_audio_probe(struct platform_device *pdev)
1725 1749
1726 /* create a card instance with ALSA framework */ 1750 /* create a card instance with ALSA framework */
1727 ret = snd_card_new(&pdev->dev, hdmi_card_index, hdmi_card_id, 1751 ret = snd_card_new(&pdev->dev, hdmi_card_index, hdmi_card_id,
1728 THIS_MODULE, sizeof(*ctx), &card); 1752 THIS_MODULE, sizeof(*card_ctx), &card);
1729 if (ret) 1753 if (ret)
1730 return ret; 1754 return ret;
1731 1755
1732 ctx = card->private_data; 1756 card_ctx = card->private_data;
1733 spin_lock_init(&ctx->had_spinlock); 1757 card_ctx->dev = &pdev->dev;
1734 mutex_init(&ctx->mutex); 1758 card_ctx->card = card;
1735 ctx->connected = false;
1736 ctx->dev = &pdev->dev;
1737 ctx->card = card;
1738 ctx->aes_bits = SNDRV_PCM_DEFAULT_CON_SPDIF;
1739 strcpy(card->driver, INTEL_HAD); 1759 strcpy(card->driver, INTEL_HAD);
1740 strcpy(card->shortname, "Intel HDMI/DP LPE Audio"); 1760 strcpy(card->shortname, "Intel HDMI/DP LPE Audio");
1741 strcpy(card->longname, "Intel HDMI/DP LPE Audio"); 1761 strcpy(card->longname, "Intel HDMI/DP LPE Audio");
1742 1762
1743 ctx->irq = -1; 1763 card_ctx->irq = -1;
1744 ctx->tmds_clock_speed = DIS_SAMPLE_RATE_148_5;
1745 INIT_WORK(&ctx->hdmi_audio_wq, had_audio_wq);
1746 1764
1747 card->private_free = hdmi_lpe_audio_free; 1765 card->private_free = hdmi_lpe_audio_free;
1748 1766
1749 /* assume pipe A as default */ 1767 platform_set_drvdata(pdev, card_ctx);
1750 ctx->had_config_offset = AUDIO_HDMI_CONFIG_A;
1751
1752 platform_set_drvdata(pdev, ctx);
1753 1768
1754 dev_dbg(&pdev->dev, "%s: mmio_start = 0x%x, mmio_end = 0x%x\n", 1769 dev_dbg(&pdev->dev, "%s: mmio_start = 0x%x, mmio_end = 0x%x\n",
1755 __func__, (unsigned int)res_mmio->start, 1770 __func__, (unsigned int)res_mmio->start,
1756 (unsigned int)res_mmio->end); 1771 (unsigned int)res_mmio->end);
1757 1772
1758 ctx->mmio_start = ioremap_nocache(res_mmio->start, 1773 card_ctx->mmio_start = ioremap_nocache(res_mmio->start,
1759 (size_t)(resource_size(res_mmio))); 1774 (size_t)(resource_size(res_mmio)));
1760 if (!ctx->mmio_start) { 1775 if (!card_ctx->mmio_start) {
1761 dev_err(&pdev->dev, "Could not get ioremap\n"); 1776 dev_err(&pdev->dev, "Could not get ioremap\n");
1762 ret = -EACCES; 1777 ret = -EACCES;
1763 goto err; 1778 goto err;
@@ -1765,65 +1780,79 @@ static int hdmi_lpe_audio_probe(struct platform_device *pdev)
1765 1780
1766 /* setup interrupt handler */ 1781 /* setup interrupt handler */
1767 ret = request_irq(irq, display_pipe_interrupt_handler, 0, 1782 ret = request_irq(irq, display_pipe_interrupt_handler, 0,
1768 pdev->name, ctx); 1783 pdev->name, card_ctx);
1769 if (ret < 0) { 1784 if (ret < 0) {
1770 dev_err(&pdev->dev, "request_irq failed\n"); 1785 dev_err(&pdev->dev, "request_irq failed\n");
1771 goto err; 1786 goto err;
1772 } 1787 }
1773 1788
1774 ctx->irq = irq; 1789 card_ctx->irq = irq;
1775
1776 ret = snd_pcm_new(card, INTEL_HAD, PCM_INDEX, MAX_PB_STREAMS,
1777 MAX_CAP_STREAMS, &pcm);
1778 if (ret)
1779 goto err;
1780
1781 /* setup private data which can be retrieved when required */
1782 pcm->private_data = ctx;
1783 pcm->info_flags = 0;
1784 strncpy(pcm->name, card->shortname, strlen(card->shortname));
1785 /* setup the ops for playabck */
1786 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &had_pcm_ops);
1787 1790
1788 /* only 32bit addressable */ 1791 /* only 32bit addressable */
1789 dma_set_mask(&pdev->dev, DMA_BIT_MASK(32)); 1792 dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
1790 dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(32)); 1793 dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(32));
1791 1794
1792 /* allocate dma pages; 1795 init_channel_allocations();
1793 * try to allocate 600k buffer as default which is large enough
1794 */
1795 snd_pcm_lib_preallocate_pages_for_all(pcm,
1796 SNDRV_DMA_TYPE_DEV, NULL,
1797 HAD_DEFAULT_BUFFER, HAD_MAX_BUFFER);
1798 1796
1799 /* create controls */ 1797 card_ctx->num_ports = 1;
1800 for (i = 0; i < ARRAY_SIZE(had_controls); i++) {
1801 struct snd_kcontrol *kctl;
1802 1798
1803 kctl = snd_ctl_new1(&had_controls[i], ctx); 1799 for_each_port(card_ctx, port) {
1804 if (!kctl) { 1800 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1805 ret = -ENOMEM; 1801 int i;
1802
1803 ctx->card_ctx = card_ctx;
1804 ctx->dev = card_ctx->dev;
1805
1806 INIT_WORK(&ctx->hdmi_audio_wq, had_audio_wq);
1807
1808 ctx->had_config_offset = AUDIO_HDMI_CONFIG_A;
1809
1810 ret = snd_pcm_new(card, INTEL_HAD, PCM_INDEX, MAX_PB_STREAMS,
1811 MAX_CAP_STREAMS, &pcm);
1812 if (ret)
1806 goto err; 1813 goto err;
1814
1815 /* setup private data which can be retrieved when required */
1816 pcm->private_data = ctx;
1817 pcm->info_flags = 0;
1818 strncpy(pcm->name, card->shortname, strlen(card->shortname));
1819 /* setup the ops for playabck */
1820 snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &had_pcm_ops);
1821
1822 /* allocate dma pages;
1823 * try to allocate 600k buffer as default which is large enough
1824 */
1825 snd_pcm_lib_preallocate_pages_for_all(pcm,
1826 SNDRV_DMA_TYPE_DEV, NULL,
1827 HAD_DEFAULT_BUFFER, HAD_MAX_BUFFER);
1828
1829 /* create controls */
1830 for (i = 0; i < ARRAY_SIZE(had_controls); i++) {
1831 struct snd_kcontrol *kctl;
1832
1833 kctl = snd_ctl_new1(&had_controls[i], ctx);
1834 if (!kctl) {
1835 ret = -ENOMEM;
1836 goto err;
1837 }
1838
1839 kctl->id.device = pcm->device;
1840
1841 ret = snd_ctl_add(card, kctl);
1842 if (ret < 0)
1843 goto err;
1807 } 1844 }
1808 1845
1809 kctl->id.device = pcm->device; 1846 /* Register channel map controls */
1847 ret = had_register_chmap_ctls(ctx, pcm);
1848 if (ret < 0)
1849 goto err;
1810 1850
1811 ret = snd_ctl_add(card, kctl); 1851 ret = had_create_jack(ctx, pcm);
1812 if (ret < 0) 1852 if (ret < 0)
1813 goto err; 1853 goto err;
1814 } 1854 }
1815 1855
1816 init_channel_allocations();
1817
1818 /* Register channel map controls */
1819 ret = had_register_chmap_ctls(ctx, pcm);
1820 if (ret < 0)
1821 goto err;
1822
1823 ret = had_create_jack(ctx, pcm);
1824 if (ret < 0)
1825 goto err;
1826
1827 ret = snd_card_register(card); 1856 ret = snd_card_register(card);
1828 if (ret) 1857 if (ret)
1829 goto err; 1858 goto err;
@@ -1837,7 +1866,11 @@ static int hdmi_lpe_audio_probe(struct platform_device *pdev)
1837 pm_runtime_set_active(&pdev->dev); 1866 pm_runtime_set_active(&pdev->dev);
1838 1867
1839 dev_dbg(&pdev->dev, "%s: handle pending notification\n", __func__); 1868 dev_dbg(&pdev->dev, "%s: handle pending notification\n", __func__);
1840 schedule_work(&ctx->hdmi_audio_wq); 1869 for_each_port(card_ctx, port) {
1870 struct snd_intelhad *ctx = &card_ctx->pcm_ctx[port];
1871
1872 schedule_work(&ctx->hdmi_audio_wq);
1873 }
1841 1874
1842 return 0; 1875 return 0;
1843 1876
@@ -1853,9 +1886,9 @@ err:
1853 */ 1886 */
1854static int hdmi_lpe_audio_remove(struct platform_device *pdev) 1887static int hdmi_lpe_audio_remove(struct platform_device *pdev)
1855{ 1888{
1856 struct snd_intelhad *ctx = platform_get_drvdata(pdev); 1889 struct snd_intelhad_card *card_ctx = platform_get_drvdata(pdev);
1857 1890
1858 snd_card_free(ctx->card); 1891 snd_card_free(card_ctx->card);
1859 return 0; 1892 return 0;
1860} 1893}
1861 1894
diff --git a/sound/x86/intel_hdmi_audio.h b/sound/x86/intel_hdmi_audio.h
index 2d3e389f76b3..2725964ebc46 100644
--- a/sound/x86/intel_hdmi_audio.h
+++ b/sound/x86/intel_hdmi_audio.h
@@ -101,7 +101,7 @@ struct pcm_stream_info {
101 * @chmap: holds channel map info 101 * @chmap: holds channel map info
102 */ 102 */
103struct snd_intelhad { 103struct snd_intelhad {
104 struct snd_card *card; 104 struct snd_intelhad_card *card_ctx;
105 bool connected; 105 bool connected;
106 struct pcm_stream_info stream_info; 106 struct pcm_stream_info stream_info;
107 unsigned char eld[HDMI_MAX_ELD_BYTES]; 107 unsigned char eld[HDMI_MAX_ELD_BYTES];
@@ -123,8 +123,6 @@ struct snd_intelhad {
123 unsigned int period_bytes; /* PCM period size in bytes */ 123 unsigned int period_bytes; /* PCM period size in bytes */
124 124
125 /* internal stuff */ 125 /* internal stuff */
126 int irq;
127 void __iomem *mmio_start;
128 unsigned int had_config_offset; 126 unsigned int had_config_offset;
129 union aud_cfg aud_config; /* AUD_CONFIG reg value cache */ 127 union aud_cfg aud_config; /* AUD_CONFIG reg value cache */
130 struct work_struct hdmi_audio_wq; 128 struct work_struct hdmi_audio_wq;
@@ -133,4 +131,15 @@ struct snd_intelhad {
133 struct snd_jack *jack; 131 struct snd_jack *jack;
134}; 132};
135 133
134struct snd_intelhad_card {
135 struct snd_card *card;
136 struct device *dev;
137
138 /* internal stuff */
139 int irq;
140 void __iomem *mmio_start;
141 int num_ports;
142 struct snd_intelhad pcm_ctx[3];
143};
144
136#endif /* _INTEL_HDMI_AUDIO_ */ 145#endif /* _INTEL_HDMI_AUDIO_ */