From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: Graeme Gregory <graeme@openmoko.org>,
alsa-devel@alsa-project.org,
Mark Brown <broonie@opensource.wolfsonmicro.com>
Subject: [PATCH 08/10] soc - neo1973_wm8753 - Convert to bulk DAPM registration APIs
Date: Tue, 13 May 2008 12:40:13 +0100 [thread overview]
Message-ID: <1210678815-9755-8-git-send-email-broonie@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <1210678815-9755-7-git-send-email-broonie@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Graeme Gregory <graeme@openmoko.org>
---
sound/soc/s3c24xx/neo1973_wm8753.c | 17 ++++++-----------
1 files changed, 6 insertions(+), 11 deletions(-)
diff --git a/sound/soc/s3c24xx/neo1973_wm8753.c b/sound/soc/s3c24xx/neo1973_wm8753.c
index e469186..79c5027 100644
--- a/sound/soc/s3c24xx/neo1973_wm8753.c
+++ b/sound/soc/s3c24xx/neo1973_wm8753.c
@@ -425,8 +425,7 @@ static const struct snd_soc_dapm_widget wm8753_dapm_widgets[] = {
};
-/* example machine audio_mapnections */
-static const char *audio_map[][3] = {
+static const struct snd_soc_dapm_route dapm_routes[] = {
/* Connections to the lm4857 amp */
{"Audio Out", NULL, "LOUT1"},
@@ -449,8 +448,6 @@ static const char *audio_map[][3] = {
/* Connect the ALC pins */
{"ACIN", NULL, "ACOP"},
-
- {NULL, NULL, NULL},
};
static const char *lm4857_mode[] = {
@@ -526,8 +523,8 @@ static int neo1973_wm8753_init(struct snd_soc_codec *codec)
set_scenario_endpoints(codec, NEO_AUDIO_OFF);
/* Add neo1973 specific widgets */
- for (i = 0; i < ARRAY_SIZE(wm8753_dapm_widgets); i++)
- snd_soc_dapm_new_control(codec, &wm8753_dapm_widgets[i]);
+ snd_soc_dapm_new_controls(codec, wm8753_dapm_widgets,
+ ARRAY_SIZE(wm8753_dapm_widgets));
/* add neo1973 specific controls */
for (i = 0; i < ARRAY_SIZE(wm8753_neo1973_controls); i++) {
@@ -538,11 +535,9 @@ static int neo1973_wm8753_init(struct snd_soc_codec *codec)
return err;
}
- /* set up neo1973 specific audio path audio_mapnects */
- for (i = 0; audio_map[i][0] != NULL; i++) {
- snd_soc_dapm_connect_input(codec, audio_map[i][0],
- audio_map[i][1], audio_map[i][2]);
- }
+ /* set up neo1973 specific audio routes */
+ err = snd_soc_dapm_add_routes(codec, dapm_routes,
+ ARRAY_SIZE(dapm_routes));
snd_soc_dapm_sync_endpoints(codec);
return 0;
--
1.5.5.1
next prev parent reply other threads:[~2008-05-13 11:40 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-13 11:40 [PATCH 01/10] ASoC: build fix for snd_soc_info_bool_ext Mark Brown
2008-05-13 11:40 ` [PATCH 02/10] soc - DAPM - Add bulk control registration Mark Brown
2008-05-13 11:40 ` [PATCH 03/10] soc - DAPM - Bulk route registration Mark Brown
2008-05-13 11:40 ` [PATCH 04/10] soc - Convert Wolfson codec drivers to use bulk DAPM registration Mark Brown
2008-05-13 11:40 ` [PATCH 05/10] soc - tlv320aic3x - Convert to use bulk registration APIs Mark Brown
2008-05-13 11:40 ` [PATCH 06/10] soc - Zaurus - Convert to bulk DAPM " Mark Brown
2008-05-13 11:40 ` [PATCH 07/10] soc - eti_b1_wm8731 - Convert to use bulk DAPM control registration Mark Brown
2008-05-13 11:40 ` Mark Brown [this message]
2008-05-13 11:40 ` [PATCH 09/10] soc - davinci-evm - Update for bulk DAPM registration APIs Mark Brown
2008-05-13 11:40 ` [PATCH 10/10] soc - n810 " Mark Brown
2008-05-13 12:34 ` [PATCH 05/10] soc - tlv320aic3x - Convert to use bulk " Jarkko Nikula
2008-05-13 12:43 ` Mark Brown
2008-05-13 13:20 ` Jarkko Nikula
2008-05-13 13:28 ` Mark Brown
2008-05-13 13:33 ` [PATCH 01/10] ASoC: build fix for snd_soc_info_bool_ext Takashi Iwai
2008-05-13 13:41 ` Mark Brown
2008-05-13 13:48 ` Takashi Iwai
2008-05-13 14:08 ` Mark Brown
2008-05-13 15:21 ` Takashi Iwai
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=1210678815-9755-8-git-send-email-broonie@opensource.wolfsonmicro.com \
--to=broonie@opensource.wolfsonmicro.com \
--cc=alsa-devel@alsa-project.org \
--cc=graeme@openmoko.org \
--cc=tiwai@suse.de \
/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