}
static void clk_core_init_rate_req(struct clk_core * const core,
- struct clk_rate_request *req)
+ struct clk_rate_request *req,
+ unsigned long rate)
{
struct clk_core *parent;
if (WARN_ON(!core || !req))
return;
+ req->rate = rate;
clk_core_get_boundaries(core, &req->min_rate, &req->max_rate);
parent = core->parent;
return 0;
}
- clk_core_init_rate_req(core, req);
+ clk_core_init_rate_req(core, req, req->rate);
if (clk_core_can_round(core))
return clk_core_determine_round_nolock(core, req);
if (clk_core_can_round(core)) {
struct clk_rate_request req;
- req.rate = rate;
-
- clk_core_init_rate_req(core, &req);
+ clk_core_init_rate_req(core, &req, rate);
ret = clk_core_determine_round_nolock(core, &req);
if (ret < 0)