本文整理汇总了C++中snd_soc_unregister_dai函数的典型用法代码示例。如果您正苦于以下问题:C++ snd_soc_unregister_dai函数的具体用法?C++ snd_soc_unregister_dai怎么用?C++ snd_soc_unregister_dai使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了snd_soc_unregister_dai函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: msm_dai_q6_dai_auxpcm_remove
static int msm_dai_q6_dai_auxpcm_remove(struct snd_soc_dai *dai)
{
struct msm_dai_q6_dai_data *dai_data;
int rc;
dai_data = dev_get_drvdata(dai->dev);
mutex_lock(&aux_pcm_mutex);
if (aux_pcm_count == 0) {
dev_dbg(dai->dev, "%s(): dai->id %d aux_pcm_count is 0. clean"
" up and return\n", __func__, dai->id);
goto done;
}
aux_pcm_count--;
if (aux_pcm_count > 0) {
dev_dbg(dai->dev, "%s(): dai->id %d aux_pcm_count = %d\n",
__func__, dai->id, aux_pcm_count);
goto done;
} else if (aux_pcm_count < 0) {
dev_err(dai->dev, "%s(): ERROR: dai->id %d"
" aux_pcm_count = %d < 0\n",
__func__, dai->id, aux_pcm_count);
goto done;
}
dev_dbg(dai->dev, "%s(): dai->id %d aux_pcm_count = %d."
"closing afe\n",
__func__, dai->id, aux_pcm_count);
rc = afe_close(PCM_RX); /* can block */
if (IS_ERR_VALUE(rc))
dev_err(dai->dev, "fail to close AUX PCM RX AFE port\n");
rc = afe_close(PCM_TX);
if (IS_ERR_VALUE(rc))
dev_err(dai->dev, "fail to close AUX PCM TX AFE port\n");
done:
kfree(dai_data);
snd_soc_unregister_dai(dai->dev);
mutex_unlock(&aux_pcm_mutex);
return 0;
}
示例2: wm8903_i2c_remove
static __devexit int wm8903_i2c_remove(struct i2c_client *client)
{
struct snd_soc_codec *codec = i2c_get_clientdata(client);
snd_soc_unregister_dai(&wm8903_dai);
snd_soc_unregister_codec(codec);
wm8903_set_bias_level(codec, SND_SOC_BIAS_OFF);
kfree(codec->private_data);
wm8903_codec = NULL;
wm8903_dai.dev = NULL;
return 0;
}
示例3: s3c64xx_i2sv4_dev_remove
static __devexit int s3c64xx_i2sv4_dev_remove(struct platform_device *pdev)
{
struct s3c_i2sv2_info *i2s = &s3c64xx_i2sv4;
struct resource *res;
snd_soc_unregister_dai(&pdev->dev);
clk_put(i2s->iis_cclk);
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
if (res)
release_mem_region(res->start, resource_size(res));
else
dev_warn(&pdev->dev, "Unable to get I2S SFR address\n");
return 0;
}
示例4: davinci_mcasp_remove
static int davinci_mcasp_remove(struct platform_device *pdev)
{
struct davinci_audio_dev *dev = dev_get_drvdata(&pdev->dev);
struct resource *mem;
snd_soc_unregister_dai(&pdev->dev);
pm_runtime_put_sync(&pdev->dev);
pm_runtime_disable(&pdev->dev);
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(mem->start, resource_size(mem));
if (dev->version == MCASP_VERSION_3)
kfree(dev->xrsrctl);
kfree(dev);
return 0;
}
示例5: fsl_ssi_remove
static int fsl_ssi_remove(struct platform_device *pdev)
{
struct fsl_ssi_private *ssi_private = dev_get_drvdata(&pdev->dev);
platform_device_unregister(ssi_private->pdev);
snd_soc_unregister_dai(&pdev->dev);
device_remove_file(&pdev->dev, &ssi_private->dev_attr);
free_irq(ssi_private->irq, ssi_private);
irq_dispose_mapping(ssi_private->irq);
kfree(ssi_private);
dev_set_drvdata(&pdev->dev, NULL);
return 0;
}
示例6: jz4740_i2s_dev_remove
static int __devexit jz4740_i2s_dev_remove(struct platform_device *pdev)
{
struct jz4740_i2s *i2s = platform_get_drvdata(pdev);
snd_soc_unregister_dai(&pdev->dev);
clk_put(i2s->clk_i2s);
clk_put(i2s->clk_aic);
iounmap(i2s->base);
release_mem_region(i2s->mem->start, resource_size(i2s->mem));
platform_set_drvdata(pdev, NULL);
kfree(i2s);
return 0;
}
示例7: davinci_mcasp_remove
static int davinci_mcasp_remove(struct platform_device *pdev)
{
struct davinci_audio_dev *dev = dev_get_drvdata(&pdev->dev);
struct resource *mem;
snd_soc_unregister_dai(&pdev->dev);
clk_disable(dev->clk);
clk_put(dev->clk);
dev->clk = NULL;
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(mem->start, (mem->end - mem->start) + 1);
kfree(dev);
return 0;
}
示例8: asoc_mcbsp_remove
static int asoc_mcbsp_remove(struct platform_device *pdev)
{
struct omap_mcbsp *mcbsp = platform_get_drvdata(pdev);
snd_soc_unregister_dai(&pdev->dev);
if (mcbsp->pdata->ops && mcbsp->pdata->ops->free)
mcbsp->pdata->ops->free(mcbsp->id);
omap_mcbsp_sysfs_remove(mcbsp);
clk_put(mcbsp->fclk);
platform_set_drvdata(pdev, NULL);
return 0;
}
示例9: mxs_saif_remove
static int __devexit mxs_saif_remove(struct platform_device *pdev)
{
struct resource *res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
struct mxs_saif *saif = platform_get_drvdata(pdev);
platform_device_unregister(saif->soc_platform_pdev);
snd_soc_unregister_dai(&pdev->dev);
iounmap(saif->base);
release_mem_region(res->start, resource_size(res));
free_irq(saif->irq, saif);
clk_put(saif->clk);
kfree(saif);
return 0;
}
示例10: au1xpsc_i2s_drvremove
static int __devexit au1xpsc_i2s_drvremove(struct platform_device *pdev)
{
struct au1xpsc_audio_data *wd = platform_get_drvdata(pdev);
struct resource *r = platform_get_resource(pdev, IORESOURCE_MEM, 0);
snd_soc_unregister_dai(&pdev->dev);
au_writel(0, I2S_CFG(wd));
au_sync();
au_writel(PSC_CTRL_DISABLE, PSC_CTRL(wd));
au_sync();
iounmap(wd->mmio);
release_mem_region(r->start, resource_size(r));
kfree(wd);
return 0;
}
示例11: davinci_mcasp_remove
static int davinci_mcasp_remove(struct platform_device *pdev)
{
struct snd_platform_data *pdata = pdev->dev.platform_data;
struct davinci_audio_dev *dev;
struct resource *mem;
snd_soc_unregister_dai(&davinci_mcasp_dai[pdata->op_mode]);
dev = davinci_mcasp_dai[pdata->op_mode].private_data;
clk_disable(dev->clk);
clk_put(dev->clk);
dev->clk = NULL;
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(mem->start, (mem->end - mem->start) + 1);
kfree(dev);
return 0;
}
示例12: s3c_pcm_dev_remove
static __devexit int s3c_pcm_dev_remove(struct platform_device *pdev)
{
struct s3c_pcm_info *pcm = &s3c_pcm[pdev->id];
struct resource *mem_res;
snd_soc_unregister_dai(&pdev->dev);
iounmap(pcm->regs);
mem_res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(mem_res->start, resource_size(mem_res));
clk_disable(pcm->cclk);
clk_disable(pcm->pclk);
clk_put(pcm->pclk);
clk_put(pcm->cclk);
return 0;
}
示例13: spdif_remove
static __devexit int spdif_remove(struct platform_device *pdev)
{
struct snd_soc_dai *dai = &samsung_spdif_dai;
struct samsung_spdif_info *spdif = &spdif_info;
struct resource *mem_res;
snd_soc_unregister_dai(dai);
iounmap(spdif->regs);
mem_res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(mem_res->start, resource_size(mem_res));
clk_disable(spdif->pclk);
clk_disable(spdif->sclk);
clk_put(spdif->pclk);
clk_put(spdif->sclk);
return 0;
}
示例14: twl6040_codec_remove
static int __devexit twl6040_codec_remove(struct platform_device *pdev)
{
struct twl6040_data *priv = snd_soc_codec_get_drvdata(twl6040_codec);
int audpwron = priv->audpwron;
int naudint = priv->naudint;
if (gpio_is_valid(audpwron))
gpio_free(audpwron);
if (naudint)
free_irq(naudint, twl6040_codec);
snd_soc_unregister_dai(&twl6040_dai);
snd_soc_unregister_codec(twl6040_codec);
kfree(twl6040_codec);
twl6040_codec = NULL;
return 0;
}
示例15: asoc_dmic_remove
static int __devexit asoc_dmic_remove(struct platform_device *pdev)
{
struct tegra_dmic *dmic = platform_get_drvdata(pdev);
struct resource *res;
tegra_dmic_debug_remove(dmic);
snd_soc_unregister_dai(&pdev->dev);
iounmap(dmic->io_base);
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
release_mem_region(res->start, resource_size(res));
if (dmic->parent)
clk_put(dmic->parent);
if (dmic->clk)
clk_put(dmic->clk);
kfree(dmic);
return 0;
}