linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: zhangfei.gao@gmail.com (zhangfei gao)
To: linux-arm-kernel@lists.infradead.org
Subject: [alsa-devel] [PATCH v1 3/5] ASOC: mmp: add sspa support
Date: Fri, 8 Jun 2012 21:28:12 +0800	[thread overview]
Message-ID: <CAMj5Bkg7cSaEHm+mz-9ah85J83rQFiw1QNxMP5RBa8BiYJhoqw@mail.gmail.com> (raw)
In-Reply-To: <20120607221019.GA14525@opensource.wolfsonmicro.com>

On Fri, Jun 8, 2012 at 6:10 AM, Mark Brown
<broonie@opensource.wolfsonmicro.com> wrote:
> On Mon, Jun 04, 2012 at 02:37:29PM +0800, Zhangfei Gao wrote:
>> The SSPA is a configurable multi-channel audio serial (TDM) interface.
>> It's configurable at runtime to support up to 128 channels and the
>> number of bits per sample: 8, 12, 16, 20, 24 and 32 bits. It also
>> support stereo format: I2S, left-justified or right-justified.
>
> This looks mostly good (though you want to check your indentation a bit)
> but...
>
>> +static int __init mmp_sspa_modinit(void)
>> +{
>> + ? ? audio_clk = clk_get(NULL, "mmp-audio");
>> + ? ? if (IS_ERR(audio_clk))
>> + ? ? ? ? ? ? return PTR_ERR(audio_clk);
>> +
>> + ? ? sysclk = clk_get(NULL, "mmp-sysclk");
>> + ? ? if (IS_ERR(sysclk))
>> + ? ? ? ? ? ? return PTR_ERR(sysclk);
>> + ? ? clk_enable(audio_clk);
>
> You should be doing this stuff from the driver, not from the module init
> (and ideally you'd be managing the audio clock dynamically). ?Even if
> it's the same clock every time in current silicon it's still a good idea
> to do this from a quality of implementation point of view.

Thanks, will remove the module init, and move clk staff to probe.
However, dynamically control audio_clk make audio subsystem works abnormally.

  reply	other threads:[~2012-06-08 13:28 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-04  6:37 [PATCH v1 0/5] mmp audio support Zhangfei Gao
2012-06-04  6:37 ` [PATCH v1 1/5] dmaengine: mmp_tdma: add mmp tdma support Zhangfei Gao
2012-06-07  9:22   ` Vinod Koul
2012-06-07 10:39     ` [alsa-devel] " zhangfei gao
2012-06-07 11:30       ` Vinod Koul
2012-06-07 13:33         ` zhangfei gao
2012-06-04  6:37 ` [PATCH v1 2/5] ASoC: mmp: add audio dma support Zhangfei Gao
2012-06-07  9:24   ` Vinod Koul
2012-06-07  9:59     ` [alsa-devel] " zhangfei gao
2012-06-07 10:05       ` Vinod Koul
2012-06-07 10:44         ` zhangfei gao
2012-06-07 11:20           ` Vinod Koul
2012-06-07 13:17             ` zhangfei gao
2012-06-04  6:37 ` [PATCH v1 3/5] ASOC: mmp: add sspa support Zhangfei Gao
2012-06-07 22:10   ` Mark Brown
2012-06-08 13:28     ` zhangfei gao [this message]
2012-06-04  6:37 ` [PATCH v1 4/5] ASoC: add mmp brownstone support Zhangfei Gao
2012-06-07 22:13   ` Mark Brown
2012-06-08 13:24     ` [alsa-devel] " zhangfei gao
2012-06-04  6:37 ` [PATCH v1 5/5] ASoC: add ttc-dkb machine support Zhangfei Gao

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=CAMj5Bkg7cSaEHm+mz-9ah85J83rQFiw1QNxMP5RBa8BiYJhoqw@mail.gmail.com \
    --to=zhangfei.gao@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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).