devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: NeilBrown <neilb@suse.de>
To: Mark Brown <broonie@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>,
	GTA04 owners <gta04-owner@goldelico.com>,
	alsa-devel@alsa-project.org, Pawel Moll <pawel.moll@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Liam Girdwood <lgirdwood@gmail.com>,
	linux-kernel@vger.kernel.org,
	Peter Ujfalusi <peter.ujfalusi@ti.com>,
	devicetree@vger.kernel.org, Rob Herring <robh+dt@kernel.org>
Subject: Re: [PATCH 2/3] ASoC: twl4030: allow voice port to be connected externally.
Date: Mon, 10 Nov 2014 10:25:51 +1100	[thread overview]
Message-ID: <20141110102551.2678d342@notabene.brown> (raw)
In-Reply-To: <20141108092622.GC2722@sirena.org.uk>


[-- Attachment #1.1: Type: text/plain, Size: 2887 bytes --]

On Sat, 8 Nov 2014 09:26:22 +0000 Mark Brown <broonie@kernel.org> wrote:

> On Sat, Nov 08, 2014 at 11:38:03AM +1100, NeilBrown wrote:
> 
> > If voice port on twl4030 is not connected to a McBSP (or similar)
> > then we cannot configure the format the way we normally do for a DAI.
> 
> Yes we can, you need to represent the DAI link to whatever else the
> device is connected to in the driver like we do anything else - and in
> any case this isn't a device specific issue so we shouldn't be doing
> something driver specific to solve it.  Look at something like speyside.

Hi Mark,
 thanks for the reply ... I might need a little bit more help though.

I had a look at sound/soc/samsung/speyside.c, but I'm not entirely sure what
I'm looking for.
Presumably this is an audio processor not unlike the audio module in the
twl4030.

I see that there are 3 dai-links:
  CPU-DSP
  DSP-CODEC
  Baseband

Presumably "Baseband" is similar, in purpose at least, to the "voice"
interface on the twl4030.

Each dai-link has a "cpu_dai_name" and a "codec_dai_name", even though it
appears that only "CPU-DSP" is connected to the CPU.  Maybe that naming is
the source of some of my confusion.

"Baseband" declares
                .cpu_dai_name = "wm8996-aif2",
so wm8996 is something with 2 audio interfaces, (aif), and this is the second
one?  Maybe the  wm8996 is the audio module, so what is the "speyside"?

http://opensource.wolfsonmicro.com/content/speyside-audio

says it is a "reference platform".  Does that mean it is a board with a bunch
of chips soldered onto it?  If it were a board it should be described by a
dts file, not by a pile of C code (I thought), so I must be wrong about that.


In my case, I have a board with a GSM module and the twl4030 module.  Each
has an audio interface and these are connected.  I assume that I need to
express this connection in the dts file.
The GSM module doesn't currently appear in the dts file as it is usb-attached.
However I've been thinking that we will need to add it so we can express
power-on controls (twiddling some GPIOs).  So let's suppose we have the GSM
module in the dts file (child of a USB interface) and the twl4030 as well
(beneath an i2c interface).

The twl4030 needs to know the master/polarity of the clk/frm lines.  The GSM
module declares that these are.  So presumably we need some sort of linkage.
Ahhhh... I found Documentation/devicetree/bindings/sound/simple-card.txt

So I need to make the "voice" port on the twl4030 look like a "cpu" end of a
dai-link, and create a "codec" end in the GSM module, and use "sound-dai" to
point from the twl4030 to the GSM module.
Then I use frame-master, bitclock-master, bitclock-inversion, frame-inversion
for the settings I need.

I suspect I can make that work.

Am I on the right track?

Thanks,
NeilBrown

[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



  reply	other threads:[~2014-11-09 23:25 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-08  0:38 [PATCH 0/3] ASoC: twl4030: support routine to external VOICE source NeilBrown
2014-11-08  0:38 ` [PATCH 1/3] ASoC: twl4030: don't report EBUSY if no change requested NeilBrown
     [not found]   ` <20141108003803.6561.42934.stgit-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2014-11-08  9:22     ` Mark Brown
     [not found]       ` <20141108092242.GB2722-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2014-11-10  0:45         ` NeilBrown
2014-11-10  7:07           ` [alsa-devel] " Lars-Peter Clausen
     [not found]             ` <54606446.7030907-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
2014-11-10 21:45               ` NeilBrown
     [not found]                 ` <20141111084537.1b4e726c-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2014-11-10 21:49                   ` Lars-Peter Clausen
2014-11-08  0:38 ` [PATCH 2/3] ASoC: twl4030: allow voice port to be connected externally NeilBrown
2014-11-08  9:26   ` Mark Brown
2014-11-09 23:25     ` NeilBrown [this message]
2014-11-10  6:46       ` [Gta04-owner] " Dr. H. Nikolaus Schaller
     [not found]       ` <20141110102551.2678d342-wvvUuzkyo1EYVZTmpyfIwg@public.gmane.org>
2014-11-10 12:11         ` Mark Brown
2014-11-08  0:38 ` [PATCH 3/3] ASoC: twl4030: enable routing audio to 'voice' interface NeilBrown
2014-11-08  9:27   ` Mark Brown
2014-11-09 23:54     ` NeilBrown
2014-11-10 10:48       ` 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=20141110102551.2678d342@notabene.brown \
    --to=neilb@suse.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gta04-owner@goldelico.com \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=peter.ujfalusi@ti.com \
    --cc=robh+dt@kernel.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).