mirror of https://gitee.com/openkylin/linux.git
i2c: rcar: Remove superfluous call to clk_get_rate()
Variable "rate" already contains the current clock rate, so use that rather than calling clk_get_rate() again. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Luca Ceresoli <luca@lucaceresoli.net> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
This commit is contained in:
parent
993e219406
commit
c39511ffb9
|
@ -317,7 +317,7 @@ static int rcar_i2c_clock_calculate(struct rcar_i2c_priv *priv, struct i2c_timin
|
||||||
|
|
||||||
scgd_find:
|
scgd_find:
|
||||||
dev_dbg(dev, "clk %d/%d(%lu), round %u, CDF:0x%x, SCGD: 0x%x\n",
|
dev_dbg(dev, "clk %d/%d(%lu), round %u, CDF:0x%x, SCGD: 0x%x\n",
|
||||||
scl, t->bus_freq_hz, clk_get_rate(priv->clk), round, cdf, scgd);
|
scl, t->bus_freq_hz, rate, round, cdf, scgd);
|
||||||
|
|
||||||
/* keep icccr value */
|
/* keep icccr value */
|
||||||
priv->icccr = scgd << cdf_width | cdf;
|
priv->icccr = scgd << cdf_width | cdf;
|
||||||
|
|
Loading…
Reference in New Issue