lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 21 Apr 2016 09:19:21 -0500
From:	Rob Herring <robh@...nel.org>
To:	Xing Zheng <zhengxing@...k-chips.com>
Cc:	linux-rockchip@...ts.infradead.org, heiko@...ech.de,
	Adam.Thomson@...semi.com, sugar.zhang@...k-chips.com,
	jay.xu@...k-chips.com, broonie@...nel.org,
	Pawel Moll <pawel.moll@....com>,
	Mark Rutland <mark.rutland@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	Kumar Gala <galak@...eaurora.org>,
	Liam Girdwood <lgirdwood@...il.com>,
	Jaroslav Kysela <perex@...ex.cz>,
	Takashi Iwai <tiwai@...e.com>,
	Arnaud Pouliquen <arnaud.pouliquen@...com>,
	Aaro Koskinen <aaro.koskinen@....fi>,
	Andrew Lunn <andrew@...n.ch>,
	Mengdong Lin <mengdong.lin@...ux.intel.com>,
	Jun Nie <jun.nie@...aro.org>, Jyri Sarha <jsarha@...com>,
	devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
	alsa-devel@...a-project.org
Subject: Re: [PATCH 2/3] ASoC: simple-card: Add support jack detection via
 codec

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@...k-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. 

Rob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ