[alsa-devel] [PATCH] ASoC: fsl-sai: convert to use regmap API for Freeacale SAI

Li.Xiubo at freescale.com Li.Xiubo at freescale.com
Thu Jan 23 11:32:57 CET 2014


> >  static int fsl_sai_set_dai_sysclk(struct snd_soc_dai *cpu_dai,
> >                 int clk_id, unsigned int freq, int dir)
> >  {
> > -       struct fsl_sai *sai = snd_soc_dai_get_drvdata(cpu_dai);
> >         int ret;
> >
> >         if (dir == SND_SOC_CLOCK_IN)
> >                 return 0;
> >
> > -       ret = clk_prepare_enable(sai->clk);
> > -       if (ret)
> > -               return ret;
> 
> The clock related change seems unrelated to the usage of regmap, right?
> 
 
The clock operations in the driver is only related to the module clock, and has
move to the regmap core and regmap core will to the same clock operations at 
proper time, since we are using:

+	sai->regmap = devm_regmap_init_mmio_clk(&pdev->dev,
+			"sai", base, &fsl_sai_regmap_config);


Thanks,

Best Regards,
Xiubo


More information about the Alsa-devel mailing list