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:	Tue, 12 May 2015 20:30:14 +0100
From:	Mark Brown <broonie@...nel.org>
To:	Xing Zheng <acgzxing@...il.com>
Cc:	dgreid@...omium.org, dianders@...omium.org, heiko@...ech.de,
	sonnyrao@...omium.org, linux-rockchip@...ts.infradead.org,
	zhengxing <zhengxing@...k-chips.com>,
	Liam Girdwood <lgirdwood@...il.com>,
	Jaroslav Kysela <perex@...ex.cz>, Takashi Iwai <tiwai@...e.de>,
	linux-kernel@...r.kernel.org, alsa-devel@...a-project.org,
	linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH 3/4] ASoC: rockchip: add rockchip machine driver for
 rt5650/rt5645

On Tue, May 12, 2015 at 05:26:36PM +0800, Xing Zheng wrote:
> From: zhengxing <zhengxing@...k-chips.com>
> 
> The driver is used for rockchip board using a rt5650/rt5645.
> Test on RK3288 with rt5650.

Similar comments to the Maxim driver plus...

> +/* Jack detect via rt5645 driver. */
> +extern int rt5645_set_jack_detect(struct snd_soc_codec *codec,
> +				  struct snd_soc_jack *hp_jack,
> +				  struct snd_soc_jack *mic_jack,
> +				  struct snd_soc_jack *btn_jack);
> +
> +/* For compatible. */
> +int __weak rt5645_set_jack_detect(struct snd_soc_codec *codec,
> +				  struct snd_soc_jack *hp_jack,
> +				  struct snd_soc_jack *mic_jack,
> +				  struct snd_soc_jack *btn_jack)
> +{
> +	dev_warn(codec->dev, "Jack detect dummy, have no implement it?\n");
> +
> +	return 0;
> +}

Don't do this - if the functionality isn't there in the CODEC driver get
it implemented before you use it.  Make sure you're using the API the
CODEC actually ends up exporting.

> +	/* Enable Headset and 4 Buttons Jack detection */
> +	ret = snd_soc_card_jack_new(card, "Headphone Jack",
> +				    SND_JACK_HEADPHONE | SND_JACK_MICROPHONE,

> +	ret = snd_soc_card_jack_new(card, "Mic Jack",
> +
> +	ret = snd_soc_card_jack_new(card, "Button Jack",

No, don't do this - as discussed in another Chromebook review (I'm
guessing this is a Chromebook) the jacks should represent the physical
jacks in the system.  It's possible you have separate headphone and
microphone jacks but I really expect microphone and button to be on the
same socket.

Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)

Powered by blists - more mailing lists