From: Sylwester Nawrocki <s.nawrocki@samsung.com>
To: Lars-Peter Clausen <lars@metafoo.de>
Cc: Mark Brown <broonie@kernel.org>,
devicetree@vger.kernel.org, alsa-devel@alsa-project.org,
linux-samsung-soc@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
Chen Zhen <zhen1.chen@samsung.com>
Subject: Re: [alsa-devel] [PATCH 2/2] ASoC: samsung: Add machine driver for odroidx2
Date: Fri, 04 Jul 2014 13:24:36 +0200 [thread overview]
Message-ID: <53B68EF4.1090101@samsung.com> (raw)
In-Reply-To: <53B68B96.9010708@metafoo.de>
On 04/07/14 13:10, Lars-Peter Clausen wrote:
> On 07/04/2014 01:04 PM, Sylwester Nawrocki wrote:
>> On 22/05/14 20:53, Mark Brown wrote:
>>>> + ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S
>>>>> + | SND_SOC_DAIFMT_NB_NF
>>>>> + | SND_SOC_DAIFMT_CBM_CFM);
>>>>> + if (ret < 0)
>>>>> + return ret;
>>>>> +
>>>>> + ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S
>>>>> + | SND_SOC_DAIFMT_NB_NF
>>>>> + | SND_SOC_DAIFMT_CBM_CFM);
>>>>> + if (ret < 0)
>>>>> + return ret;
>>>
>>> These are constant, set these in the dai_link.
>>
>> set_fmt also sets master/slave mode of the I2S DAI, after I moved
>> this into the cpu_dai link data structure after suspend/resume cycle
>> the I2S IP block is not being properly re-configured. Should the
>> format setting be added in resume_post callback, or is there any
>> other preferred way ? Similarly the syclk settings are being lost
>> over suspend/resume cycle and nothing restores them.
>
> The I2S driver should save and restore it's register during suspend/resume.
OK, thanks. I checked the I2S driver does it, but only when dai->active
flags is set [1]. However, during system resume this flag is not set
(in situation where playback or capture wasn't active right before
system suspend). Is the dai->active test wrong in that driver then ?
I'm not sure if it could just be removed.
[1] http://lxr.free-electrons.com/source/sound/soc/samsung/i2s.c#L913
--
Regards,
Sylwester
WARNING: multiple messages have this Message-ID (diff)
From: s.nawrocki@samsung.com (Sylwester Nawrocki)
To: linux-arm-kernel@lists.infradead.org
Subject: [alsa-devel] [PATCH 2/2] ASoC: samsung: Add machine driver for odroidx2
Date: Fri, 04 Jul 2014 13:24:36 +0200 [thread overview]
Message-ID: <53B68EF4.1090101@samsung.com> (raw)
In-Reply-To: <53B68B96.9010708@metafoo.de>
On 04/07/14 13:10, Lars-Peter Clausen wrote:
> On 07/04/2014 01:04 PM, Sylwester Nawrocki wrote:
>> On 22/05/14 20:53, Mark Brown wrote:
>>>> + ret = snd_soc_dai_set_fmt(codec_dai, SND_SOC_DAIFMT_I2S
>>>>> + | SND_SOC_DAIFMT_NB_NF
>>>>> + | SND_SOC_DAIFMT_CBM_CFM);
>>>>> + if (ret < 0)
>>>>> + return ret;
>>>>> +
>>>>> + ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_I2S
>>>>> + | SND_SOC_DAIFMT_NB_NF
>>>>> + | SND_SOC_DAIFMT_CBM_CFM);
>>>>> + if (ret < 0)
>>>>> + return ret;
>>>
>>> These are constant, set these in the dai_link.
>>
>> set_fmt also sets master/slave mode of the I2S DAI, after I moved
>> this into the cpu_dai link data structure after suspend/resume cycle
>> the I2S IP block is not being properly re-configured. Should the
>> format setting be added in resume_post callback, or is there any
>> other preferred way ? Similarly the syclk settings are being lost
>> over suspend/resume cycle and nothing restores them.
>
> The I2S driver should save and restore it's register during suspend/resume.
OK, thanks. I checked the I2S driver does it, but only when dai->active
flags is set [1]. However, during system resume this flag is not set
(in situation where playback or capture wasn't active right before
system suspend). Is the dai->active test wrong in that driver then ?
I'm not sure if it could just be removed.
[1] http://lxr.free-electrons.com/source/sound/soc/samsung/i2s.c#L913
--
Regards,
Sylwester
next prev parent reply other threads:[~2014-07-04 11:24 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-22 11:55 [PATCH 1/2] doc: dt bindings: Document Odroid X2/U3 audio subsystem bindings Sylwester Nawrocki
2014-05-22 11:55 ` Sylwester Nawrocki
2014-05-22 11:55 ` [PATCH 2/2] ASoC: samsung: Add machine driver for odroidx2 Sylwester Nawrocki
2014-05-22 11:55 ` Sylwester Nawrocki
2014-05-22 18:53 ` Mark Brown
2014-05-22 18:53 ` Mark Brown
2014-05-23 8:44 ` Sylwester Nawrocki
2014-05-23 8:44 ` Sylwester Nawrocki
2014-05-23 11:05 ` Mark Brown
2014-05-23 11:05 ` Mark Brown
2014-07-04 11:04 ` Sylwester Nawrocki
2014-07-04 11:04 ` Sylwester Nawrocki
2014-07-04 11:10 ` [alsa-devel] " Lars-Peter Clausen
2014-07-04 11:10 ` Lars-Peter Clausen
2014-07-04 11:24 ` Sylwester Nawrocki [this message]
2014-07-04 11:24 ` Sylwester Nawrocki
2014-07-04 11:28 ` Lars-Peter Clausen
2014-07-04 11:28 ` Lars-Peter Clausen
2014-05-22 18:46 ` [PATCH 1/2] doc: dt bindings: Document Odroid X2/U3 audio subsystem bindings Mark Brown
2014-05-22 18:46 ` Mark Brown
2014-05-23 9:54 ` Sylwester Nawrocki
2014-05-23 9:54 ` Sylwester Nawrocki
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=53B68EF4.1090101@samsung.com \
--to=s.nawrocki@samsung.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=lars@metafoo.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=zhen1.chen@samsung.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.