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]
Message-ID: <20091102172720.GA8546@rakim.wolfsonmicro.main>
Date:	Mon, 2 Nov 2009 17:27:20 +0000
From:	Mark Brown <broonie@...nsource.wolfsonmicro.com>
To:	Peter Ujfalusi <peter.ujfalusi@...ia.com>
Cc:	alsa-devel@...a-project.org, linux-omap@...r.kernel.org,
	sameo@...ux.intel.com, linux-kernel@...r.kernel.org,
	tony@...mide.com
Subject: Re: [PATCH 5/5] ASoC: TWL4030: Do not modify the APLL_CTL register

On Mon, Nov 02, 2009 at 02:34:55PM +0200, Peter Ujfalusi wrote:
> APLL_CTL register is configured by the twl4030-codec MFD
> driver.
> Remove code, which makes changes in the APLL_CTL register,
> and replace those with checks against the configured
> audio_mclk configuration done in the MFD driver.

This all looks mostly OK.  It might be nice to combine this patch with
the change to the MFD driver, simply because when the previous patch
said "move" but didn't remove anything from the CODEC driver it seemed a
bit surprising.  The MFD part of this is queued in ASoC ATM so it
shouldn't cause cross tree issues.

> -	twl4030_write(codec, TWL4030_REG_APLL_CTL, apll_ctrl);
> +	if ((freq / 1000) != twl4030->sysclk) {
> +		dev_err(codec->dev,
> +			"Mismatch in APLL infrequency %u (configred: %u)\n",
> +			freq, twl4030->sysclk * 1000);

Typos in the log message here (and similarly for the other DAI).

> -	if (infreq != TWL4030_APLL_INFREQ_26000KHZ) {
> +	if (twl4030->sysclk != 26000) {
>  		printk(KERN_ERR "TWL4030 voice startup: "
>  			"MCLK is not 26MHz, call set_sysclk() on init\n");
>  		return -EINVAL;

Is that advice still appropriate if things are specified via the
codec device now?

> @@ -2233,6 +2215,7 @@ static int __devinit twl4030_codec_probe(struct platform_device *pdev)
>  	twl4030_codec = codec;
>  
>  	/* Set the defaults, and power up the codec */
> +	twl4030->sysclk = twl4030_codec_get_mclk() / 1000;
>  	twl4030_init_chip(codec);
>  	codec->bias_level = SND_SOC_BIAS_OFF;
>  	twl4030_set_bias_level(codec, SND_SOC_BIAS_STANDBY);

twl4030_codec_get_mclk() feels like it ought to take a parameter saying
which twl4030, though the chances of having multiple twl4030s in one
system are remote so it's not a real issue.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ