From: "Thomas Niederprüm" <niederp@physik.uni-kl.de>
To: peter.ujfalusi@ti.com, jarkko.nikula@bitmer.com
Cc: linux-omap@vger.kernel.org, alsa-devel@alsa-project.org,
"Thomas Niederprüm" <niederp@physik.uni-kl.de>
Subject: [PATCH] ASoC: OMAP: mcbsp: ensure that CLKX and CLKR are not used as ouput pins when they are used as input clock for the SRG.
Date: Thu, 15 Jan 2015 23:28:21 +0100 [thread overview]
Message-ID: <1421360901-20671-1-git-send-email-niederp@physik.uni-kl.de> (raw)
This patch fixes faulty behaviour in a setup where the input clock for
the SRG is fed through the CLKR pin but the McBSP is configured to be
master (SND_SOC_DAIFMT_CBS_CFS). In that case of course CLKR must not be
configured as output pin. Otherwise the input clock is messed up
horribly. The same reasoning applies if CLKX is configured as input for
the SRG.
Signed-off-by: Thomas Niederprüm <niederp@physik.uni-kl.de>
---
sound/soc/omap/omap-mcbsp.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index bd3ef2a..c89f562 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -530,8 +530,12 @@ static int omap_mcbsp_dai_set_dai_sysclk(struct snd_soc_dai *cpu_dai,
case OMAP_MCBSP_SYSCLK_CLKX_EXT:
regs->srgr2 |= CLKSM;
+ regs->pcr0 |= SCLKME;
+ regs->pcr0 &= ~CLKXM;
+ break;
case OMAP_MCBSP_SYSCLK_CLKR_EXT:
regs->pcr0 |= SCLKME;
+ regs->pcr0 &= ~CLKRM;
break;
default:
err = -ENODEV;
--
2.1.1
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next reply other threads:[~2015-01-15 22:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-15 22:28 Thomas Niederprüm [this message]
2015-01-16 9:09 ` [PATCH] ASoC: OMAP: mcbsp: ensure that CLKX and CLKR are not used as ouput pins when they are used as input clock for the SRG Jarkko Nikula
2015-01-16 9:15 ` Peter Ujfalusi
2015-01-16 10:15 ` Thomas Niederprüm
2015-01-16 12:42 ` Peter Ujfalusi
2015-01-16 15:06 ` Thomas Niederprüm
2015-01-19 7:44 ` Peter Ujfalusi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1421360901-20671-1-git-send-email-niederp@physik.uni-kl.de \
--to=niederp@physik.uni-kl.de \
--cc=alsa-devel@alsa-project.org \
--cc=jarkko.nikula@bitmer.com \
--cc=linux-omap@vger.kernel.org \
--cc=peter.ujfalusi@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).