From: Jarkko Nikula <jhnikula@gmail.com>
To: alsa-devel@alsa-project.org
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>,
Liam Girdwood <lrg@slimlogic.co.uk>
Subject: [PATCH] ASoC: omap: rx51: Enable McBSP2 sidetone
Date: Wed, 9 Mar 2011 11:25:00 +0200 [thread overview]
Message-ID: <1299662700-25220-1-git-send-email-jhnikula@gmail.com> (raw)
McBSP sidetone is needed in telephony applications. McBSP sidetone is a
configurable FIR filter that forms a loopback from McBSP input to output.
This patch enables the McBSP2 sidetone ALSA controls so that it can be used
on Nokia RX-51/N900.
Sidetone feature can be tested with following commands:
(set up codec input and output paths)
# Enable and configure sidetone
amixer -D hw:0 set 'McBSP2 Sidetone' on
amixer set -D hw:0 'McBSP2 Sidetone Channel 0' 32767
echo 32767 >/sys/devices/platform/omap-mcbsp.2/st_taps
# Do not loop audio via CPU
arecord -f dat >/dev/null |aplay /dev/zero
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
---
sound/soc/omap/rx51.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/sound/soc/omap/rx51.c b/sound/soc/omap/rx51.c
index 055e447..d098622 100644
--- a/sound/soc/omap/rx51.c
+++ b/sound/soc/omap/rx51.c
@@ -331,6 +331,10 @@ static int rx51_aic34_init(struct snd_soc_pcm_runtime *rtd)
return err;
snd_soc_limit_volume(codec, "TPA6130A2 Headphone Playback Volume", 42);
+ err = omap_mcbsp_st_add_controls(codec, 1);
+ if (err < 0)
+ return err;
+
snd_soc_dapm_sync(dapm);
/* AV jack detection */
--
1.7.2.3
next reply other threads:[~2011-03-09 9:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-09 9:25 Jarkko Nikula [this message]
2011-03-09 10:11 ` [PATCH] ASoC: omap: rx51: Enable McBSP2 sidetone Mark Brown
2011-03-09 11:55 ` Liam Girdwood
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=1299662700-25220-1-git-send-email-jhnikula@gmail.com \
--to=jhnikula@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=lrg@slimlogic.co.uk \
/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).