/Linux-v4.19/lib/ |
D | div64.c | 141 #ifndef div64_u64 142 u64 div64_u64(u64 dividend, u64 divisor) in div64_u64() function 161 EXPORT_SYMBOL(div64_u64); 174 quot = div64_u64(abs(dividend), abs(divisor)); in div64_s64()
|
/Linux-v4.19/drivers/clk/ |
D | clk-si570.c | 154 data->fxtal = div64_u64(fdco << 24, data->rfreq >> 4); in si570_get_defaults() 156 data->fxtal = div64_u64(fdco << 28, data->rfreq); in si570_get_defaults() 216 *out_rfreq = div64_u64(fdco << 28, data->fxtal); in si570_calc_divs() 260 if (div64_u64(abs(rate - data->frequency) * 10000LL, in si570_round_rate() 262 rfreq = div64_u64((data->rfreq * rate) + in si570_round_rate() 263 div64_u64(data->frequency, 2), data->frequency); in si570_round_rate() 330 data->rfreq = div64_u64((data->rfreq * frequency) + in si570_set_frequency_small() 355 if (div64_u64(abs(rate - data->frequency) * 10000LL, in si570_set_rate()
|
/Linux-v4.19/drivers/gpu/drm/amd/display/modules/freesync/ |
D | freesync.c | 444 min_frame_duration_in_ns = ((unsigned int) (div64_u64( in calc_freesync_range() 447 max_frame_duration_in_ns = ((unsigned int) (div64_u64( in calc_freesync_range() 457 state->freesync_range.vmax = div64_u64(div64_u64(((unsigned long long)( in calc_freesync_range() 460 state->freesync_range.vmin = div64_u64(div64_u64(((unsigned long long)( in calc_freesync_range() 497 *v_total_nominal = div64_u64(div64_u64(((unsigned long long)( in calc_v_total_from_duration() 512 unsigned int frame_duration_ratio = div64_u64(1000000, in calc_v_total_for_static_ramp() 513 (1000 + div64_u64(((unsigned long long)( in calc_v_total_for_static_ramp() 519 unsigned int frame_duration_delta = div64_u64(((unsigned long long)( in calc_v_total_for_static_ramp() 526 unsigned int ramp_rate_interpolated = div64_u64(((unsigned long long)( in calc_v_total_for_static_ramp() 537 frame_duration = ((unsigned int) (div64_u64( in calc_v_total_for_static_ramp() [all …]
|
/Linux-v4.19/include/linux/ |
D | math64.h | 11 #define div64_ul(x, y) div64_u64((x), (y)) 65 static inline u64 div64_u64(u64 dividend, u64 divisor) in div64_u64() function 103 #ifndef div64_u64 104 extern u64 div64_u64(u64 dividend, u64 divisor);
|
/Linux-v4.19/drivers/pwm/ |
D | pwm-bcm-iproc.c | 110 state->period = div64_u64(tmp, rate); in iproc_pwmc_get_state() 114 state->duty_cycle = div64_u64(tmp, rate); in iproc_pwmc_get_state() 142 period = div64_u64(value, div); in iproc_pwmc_apply() 144 duty = div64_u64(value, div); in iproc_pwmc_apply()
|
D | pwm-lpc32xx.c | 43 period_cycles = div64_u64(c * period_ns, in lpc32xx_pwm_config() 51 duty_cycles = div64_u64((unsigned long long)(period_ns - duty_ns) * 256, in lpc32xx_pwm_config()
|
D | pwm-spear.c | 100 pv = div64_u64(val, div); in spear_pwm_config() 102 dc = div64_u64(val, div); in spear_pwm_config()
|
D | pwm-mtk-disp.c | 102 period = div64_u64(rate * period_ns, div); in mtk_disp_pwm_config() 106 high_width = div64_u64(rate * duty_ns, div); in mtk_disp_pwm_config()
|
D | pwm-bcm-kona.c | 136 pc = div64_u64(val, div); in kona_pwmc_config() 138 dc = div64_u64(val, div); in kona_pwmc_config()
|
/Linux-v4.19/net/netfilter/ |
D | nft_limit.c | 161 priv->cost = div64_u64(priv->limit.nsecs, priv->limit.rate); in nft_limit_pkts_init() 186 u64 cost = div64_u64(priv->nsecs * pkt->skb->len, priv->rate); in nft_limit_bytes_eval() 263 priv->cost = div64_u64(priv->limit.nsecs, priv->limit.rate); in nft_limit_obj_pkts_init() 290 u64 cost = div64_u64(priv->nsecs * pkt->skb->len, priv->rate); in nft_limit_obj_bytes_eval()
|
D | xt_connbytes.c | 88 what = div64_u64(bytes, pkts); in connbytes_mt()
|
D | xt_hashlimit.c | 509 return div64_u64(user, div64_u64(scale, HZ * cpj)); in user2credits() 511 return user * div64_u64(HZ * cpj, scale); in user2credits() 524 return div64_u64(XT_HASHLIMIT_SCALE_v2, user); in user2rate()
|
/Linux-v4.19/drivers/acpi/ |
D | acpi_lpit.c | 45 *counter = div64_u64(count * 1000000ULL, residency_info_mem.frequency); in lpit_read_residency_counter_us() 57 *counter = div64_u64(*counter * 1000000ULL, residency_info_ffh.frequency); in lpit_read_residency_counter_us()
|
/Linux-v4.19/net/dccp/ccids/lib/ |
D | tfrc.h | 34 return div64_u64(a * 1000000, b); in scaled_div()
|
/Linux-v4.19/drivers/iio/common/ssp_sensors/ |
D | ssp_iio_sensor.h | 70 return div64_u64((u64)SSP_FACTOR_WITH_MS, value); in ssp_convert_to_time()
|
/Linux-v4.19/arch/x86/kernel/cpu/ |
D | aperfmperf.c | 63 s->khz = div64_u64((cpu_khz * aperf_delta), mperf_delta); in aperfmperf_snapshot_khz()
|
/Linux-v4.19/drivers/clk/pistachio/ |
D | clk-pll.c | 100 return div64_u64(dividend, divisor); in do_div_round_closest() 215 vco = div64_u64(vco, params->refdiv << 24); in pll_gf40lp_frac_set_rate() 221 val = div64_u64(params->fref, params->refdiv); in pll_gf40lp_frac_set_rate()
|
/Linux-v4.19/block/ |
D | blk-iolatency.c | 372 samples_thresh = div64_u64(samples_thresh, 100); in check_scale_change() 513 div64_u64(iolat->cur_win_nsec, in iolatency_check_latencies() 842 unsigned long long avg_lat = div64_u64(iolat->lat_avg, NSEC_PER_USEC); in iolatency_pd_stat() 843 unsigned long long cur_win = div64_u64(iolat->cur_win_nsec, NSEC_PER_MSEC); in iolatency_pd_stat()
|
/Linux-v4.19/drivers/net/ethernet/mellanox/mlx5/core/lib/ |
D | clock.c | 313 cycles_delta = div64_u64(nsec_delta << clock->cycles.shift, in mlx5_perout_configure() 477 cycles_delta = div64_u64(nsec_delta << clock->cycles.shift, in mlx5_pps_event() 520 overflow_cycles = div64_u64(~0ULL >> 1, clock->cycles.mult); in mlx5_init_clock()
|
/Linux-v4.19/drivers/net/ethernet/mellanox/mlx4/ |
D | en_clock.c | 257 u64 max_mul = div64_u64(ULLONG_MAX, max_val_cycles_rounded); in freq_to_shift()
|
/Linux-v4.19/drivers/gpu/drm/amd/display/dc/dcn10/ |
D | dcn10_optc.c | 143 unsigned long long req_delta_tens_of_usec = div64_u64((vsync_delta + 9999), 10000); in optc1_program_vline_interrupt() 144 unsigned long long pix_clk_hundreds_khz = div64_u64((dc_crtc_timing->pix_clk_khz + 99), 100); in optc1_program_vline_interrupt() 145 uint32_t req_delta_lines = (uint32_t) div64_u64( in optc1_program_vline_interrupt()
|
/Linux-v4.19/drivers/video/fbdev/omap2/omapfb/dss/ |
D | dsi.c | 4338 #define TO_DSI_T(x) ((u32)div64_u64((u64)x * 1000000000llu, byteclk)) in print_dsi_vm() 4369 #define TO_DISPC_T(x) ((u32)div64_u64((u64)x * 1000000000llu, pck)) in print_dispc_vm() 4398 pck = (u32)div64_u64(dsi_tput, t->bitspp); in print_dsi_dispc_vm() 4403 vm.hsw = div64_u64((u64)(t->hsa + t->hse) * pck, byteclk); in print_dsi_dispc_vm() 4404 vm.hbp = div64_u64((u64)t->hbp * pck, byteclk); in print_dsi_dispc_vm() 4405 vm.hfp = div64_u64((u64)t->hfp * pck, byteclk); in print_dsi_dispc_vm() 4570 dsi_htot = div64_u64((u64)panel_htot * byteclk, req_pck_nom); in dsi_vm_calc_blanking() 4580 dispc_htot = div64_u64((u64)dsi_htot * dispc_pck, byteclk); in dsi_vm_calc_blanking() 4603 hsa = div64_u64((u64)req_vm->hsw * byteclk, req_pck_nom); in dsi_vm_calc_blanking() 4607 hbp = div64_u64((u64)req_vm->hbp * byteclk, req_pck_nom); in dsi_vm_calc_blanking() [all …]
|
/Linux-v4.19/drivers/gpu/drm/omapdrm/dss/ |
D | dsi.c | 4339 #define TO_DSI_T(x) ((u32)div64_u64((u64)x * 1000000000llu, byteclk)) in print_dsi_vm() 4370 #define TO_DISPC_T(x) ((u32)div64_u64((u64)x * 1000000000llu, pck)) in print_dispc_vm() 4399 pck = (u32)div64_u64(dsi_tput, t->bitspp); in print_dsi_dispc_vm() 4404 vm.hsync_len = div64_u64((u64)(t->hsa + t->hse) * pck, byteclk); in print_dsi_dispc_vm() 4405 vm.hback_porch = div64_u64((u64)t->hbp * pck, byteclk); in print_dsi_dispc_vm() 4406 vm.hfront_porch = div64_u64((u64)t->hfp * pck, byteclk); in print_dsi_dispc_vm() 4574 dsi_htot = div64_u64((u64)panel_htot * byteclk, req_pck_nom); in dsi_vm_calc_blanking() 4584 dispc_htot = div64_u64((u64)dsi_htot * dispc_pck, byteclk); in dsi_vm_calc_blanking() 4607 hsa = div64_u64((u64)req_vm->hsync_len * byteclk, req_pck_nom); in dsi_vm_calc_blanking() 4611 hbp = div64_u64((u64)req_vm->hback_porch * byteclk, req_pck_nom); in dsi_vm_calc_blanking() [all …]
|
/Linux-v4.19/drivers/media/platform/ti-vpe/ |
D | sc.c | 205 lin_acc_inc = div64_u64(((u64)(src_w >> dcm_shift) - 1) << 24, lltmp); in sc_config_scaler()
|
/Linux-v4.19/drivers/powercap/ |
D | intel_rapl.c | 735 return div64_u64(value, units) * scale; in rapl_unit_xlate() 739 return div64_u64(value, scale); in rapl_unit_xlate() 1073 f = div64_u64(4 * (value - (1 << y)), 1 << y); in rapl_compute_time_window_core() 1089 value = div64_u64(value, rp->time_unit); in rapl_compute_time_window_atom()
|