10 Jul
2015
10 Jul
'15
7 p.m.
On Mon, Jun 22, 2015 at 04:31:07PM +0200, Arnaud Pouliquen wrote:
- if (clk_id != 0)
return -EINVAL;
- player->mclk = freq;
- return clk_set_rate(player->clk, freq);
You should really only set the mclk after clk_set_rate() succeeds but practically it probably doesn't matter.
- case SND_SOC_DAIFMT_IB_NF:
SET_UNIPERIF_I2S_FMT_LR_POL_LOW(player);
SET_UNIPERIF_I2S_FMT_SCLK_EDGE_FALLING(player);
break;
- case SND_SOC_DAIFMT_IB_IF:
SET_UNIPERIF_I2S_FMT_LR_POL_HIG(player);
SET_UNIPERIF_I2S_FMT_SCLK_EDGE_FALLING(player);
- }
Missing break in that last case.
- player->clk = of_clk_get(pdev->dev.of_node, 0);
- if (IS_ERR(player->clk))
ret = (int)PTR_ERR(player->clk);
You shouldn't need the cast here.