All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Raffaele Recalcati <lamiaposta71@gmail.com>
Cc: davinci-linux-open-source@linux.davincidsp.com,
	alsa-devel@alsa-project.org,
	Troy Kisky <troy.kisky@boundarydevices.com>,
	Davide Bonfanti <davide.bonfanti@bticino.it>,
	Raffaele Recalcati <raffaele.recalcati@bticino.it>,
	Chaithrika U S <chaithrika@ti.com>,
	Liam Girdwood <lrg@slimlogic.co.uk>
Subject: Re: [PATCH 2/3] ASoC: DaVinci: Added support based on copy_from_user instead of DMA
Date: Tue, 3 Aug 2010 16:13:45 +0100	[thread overview]
Message-ID: <20100803151345.GH25306@rakim.wolfsonmicro.main> (raw)
In-Reply-To: <1279291619-5081-3-git-send-email-lamiaposta71@gmail.com>

On Fri, Jul 16, 2010 at 04:46:58PM +0200, Raffaele Recalcati wrote:
> From: Davide Bonfanti <davide.bonfanti@bticino.it>
> 
>     This driver implements a pcm interface without the use of a DMA but with
>     a copy_from_user.
>     There's a buffer in the driver that is filled with davinci_pcm_copy.
>     When pcm is running, a TIMER interrupt is activated in order to fill
>     HW FIFO.
>     BUG: It happens sometimes that the peripheral stops working so there's a
>     trap.

Looking at this code the main thing that jumps out at me is that it
doesn't look at all DaVinci specific - all the interaction with the
hardware is hidden behind the ops structure you've defined, though the
ops structure doesn't define things like the maximum number of channels
and sample rate which I'd expect it to.  This suggests that either the
patch shouldn't be DaVinci specific or the splitting out of the ops
structure isn't adding anything.

> +int pointer_sub;

These should all be static.

> +int hw_fifo_size;
> +u16 *local_buffer;
> +static struct hrtimer hrtimer;
> +struct snd_pcm_substream *substream_loc;
> +int ns_for_interrupt = 1500000;

Magic number?

> +       gpio_set_value(69, 0);

Magic number again, and nothing requests this GPIO either.  Looks like
another thing for the ops structure.

  reply	other threads:[~2010-08-03 15:13 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-16 14:46 ASoC DaVinci voicecodec based on copyfromuser Raffaele Recalcati
     [not found] ` <1279291619-5081-1-git-send-email-lamiaposta71-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-07-16 14:46   ` [PATCH 1/3] ASoC: soc-core: soc_pcm_ops dynamically allocated Raffaele Recalcati
2010-07-16 15:09     ` Mark Brown
     [not found]       ` <20100716150948.GA23183-HF5t3jzXg/6ND3a5+9QAFujbO/Zr0HzV@public.gmane.org>
2010-07-16 15:25         ` Raffaele Recalcati
2010-07-16 15:35           ` Mark Brown
2010-07-16 14:46   ` [PATCH 2/3] ASoC: DaVinci: Added support based on copy_from_user instead of DMA Raffaele Recalcati
2010-08-03 15:13     ` Mark Brown [this message]
2010-07-16 14:46   ` [PATCH 3/3] ASoC: DaVinci: Voicecodec: Added support based on davinci-pcm-copyfromuser Raffaele Recalcati

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=20100803151345.GH25306@rakim.wolfsonmicro.main \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=chaithrika@ti.com \
    --cc=davide.bonfanti@bticino.it \
    --cc=davinci-linux-open-source@linux.davincidsp.com \
    --cc=lamiaposta71@gmail.com \
    --cc=lrg@slimlogic.co.uk \
    --cc=raffaele.recalcati@bticino.it \
    --cc=troy.kisky@boundarydevices.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.