MLK-15071: ASoC: fsl: imx-ak4497: Fix clk for 384KHz and 786KHz
With the current multipliers SAI isn't able to derive a correct bitclk. e.g: When playing at 786Khz with current multiplier MCLK = 22579200, requested freq 22579200 but SAI wants: MCLK = (DIV + 1) * 2 * freq [SAI TCR2], so an acceptable solution is to add a 2x factor to mclk. Signed-off-by: Viorel Suman <viorel.suman@nxp.com>
This commit is contained in:
parent
1165041e06
commit
94b4ed3160
|
@ -544,16 +544,17 @@ static int ak4497_hw_params(struct snd_pcm_substream *substream,
|
|||
dfs |= AK4497_DFS_96KHZ;
|
||||
dfs2 |= AK4497_DFS2_48KHZ;
|
||||
break;
|
||||
|
||||
case 176400:
|
||||
case 192000:
|
||||
dfs |= AK4497_DFS_192KHZ;
|
||||
dfs2 |= AK4497_DFS2_48KHZ;
|
||||
break;
|
||||
case 352800:
|
||||
case 384000:
|
||||
dfs |= AK4497_DFS_384KHZ;
|
||||
dfs2 |= AK4497_DFS2_384KHZ;
|
||||
break;
|
||||
case 705600:
|
||||
case 768000:
|
||||
dfs |= AK4497_DFS_768KHZ;
|
||||
dfs2 |= AK4497_DFS2_384KHZ;
|
||||
|
|
|
@ -45,8 +45,8 @@ static const struct imx_ak4497_fs_mul {
|
|||
{ .min = 44100, .max = 48000, .mul = 512 }, /* Normal */
|
||||
{ .min = 88200, .max = 96000, .mul = 256 }, /* Double */
|
||||
{ .min = 176400, .max = 192000, .mul = 128 }, /* Quad */
|
||||
{ .min = 384000, .max = 384000, .mul = 64 }, /* Oct */
|
||||
{ .min = 768000, .max = 768000, .mul = 32 }, /* Hex */
|
||||
{ .min = 352800, .max = 384000, .mul = 2*64 }, /* Oct */
|
||||
{ .min = 705600, .max = 768000, .mul = 2*32 }, /* Hex */
|
||||
};
|
||||
|
||||
static bool imx_ak4497_is_dsd(struct snd_pcm_hw_params *params)
|
||||
|
|
Loading…
Reference in a new issue