ASoC: au1x: convert to platform drivers.
[safe/jmp/linux-2.6] / sound / soc / blackfin / bf5xx-ac97.c
index b1ed423..e693229 100644 (file)
@@ -277,28 +277,28 @@ static int bf5xx_ac97_resume(struct snd_soc_dai *dai)
        if (!dai->active)
                return 0;
 
-       ret = sport_set_multichannel(sport_handle, 16, 0x1F, 1);
+#if defined(CONFIG_SND_BF5XX_MULTICHAN_SUPPORT)
+       ret = sport_set_multichannel(sport, 16, 0x3FF, 1);
+#else
+       ret = sport_set_multichannel(sport, 16, 0x1F, 1);
+#endif
        if (ret) {
                pr_err("SPORT is busy!\n");
                return -EBUSY;
        }
 
-       ret = sport_config_rx(sport_handle, IRFS, 0xF, 0, (16*16-1));
+       ret = sport_config_rx(sport, IRFS, 0xF, 0, (16*16-1));
        if (ret) {
                pr_err("SPORT is busy!\n");
                return -EBUSY;
        }
 
-       ret = sport_config_tx(sport_handle, ITFS, 0xF, 0, (16*16-1));
+       ret = sport_config_tx(sport, ITFS, 0xF, 0, (16*16-1));
        if (ret) {
                pr_err("SPORT is busy!\n");
                return -EBUSY;
        }
 
-       if (dai->capture.active)
-               sport_rx_start(sport);
-       if (dai->playback.active)
-               sport_tx_start(sport);
        return 0;
 }
 
@@ -338,7 +338,11 @@ static int bf5xx_ac97_probe(struct platform_device *pdev,
                goto sport_err;
        }
        /*SPORT works in TDM mode to simulate AC97 transfers*/
+#if defined(CONFIG_SND_BF5XX_MULTICHAN_SUPPORT)
+       ret = sport_set_multichannel(sport_handle, 16, 0x3FF, 1);
+#else
        ret = sport_set_multichannel(sport_handle, 16, 0x1F, 1);
+#endif
        if (ret) {
                pr_err("SPORT is busy!\n");
                ret = -EBUSY;