Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Ujfalusi <peter.ujfalusi@nokia.com>
To: ext Mark Brown <broonie@sirena.org.uk>
Cc: sakoman@gmail.com, alsa-devel@alsa-project.org
Subject: Re: [PATCH 5/9] ASoC: TWL4030: Add PreDriv outupt mux and volume controls
Date: Tue, 25 Nov 2008 12:51:46 +0200	[thread overview]
Message-ID: <200811251251.46575.peter.ujfalusi@nokia.com> (raw)
In-Reply-To: <20081124145031.GH22394@sirena.org.uk>



On Monday 24 November 2008 16:50:31 ext Mark Brown wrote:
> On Mon, Nov 24, 2008 at 04:19:18PM +0200, Peter Ujfalusi wrote:
> > On Monday 24 November 2008 15:48:09 ext Mark Brown wrote:
 
> > Do you have a pointer, where should I look for existing code?
> 
> At least WM8990 and WM8903 do this with separate controls.  Most of the
> drivers should be fine to look at for examples, it's just that this was
> done for some of the older drivers and it's never been worth changing
> them.

I'll take a look.

> Oh, ick.  There's a couple of ways I can think of to represent that to
> DAPM.  One would be to have a simple mixer with switches for everything
> and an extended event on the mixer which returns an error if multiple
> DAC inputs are enabled.  The other is to have the DAC selection be a
> custom mux like you've got and feed that into the mixer unconditionally.
> The voice input should certainly be a separate control here.

Not sure that I understand these, but I'll try to get the 'other' way
implemented.

> > On the side not: the voice path at the moment not in use -> the codec has
> > to be in different mode to have the voice path enabled. But then lot's of
> > things will behave differently.
> 
> Could you go into more detail about these modes?  Sounds like it could
> get tricky...

Let's see... I might be the wrong person for this, but in short.
TWL can operate in two modes:
Option 1: two RX and TX stereo paths (four channel RX and four channel TX)
Option 2: Voice uplink (sterreo) and downlink (mono) +
          one RX and TX stereo paths (two channel RX and two channel TX).

At the moment the driver supports the Option 1. Adding the support for Option 2
is tricky, since I have not seen a HW which can support it. The SW support
can be added, but at least I can not verify, that it is working...
On the Option 1 side: in order to use all four channel the TDM support is
needed for twl4030 and for omap-mcbsp. Actually this is my long term plan...
This is one of the reasons to have as flexible routing and control for TWL as
possible.
When the Option 1 is ready, I think in theory it should not be that hard to
add support for the Option 2. Couple of new DAC, mixers, muxes, interconnects..

Hmm, after reading it back: probably this will just cause more confusion ;)

> > Initially I did not wanted to spread these controls - to make it simple
> > for myself, but I might separate the voice and DAC mux selections (separated
> > enable for voice and mux the DACL/Rs selection).
> 
> Yes, that does sound like the best approach.
> 

-- 
Péter

  reply	other threads:[~2008-11-25 10:52 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-11-24 11:49 [PATCH 0/9] ASoC: TWL4030: Add mixer controls for outputs Peter Ujfalusi
2008-11-24 11:49 ` [PATCH 1/9] ASoC: TWL4030: Change the Master volume control to TLV Peter Ujfalusi
2008-11-24 11:49   ` [PATCH 2/9] ASoC: TWL4030: Add CGAIN volume control Peter Ujfalusi
2008-11-24 11:49     ` [PATCH 3/9] ASoC: TWL4030: Add helper function for mux handling Peter Ujfalusi
2008-11-24 11:49       ` [PATCH 4/9] ASoC: TWL4030: Add helper function for output gain controls Peter Ujfalusi
2008-11-24 11:49         ` [PATCH 5/9] ASoC: TWL4030: Add PreDriv outupt mux and volume controls Peter Ujfalusi
2008-11-24 11:49           ` [PATCH 6/9] ASoC: TWL4030: Add Headset " Peter Ujfalusi
2008-11-24 11:49             ` [PATCH 7/9] ASoC: TWL4030: Add Carkit " Peter Ujfalusi
2008-11-24 11:49               ` [PATCH 8/9] ASoC: TWL4030: Add Hands-free outupt mux control Peter Ujfalusi
2008-11-24 11:49                 ` [PATCH 9/9] ASoC: TWL4030: Add Earpiece outupt mux and volume controls Peter Ujfalusi
2008-11-24 13:48           ` [PATCH 5/9] ASoC: TWL4030: Add PreDriv " Mark Brown
2008-11-24 14:19             ` Peter Ujfalusi
2008-11-24 14:50               ` Mark Brown
2008-11-25 10:51                 ` Peter Ujfalusi [this message]
2008-11-24 13:57         ` [PATCH 4/9] ASoC: TWL4030: Add helper function for output gain controls Mark Brown
2008-11-24 13:55     ` [PATCH 2/9] ASoC: TWL4030: Add CGAIN volume control Mark Brown
2008-11-24 13:55   ` [PATCH 1/9] ASoC: TWL4030: Change the Master volume control to TLV 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=200811251251.46575.peter.ujfalusi@nokia.com \
    --to=peter.ujfalusi@nokia.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@sirena.org.uk \
    --cc=sakoman@gmail.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