Message ID | 1600251387-1863-4-git-send-email-shengjiu.wang@nxp.com (mailing list archive) |
---|---|
State | Not Applicable |
Headers | show |
Series | ASoC: fsl_sai: update the register list | expand |
Context | Check | Description |
---|---|---|
snowpatch_ozlabs/apply_patch | success | Successfully applied on branch powerpc/merge (27e2fbcd815a088d7d83c7158f76b6e95ab07c50) |
snowpatch_ozlabs/build-ppc64le | warning | Upstream build failed, couldn't test patch |
snowpatch_ozlabs/build-ppc64be | warning | Upstream build failed, couldn't test patch |
snowpatch_ozlabs/build-ppc64e | warning | Upstream build failed, couldn't test patch |
snowpatch_ozlabs/build-pmac32 | warning | Upstream build failed, couldn't test patch |
snowpatch_ozlabs/checkpatch | success | total: 0 errors, 0 warnings, 0 checks, 13 lines checked |
snowpatch_ozlabs/needsstable | success | Patch has no Fixes tags |
On Wed, Sep 16, 2020 at 06:16:27PM +0800, Shengjiu Wang wrote: > SAI support select MCLK direction with version.major > 3 > and version.minor > 1, the default direction is input, > set it to be output according to DT property. > > Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Acked-by: Nicolin Chen <nicoleotsuka@gmail.com> > --- > sound/soc/fsl/fsl_sai.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c > index 738b4dda7847..5117c1cd5682 100644 > --- a/sound/soc/fsl/fsl_sai.c > +++ b/sound/soc/fsl/fsl_sai.c > @@ -1117,6 +1117,13 @@ static int fsl_sai_probe(struct platform_device *pdev) > if (ret < 0) > dev_warn(&pdev->dev, "Error reading SAI version: %d\n", ret); > > + /* Select MCLK direction */ > + if (of_find_property(np, "fsl,sai-mclk-direction-output", NULL) && > + sai->verid.major >= 3 && sai->verid.minor >= 1) { > + regmap_update_bits(sai->regmap, FSL_SAI_MCTL, > + FSL_SAI_MCTL_MCLK_EN, FSL_SAI_MCTL_MCLK_EN); > + } > + > pm_runtime_enable(&pdev->dev); > regcache_cache_only(sai->regmap, true); > > -- > 2.27.0 >
diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index 738b4dda7847..5117c1cd5682 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -1117,6 +1117,13 @@ static int fsl_sai_probe(struct platform_device *pdev) if (ret < 0) dev_warn(&pdev->dev, "Error reading SAI version: %d\n", ret); + /* Select MCLK direction */ + if (of_find_property(np, "fsl,sai-mclk-direction-output", NULL) && + sai->verid.major >= 3 && sai->verid.minor >= 1) { + regmap_update_bits(sai->regmap, FSL_SAI_MCTL, + FSL_SAI_MCTL_MCLK_EN, FSL_SAI_MCTL_MCLK_EN); + } + pm_runtime_enable(&pdev->dev); regcache_cache_only(sai->regmap, true);
SAI support select MCLK direction with version.major > 3 and version.minor > 1, the default direction is input, set it to be output according to DT property. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> --- sound/soc/fsl/fsl_sai.c | 7 +++++++ 1 file changed, 7 insertions(+)