From: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
To: alsa-devel@alsa-project.org
Cc: tiwai@suse.de, broonie@kernel.org,
Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>,
irina.tirdea@intel.com
Subject: [PATCH 06/17] ASoC: Intel: atom: enable configuration of SSP0
Date: Fri, 12 Aug 2016 16:27:49 -0500 [thread overview]
Message-ID: <1471037280-17433-7-git-send-email-pierre-louis.bossart@linux.intel.com> (raw)
In-Reply-To: <1471037280-17433-1-git-send-email-pierre-louis.bossart@linux.intel.com>
Existing code used SSP2, make selection of SSP id
dependent on port name. This is required when the
machine driver uses non-default settings
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
sound/soc/intel/atom/sst-atom-controls.c | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/sound/soc/intel/atom/sst-atom-controls.c b/sound/soc/intel/atom/sst-atom-controls.c
index 28eea12..0838478 100644
--- a/sound/soc/intel/atom/sst-atom-controls.c
+++ b/sound/soc/intel/atom/sst-atom-controls.c
@@ -935,17 +935,26 @@ void sst_fill_ssp_defaults(struct snd_soc_dai *dai)
int send_ssp_cmd(struct snd_soc_dai *dai, const char *id, bool enable)
{
struct sst_data *drv = snd_soc_dai_get_drvdata(dai);
- const struct sst_ssp_config *config;
+ int ssp_id;
dev_info(dai->dev, "Enter: enable=%d port_name=%s\n", enable, id);
+ if (strcmp(id, "ssp0-port") == 0)
+ ssp_id = SSP_MODEM;
+ else if (strcmp(id, "ssp2-port") == 0)
+ ssp_id = SSP_CODEC;
+ else {
+ dev_dbg(dai->dev, "port %s is not supported\n", id);
+ return -1;
+ }
+
SST_FILL_DEFAULT_DESTINATION(drv->ssp_cmd.header.dst);
drv->ssp_cmd.header.command_id = SBA_HW_SET_SSP;
drv->ssp_cmd.header.length = sizeof(struct sst_cmd_sba_hw_set_ssp)
- sizeof(struct sst_dsp_header);
- config = &sst_ssp_configs;
- dev_dbg(dai->dev, "ssp_id: %u\n", config->ssp_id);
+ drv->ssp_cmd.selection = ssp_id;
+ dev_dbg(dai->dev, "ssp_id: %u\n", ssp_id);
if (enable)
drv->ssp_cmd.switch_state = SST_SWITCH_ON;
--
2.5.0
next prev parent reply other threads:[~2016-08-12 21:28 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-12 21:27 [PATCH 00/17] Baytrail audio fixes Pierre-Louis Bossart
2016-08-12 21:27 ` [PATCH 01/17] ASoC: Intel: bytcr-rt5640: add Asus T100TAF quirks Pierre-Louis Bossart
2016-08-15 14:16 ` Applied "ASoC: Intel: bytcr-rt5640: add Asus T100TAF quirks" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 02/17] ASoC: Intel: bytcr_rt5640: quirk for mono speaker Pierre-Louis Bossart
2016-08-15 14:16 ` Applied "ASoC: Intel: bytcr_rt5640: quirk for mono speaker" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 03/17] ASoC: Intel: bytcr_rt5640: enable differential mic quirk Pierre-Louis Bossart
2016-08-15 14:16 ` Applied "ASoC: Intel: bytcr_rt5640: enable differential mic quirk" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 04/17] ASoC: Intel: Atom: auto-detection of Baytrail-CR Pierre-Louis Bossart
2016-08-15 14:16 ` Applied "ASoC: Intel: Atom: auto-detection of Baytrail-CR" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 05/17] ASoC: Intel: Atom: add definitions for modem/SSP0 interface Pierre-Louis Bossart
2016-08-15 14:16 ` Applied "ASoC: Intel: Atom: add definitions for modem/SSP0 interface" to the asoc tree Mark Brown
2016-08-12 21:27 ` Pierre-Louis Bossart [this message]
2016-08-15 14:16 ` Applied "ASoC: Intel: atom: enable configuration of SSP0" " Mark Brown
2016-08-12 21:27 ` [PATCH 07/17] ASoC: Intel: bytcr_rt5640: add SSP2_AIF2 routing Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: add SSP2_AIF2 routing" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 08/17] ASoC: Intel: bytcr_rt56040: additional routing quirks Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt56040: additional routing quirks" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 09/17] ASoC: Intel: bytcr_rt5640: fix dai/clock setup for SSP0 routing Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: fix dai/clock setup for SSP0 routing" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 10/17] ASoC: Intel: bytcr_rt5640: default routing and quirks on Baytrail-CR Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: default routing and quirks on Baytrail-CR" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 11/17] ASoC: Intel: bytcr_rt5640: add IN3 map Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: add IN3 map" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 12/17] ASoC: rt5640: add internal clock source support Pierre-Louis Bossart
2016-08-15 14:11 ` Applied "ASoC: rt5640: add internal clock source support" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 13/17] clk: x86: Add Atom PMC platform clocks Pierre-Louis Bossart
2016-08-12 21:27 ` [PATCH 14/17] ASoC: Intel: bytcr_rt5640: add MCLK support Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: add MCLK support" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 15/17] AsoC: Intel: Add quirks for MinnowBoard MAX Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "AsoC: Intel: Add quirks for MinnowBoard MAX" to the asoc tree Mark Brown
2016-08-12 21:27 ` [PATCH 16/17] ASoC: bytcr_rt5640: Add quirk for Teclast X98 Air 3G tablet Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: Add quirk for Teclast X98 Air 3G tablet" to the asoc tree Mark Brown
2016-08-12 21:28 ` [PATCH 17/17] ASoC: Intel: bytcr_rt5640: log quirks Pierre-Louis Bossart
2016-08-15 14:15 ` Applied "ASoC: Intel: bytcr_rt5640: log quirks" to the asoc tree Mark Brown
2016-08-15 14:56 ` [PATCH 00/17] Baytrail audio fixes Pierre-Louis Bossart
2016-08-17 10:50 ` Mark Brown
2016-08-17 18:26 ` Pierre-Louis Bossart
2016-08-18 9:29 ` Mark Brown
2016-08-18 16:22 ` Pierre-Louis Bossart
2016-08-18 16:35 ` Mark Brown
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=1471037280-17433-7-git-send-email-pierre-louis.bossart@linux.intel.com \
--to=pierre-louis.bossart@linux.intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=irina.tirdea@intel.com \
--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;
as well as URLs for NNTP newsgroup(s).