From: Simran Rai <ssimran@broadcom.com>
To: Mark Brown <broonie@kernel.org>
Cc: Rob Herring <robh+dt@kernel.org>, Pawel Moll <pawel.moll@arm.com>,
"Mark Rutland" <mark.rutland@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>, Ray Jui <rjui@broadcom.com>,
Scott Branden <sbranden@broadcom.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
Lori Hikichi <lhikichi@broadcom.com>,
<devicetree@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<bcm-kernel-feedback-list@broadcom.com>,
<linux-kernel@vger.kernel.org>,
Arun Parameswaran <arunp@broadcom.com>,
<alsa-devel@alsa-project.org>
Subject: Re: [PATCH v4 2/3] ASoC: cygnus: Add Cygnus audio DAI driver
Date: Tue, 1 Dec 2015 18:17:54 -0800 [thread overview]
Message-ID: <565E54D2.50806@broadcom.com> (raw)
In-Reply-To: <20151122134440.GQ26072@sirena.org.uk>
On 11/22/2015 5:44 AM, Mark Brown wrote:
> On Mon, Nov 09, 2015 at 04:17:43PM -0800, Simran Rai wrote:
>
>> +#ifdef CONFIG_PM_SLEEP
>> +static int cygnus_ssp_suspend(struct snd_soc_dai *cpu_dai)
>> +{
>> + struct cygnus_aio_port *aio = cygnus_dai_get_portinfo(cpu_dai);
>> + struct cygnus_audio *cygaud = snd_soc_dai_get_drvdata(cpu_dai);
>> +
>> + audio_ssp_out_disable(aio);
>> + audio_ssp_in_disable(aio);
>> + if (cygaud->active_ports > 0)
>> + cygaud->active_ports--;
>> +
>> + return 0;
>> +}
>> +
>> +static int cygnus_ssp_resume(struct snd_soc_dai *cpu_dai)
>> +{
>> + return 0;
>> +}
> I'm a bit confused here - why do we need to disable things on suspend
> but not reenable them on resume? I'd expect that the core would have
> quiesced any streams that need to be suspended before we get as far as
> suspending the drivers.
>
> Please also remove empty functions.
>
> Now I check I see that I'm repeating the questions I had on my previous
> review:
>
> | Blank line between functions and remove empty functions. Though I'm not
> | clear why the result doesn't undo what the suspend did...
>
> Please don't ignore review comments.
Let me investigate this further and debug why the core did not
quiescence the streams.
>
>> + parent = clk_get_parent(cygaud->audio_clk[0]);
>> + if (IS_ERR(parent)) {
>> + error = PTR_ERR(parent);
>> + goto err_get_parent;
>> + }
>> +
>> + /* Set PLL VCO Frequency (Hz) to default */
>> + error = clk_set_rate(parent, DEFAULT_VCO);
>> + if (error) {
>> + dev_err(&pdev->dev,
>> + "%s Set PLL VCO rate failed: %d\n", __func__, error);
>> + goto err_get_parent;
>> + }
> I would expect any initialisationn of clocks beyond the ones that the
> device directly interacts with to be handled within the clock API
> configuration rather than in a specific driver, this avoids the driver
> being dependent on a particular system integration.
I will have to figure out a way to propagate the frequency from leaf clocks to the parent
clock. Will send out another patch with the fix.
Thanks,
Simran
next prev parent reply other threads:[~2015-12-02 2:17 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-10 0:17 [PATCH v4 0/3]ASoC: cygnus: Add audio support for Broadcom Cygnus SoC Simran Rai
2015-11-10 0:17 ` [PATCH v4 1/3] ASoC: cygnus: Add DT bindings for Broadcom Cygnus audio Simran Rai
2015-11-10 0:17 ` [PATCH v4 2/3] ASoC: cygnus: Add Cygnus audio DAI driver Simran Rai
2015-11-22 13:44 ` Mark Brown
2015-12-02 2:17 ` Simran Rai [this message]
2015-12-02 10:45 ` Mark Brown
2015-11-10 0:17 ` [PATCH v4 3/3] ASoC: cygnus: Add Cygnus audio DMA driver Simran Rai
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=565E54D2.50806@broadcom.com \
--to=ssimran@broadcom.com \
--cc=alsa-devel@alsa-project.org \
--cc=arunp@broadcom.com \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=galak@codeaurora.org \
--cc=ijc+devicetree@hellion.org.uk \
--cc=lgirdwood@gmail.com \
--cc=lhikichi@broadcom.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=pawel.moll@arm.com \
--cc=perex@perex.cz \
--cc=rjui@broadcom.com \
--cc=robh+dt@kernel.org \
--cc=sbranden@broadcom.com \
--cc=tiwai@suse.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
Powered by JetHome