Commit f5ca6d4c authored by Guennadi Liakhovetski's avatar Guennadi Liakhovetski Committed by Paul Mundt

sh: simplify WARN usage in SH clock driver

Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
parent 03c5ecd1
......@@ -160,12 +160,9 @@ void propagate_rate(struct clk *tclk)
static void __clk_disable(struct clk *clk)
{
if (clk->usecount == 0) {
printk(KERN_ERR "Trying disable clock %s with 0 usecount\n",
clk->name);
WARN_ON(1);
if (WARN(!clk->usecount, "Trying to disable clock %s with 0 usecount\n",
clk->name))
return;
}
if (!(--clk->usecount)) {
if (likely(clk->ops && clk->ops->disable))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment