Commit 762c4e7f authored by Wan Jiabing's avatar Wan Jiabing Committed by Thierry Reding

pwm: sifive: Simplify if-if to if-else

Use if and else instead of if(A) and if (!A).
Signed-off-by: default avatarWan Jiabing <wanjiabing@vivo.com>
Signed-off-by: default avatarThierry Reding <thierry.reding@gmail.com>
parent 2bf8ee0f
......@@ -138,10 +138,9 @@ static int pwm_sifive_enable(struct pwm_chip *chip, bool enable)
dev_err(ddata->chip.dev, "Enable clk failed\n");
return ret;
}
}
if (!enable)
} else {
clk_disable(ddata->clk);
}
return 0;
}
......
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