Lines Matching refs:calcp
290 u8 div, calcp, calcm = 1; in sun6i_get_ahb1_factors() local
304 calcp = 0; in sun6i_get_ahb1_factors()
306 calcp = 1; in sun6i_get_ahb1_factors()
308 calcp = 2; in sun6i_get_ahb1_factors()
310 calcp = 3; in sun6i_get_ahb1_factors()
312 calcm = DIV_ROUND_UP(div, 1 << calcp); in sun6i_get_ahb1_factors()
314 calcp = __roundup_pow_of_two(div); in sun6i_get_ahb1_factors()
315 calcp = calcp > 3 ? 3 : calcp; in sun6i_get_ahb1_factors()
318 req->rate = (req->parent_rate / calcm) >> calcp; in sun6i_get_ahb1_factors()
319 req->p = calcp; in sun6i_get_ahb1_factors()
347 u8 calcm, calcp; in sun4i_get_apb1_factors() local
360 calcp = 0; in sun4i_get_apb1_factors()
362 calcp = 1; in sun4i_get_apb1_factors()
364 calcp = 2; in sun4i_get_apb1_factors()
366 calcp = 3; in sun4i_get_apb1_factors()
368 calcm = (div >> calcp) - 1; in sun4i_get_apb1_factors()
370 req->rate = (req->parent_rate >> calcp) / (calcm + 1); in sun4i_get_apb1_factors()
372 req->p = calcp; in sun4i_get_apb1_factors()
386 u8 div, calcm, calcp; in sun7i_a20_get_out_factors() local
396 calcp = 0; in sun7i_a20_get_out_factors()
398 calcp = 1; in sun7i_a20_get_out_factors()
400 calcp = 2; in sun7i_a20_get_out_factors()
402 calcp = 3; in sun7i_a20_get_out_factors()
404 calcm = DIV_ROUND_UP(div, 1 << calcp); in sun7i_a20_get_out_factors()
406 req->rate = (req->parent_rate >> calcp) / calcm; in sun7i_a20_get_out_factors()
408 req->p = calcp; in sun7i_a20_get_out_factors()