[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190427171955.GH14916@sirena.org.uk>
Date: Sun, 28 Apr 2019 02:19:55 +0900
From: Mark Brown <broonie@...nel.org>
To: Adam Thomson <Adam.Thomson.Opensource@...semi.com>
Cc: Liam Girdwood <lgirdwood@...il.com>, Takashi Iwai <tiwai@...e.com>,
Jaroslav Kysela <perex@...ex.cz>,
Akshu Agrawal <Akshu.Agrawal@....com>,
alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
Support Opensource <support.opensource@...semi.com>
Subject: Re: [PATCH] ASoC: da7219: Use clk_round_rate to handle enabled
bclk/wclk case
On Fri, Apr 26, 2019 at 01:59:24PM +0100, Adam Thomson wrote:
> + /*
> + * Rounding the rate here avoids failure trying to set a new
> + * rate on an already enabled wclk. In that instance this will
> + * just set the same rate as is currently in use, and so should
> + * continue without problem.
> + */
> + sr = clk_round_rate(wclk, sr);
> ret = clk_set_rate(wclk, sr);
> if (ret) {
> dev_err(component->dev,
Don't we need to validate that the rounded rate is actually viable for
the parameters we're trying to set here? If there's missing constraints
causing something to try to do something unsupportable then we should
return an error rather than silently accept.
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists