Message ID | 8485366fbf06600d528ac31ef4a873f6717f2fd7.1576770177.git.leonard.crestez@nxp.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
Series | PM / devfreq: imx8m-ddrc: Fix argument swap in error print | expand |
2019년 12월 20일 (금) 오전 12:44, Leonard Crestez <leonard.crestez@nxp.com>님이 작성: > > When frequency adjustment fails the old/new frequencies are swapped on > the dev_err call. > > Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com> > --- > drivers/devfreq/imx8m-ddrc.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/devfreq/imx8m-ddrc.c b/drivers/devfreq/imx8m-ddrc.c > index ecbb1db05ea0..53df7923d893 100644 > --- a/drivers/devfreq/imx8m-ddrc.c > +++ b/drivers/devfreq/imx8m-ddrc.c > @@ -258,14 +258,14 @@ static int imx8m_ddrc_target(struct device *dev, unsigned long *freq, u32 flags) > ret = imx8m_ddrc_set_freq(dev, freq_info); > > new_freq = clk_get_rate(priv->dram_core); > if (ret) > dev_err(dev, "ddrc failed freq switch to %lu from %lu: error %d. now at %lu\n", > - old_freq, *freq, ret, new_freq); > + *freq, old_freq, ret, new_freq); > else if (*freq != new_freq) > dev_err(dev, "ddrc failed freq update to %lu from %lu, now at %lu\n", > - old_freq, *freq, new_freq); > + *freq, old_freq, new_freq); > else > dev_dbg(dev, "ddrc freq set to %lu (was %lu)\n", > *freq, old_freq); > > return ret; > -- > 2.17.1 > If you agree, I want to squash this patch to original patch on devfreq-next patch without separate patch applied.
diff --git a/drivers/devfreq/imx8m-ddrc.c b/drivers/devfreq/imx8m-ddrc.c index ecbb1db05ea0..53df7923d893 100644 --- a/drivers/devfreq/imx8m-ddrc.c +++ b/drivers/devfreq/imx8m-ddrc.c @@ -258,14 +258,14 @@ static int imx8m_ddrc_target(struct device *dev, unsigned long *freq, u32 flags) ret = imx8m_ddrc_set_freq(dev, freq_info); new_freq = clk_get_rate(priv->dram_core); if (ret) dev_err(dev, "ddrc failed freq switch to %lu from %lu: error %d. now at %lu\n", - old_freq, *freq, ret, new_freq); + *freq, old_freq, ret, new_freq); else if (*freq != new_freq) dev_err(dev, "ddrc failed freq update to %lu from %lu, now at %lu\n", - old_freq, *freq, new_freq); + *freq, old_freq, new_freq); else dev_dbg(dev, "ddrc freq set to %lu (was %lu)\n", *freq, old_freq); return ret;
When frequency adjustment fails the old/new frequencies are swapped on the dev_err call. Signed-off-by: Leonard Crestez <leonard.crestez@nxp.com> --- drivers/devfreq/imx8m-ddrc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)