Lines Matching refs:clk_rate
123 unsigned long clk_rate; member
179 unsigned long clk_rate = aemif->clk_rate; in aemif_config_abus() local
185 ta = aemif_calc_rate(pdev, data->ta, clk_rate, TA_MAX); in aemif_config_abus()
186 rhold = aemif_calc_rate(pdev, data->rhold, clk_rate, RHOLD_MAX); in aemif_config_abus()
187 rstrobe = aemif_calc_rate(pdev, data->rstrobe, clk_rate, RSTROBE_MAX); in aemif_config_abus()
188 rsetup = aemif_calc_rate(pdev, data->rsetup, clk_rate, RSETUP_MAX); in aemif_config_abus()
189 whold = aemif_calc_rate(pdev, data->whold, clk_rate, WHOLD_MAX); in aemif_config_abus()
190 wstrobe = aemif_calc_rate(pdev, data->wstrobe, clk_rate, WSTROBE_MAX); in aemif_config_abus()
191 wsetup = aemif_calc_rate(pdev, data->wsetup, clk_rate, WSETUP_MAX); in aemif_config_abus()
217 static inline int aemif_cycles_to_nsec(int val, unsigned long clk_rate) in aemif_cycles_to_nsec() argument
219 return ((val + 1) * NSEC_PER_MSEC) / clk_rate; in aemif_cycles_to_nsec()
235 unsigned long clk_rate = aemif->clk_rate; in aemif_get_hw_params() local
241 data->ta = aemif_cycles_to_nsec(TA_VAL(val), clk_rate); in aemif_get_hw_params()
242 data->rhold = aemif_cycles_to_nsec(RHOLD_VAL(val), clk_rate); in aemif_get_hw_params()
243 data->rstrobe = aemif_cycles_to_nsec(RSTROBE_VAL(val), clk_rate); in aemif_get_hw_params()
244 data->rsetup = aemif_cycles_to_nsec(RSETUP_VAL(val), clk_rate); in aemif_get_hw_params()
245 data->whold = aemif_cycles_to_nsec(WHOLD_VAL(val), clk_rate); in aemif_get_hw_params()
246 data->wstrobe = aemif_cycles_to_nsec(WSTROBE_VAL(val), clk_rate); in aemif_get_hw_params()
247 data->wsetup = aemif_cycles_to_nsec(WSETUP_VAL(val), clk_rate); in aemif_get_hw_params()
357 aemif->clk_rate = clk_get_rate(aemif->clk) / MSEC_PER_SEC; in aemif_probe()