summaryrefslogtreecommitdiff
path: root/sound/soc/samsung/s3c2412-i2s.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/soc/samsung/s3c2412-i2s.c')
-rw-r--r--sound/soc/samsung/s3c2412-i2s.c21
1 files changed, 4 insertions, 17 deletions
diff --git a/sound/soc/samsung/s3c2412-i2s.c b/sound/soc/samsung/s3c2412-i2s.c
index e9bb5d7a71ee..08c059be9104 100644
--- a/sound/soc/samsung/s3c2412-i2s.c
+++ b/sound/soc/samsung/s3c2412-i2s.c
@@ -120,11 +120,11 @@ static int s3c2412_i2s_hw_params(struct snd_pcm_substream *substream,
iismod = readl(i2s->regs + S3C2412_IISMOD);
pr_debug("%s: r: IISMOD: %x\n", __func__, iismod);
- switch (params_format(params)) {
- case SNDRV_PCM_FORMAT_S8:
+ switch (params_width(params)) {
+ case 8:
iismod |= S3C2412_IISMOD_8BIT;
break;
- case SNDRV_PCM_FORMAT_S16_LE:
+ case 16:
iismod &= ~S3C2412_IISMOD_8BIT;
break;
}
@@ -179,27 +179,14 @@ static int s3c2412_iis_dev_probe(struct platform_device *pdev)
}
ret = samsung_asoc_dma_platform_register(&pdev->dev);
- if (ret) {
+ if (ret)
pr_err("failed to register the DMA: %d\n", ret);
- goto err;
- }
- return 0;
-err:
- snd_soc_unregister_component(&pdev->dev);
return ret;
}
-static int s3c2412_iis_dev_remove(struct platform_device *pdev)
-{
- samsung_asoc_dma_platform_unregister(&pdev->dev);
- snd_soc_unregister_component(&pdev->dev);
- return 0;
-}
-
static struct platform_driver s3c2412_iis_driver = {
.probe = s3c2412_iis_dev_probe,
- .remove = s3c2412_iis_dev_remove,
.driver = {
.name = "s3c2412-iis",
.owner = THIS_MODULE,