Commit 2aab7a20 authored by Boris Brezillon's avatar Boris Brezillon Committed by Stephen Boyd

clk: bcm: Fix 'maybe-uninitialized' warning in bcm2835_clock_choose_div_and_prate()

best_rate is reported as potentially uninitialized by gcc.
Signed-off-by: default avatarBoris Brezillon <boris.brezillon@free-electrons.com>
Fixes: 155e8b3b ("clk: bcm: Support rate change propagation on bcm2835 clocks")
Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
Reviewed-by: default avatarEric Anholt <eric@anholt.net>
Signed-off-by: default avatarStephen Boyd <sboyd@codeaurora.org>
parent 71a2f115
......@@ -1029,7 +1029,7 @@ static unsigned long bcm2835_clock_choose_div_and_prate(struct clk_hw *hw,
struct bcm2835_clock *clock = bcm2835_clock_from_hw(hw);
struct bcm2835_cprman *cprman = clock->cprman;
const struct bcm2835_clock_data *data = clock->data;
unsigned long best_rate;
unsigned long best_rate = 0;
u32 curdiv, mindiv, maxdiv;
struct clk_hw *parent;
......
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