PM / devfreq: bimc-bwmon: Optimize some debug messages

A device register is read and printed using pr_debug. Register reads can be
slow. So, refactor the code such that the register read is also compiled
out if the pr_debug is compiled out.

Change-Id: I4de5ab1f2133e19d6ce0b3cb4547b815526c7abd
Signed-off-by: Saravana Kannan <skannan@codeaurora.org>
This commit is contained in:
Saravana Kannan 2015-06-11 15:47:05 -07:00 committed by David Keitel
parent 75ec9ed0ef
commit decfc3fe4a

View file

@ -118,12 +118,12 @@ static void mon_irq_disable(struct bwmon *m)
static unsigned int mon_irq_status(struct bwmon *m)
{
u32 mval, gval;
u32 mval;
mval = readl_relaxed(MON_INT_STATUS(m)),
gval = readl_relaxed(GLB_INT_STATUS(m));
mval = readl_relaxed(MON_INT_STATUS(m));
dev_dbg(m->dev, "IRQ status p:%x, g:%x\n", mval, gval);
dev_dbg(m->dev, "IRQ status p:%x, g:%x\n", mval,
readl_relaxed(GLB_INT_STATUS(m)));
return mval;
}