From: Xing Zheng <zhengxing@rock-chips.com>
To: Rob Herring <robh@kernel.org>, broonie@kernel.org
Cc: Mark Rutland <mark.rutland@arm.com>, Andrew Lunn <andrew@lunn.ch>,
alsa-devel@alsa-project.org,
Mengdong Lin <mengdong.lin@linux.intel.com>,
heiko@sntech.de, Pawel Moll <pawel.moll@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
linux-kernel@vger.kernel.org, Takashi Iwai <tiwai@suse.com>,
Arnaud Pouliquen <arnaud.pouliquen@st.com>,
Liam Girdwood <lgirdwood@gmail.com>, Jyri Sarha <jsarha@ti.com>,
sugar.zhang@rock-chips.com, linux-rockchip@lists.infradead.org,
Adam.Thomson@diasemi.com, Kumar Gala <galak@codeaurora.org>,
Aaro Koskinen <aaro.koskinen@iki.fi>,
Jun Nie <jun.nie@linaro.org>,
jay.xu@rock-chips.com, devicetree@vger.kernel.org
Subject: Re: [PATCH 2/3] ASoC: simple-card: Add support jack detection via codec
Date: Fri, 22 Apr 2016 09:17:46 +0800 [thread overview]
Message-ID: <57197BBA.50304@rock-chips.com> (raw)
In-Reply-To: <20160421141921.GA25900@rob-hp-laptop>
On 2016年04月21日 22:19, Rob Herring wrote:
> On Mon, Apr 18, 2016 at 04:17:31PM +0800, Xing Zheng wrote:
>> In most cases, many codecs already supports jack detection, previouslly,
>> we need to create a customized machine driver every time.
>>
>> Hence, the simple-card need to support use them dynamically via parse dts
>> file for better flexibility.
>>
>> Signed-off-by: Xing Zheng <zhengxing@rock-chips.com>
>> ---
>>
>> .../devicetree/bindings/sound/simple-card.txt | 17 +++
>> sound/soc/generic/simple-card.c | 126 +++++++++++++++++++-
>> 2 files changed, 140 insertions(+), 3 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/sound/simple-card.txt b/Documentation/devicetree/bindings/sound/simple-card.txt
>> index cf3979e..d25c8eb 100644
>> --- a/Documentation/devicetree/bindings/sound/simple-card.txt
>> +++ b/Documentation/devicetree/bindings/sound/simple-card.txt
>> @@ -22,6 +22,23 @@ Optional properties:
>> headphones are attached.
>> - simple-audio-card,mic-det-gpio : Reference to GPIO that signals when
>> a microphone is attached.
>> +- simple-audio-card,codec-jack : A list of the codec supports jack detection.
>> + The jack types which are supported refer to include/sound/jack.h.
>> + All of the jack types:
>> + "JACK_HEADPHONE",
>> + "JACK_MICROPHONE",
>> + "JACK_HEADSET",
>> + "JACK_LINEOUT",
>> + "JACK_MECHANICAL",
>> + "JACK_VIDEOOUT",
>> + "JACK_AVOUT",
>> + "JACK_LINEIN",
>> + "JACK_BTN_0",
>> + "JACK_BTN_1",
>> + "JACK_BTN_2",
>> + "JACK_BTN_3",
>> + "JACK_BTN_4",
>> + "JACK_BTN_5".
> simple-card is not so simple...
>
> I think this information be part of the codec node if the codec
> provides the functionality. The binding should not be different whether
> a codec is part of simple-card or not. Also, I would make all these just
> boolean props.
Yes, these things seem like make simple-card becomes more complicated,
and the generic jack detection method is still a problem currently.
Hi Mark, the other question here, how do we make sense to use the
simple-card to call the "snd_soc_dai_set_pll" if the codec (like da7219)
requires do this?
Thanks.
--
- Xing Zheng
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
next prev parent reply other threads:[~2016-04-22 1:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-18 8:17 [PATCH 0/3] Add support simple-card parse jack detection via external codec Xing Zheng
2016-04-18 8:17 ` [PATCH 2/3] ASoC: simple-card: Add support jack detection via codec Xing Zheng
2016-04-21 14:19 ` Rob Herring
2016-04-22 1:17 ` Xing Zheng [this message]
[not found] ` <57197BBA.50304-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2016-04-22 9:22 ` Mark Brown
[not found] ` <20160422092250.GA3217-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2016-04-22 16:37 ` [alsa-devel] " Jeremy McDermond
2016-04-25 12:55 ` Mark Brown
[not found] ` <20160425125504.GL3217-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2016-04-25 18:17 ` [alsa-devel] " Jeremy McDermond
2016-04-22 16:40 ` Jeremy McDermond
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=57197BBA.50304@rock-chips.com \
--to=zhengxing@rock-chips.com \
--cc=Adam.Thomson@diasemi.com \
--cc=aaro.koskinen@iki.fi \
--cc=alsa-devel@alsa-project.org \
--cc=andrew@lunn.ch \
--cc=arnaud.pouliquen@st.com \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=galak@codeaurora.org \
--cc=heiko@sntech.de \
--cc=ijc+devicetree@hellion.org.uk \
--cc=jay.xu@rock-chips.com \
--cc=jsarha@ti.com \
--cc=jun.nie@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mark.rutland@arm.com \
--cc=mengdong.lin@linux.intel.com \
--cc=pawel.moll@arm.com \
--cc=robh@kernel.org \
--cc=sugar.zhang@rock-chips.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;
as well as URLs for NNTP newsgroup(s).