/linux-6.6.21/drivers/iio/test/ |
D | iio-test-rescale.c | 19 const s32 numerator; member 38 .numerator = 1000000, 46 .numerator = -1000000, 54 .numerator = 1000000, 63 .numerator = -1000000, 72 .numerator = 42, 81 .numerator = -42, 90 .numerator = 1000000, 99 .numerator = -1000000, 108 .numerator = 1000000, [all …]
|
/linux-6.6.21/drivers/iio/adc/ |
D | qcom-vadc-common.c | 293 { .numerator = 1, .denominator = 1 }, 294 { .numerator = 1, .denominator = 3 }, 295 { .numerator = 1, .denominator = 4 }, 296 { .numerator = 1, .denominator = 6 }, 297 { .numerator = 1, .denominator = 20 }, 298 { .numerator = 1, .denominator = 8 }, 299 { .numerator = 10, .denominator = 81 }, 300 { .numerator = 1, .denominator = 10 }, 301 { .numerator = 1, .denominator = 16 }, 418 result = div64_s64(voltage, prescale->numerator); in qcom_vadc_scale_volt() [all …]
|
D | qcom-spmi-vadc.c | 129 { .numerator = 1, .denominator = 1 }, 130 { .numerator = 1, .denominator = 3 }, 131 { .numerator = 1, .denominator = 4 }, 132 { .numerator = 1, .denominator = 6 }, 133 { .numerator = 1, .denominator = 20 }, 134 { .numerator = 1, .denominator = 8 }, 135 { .numerator = 10, .denominator = 81 }, 136 { .numerator = 1, .denominator = 10 }, 410 static int vadc_prescaling_from_dt(u32 numerator, u32 denominator) in vadc_prescaling_from_dt() argument 415 if (vadc_prescale_ratios[pre].numerator == numerator && in vadc_prescaling_from_dt()
|
/linux-6.6.21/drivers/iio/afe/ |
D | iio-rescale.c | 33 *val *= rescale->numerator; in rescale_process_scale() 44 if (!check_mul_overflow(*val, rescale->numerator, &_val) && in rescale_process_scale() 54 tmp *= rescale->numerator; in rescale_process_scale() 86 tmp = (s64)abs(*val) * abs(rescale->numerator); in rescale_process_scale() 89 tmp = (s64)rem * mult + (s64)abs(*val2) * abs(rescale->numerator); in rescale_process_scale() 98 if (neg ^ ((rescale->numerator < 0) ^ (rescale->denominator < 0))) { in rescale_process_scale() 347 rescale->numerator = 1000000 / factor; in rescale_current_sense_amplifier_props() 350 factor = gcd(rescale->numerator, gain_mult); in rescale_current_sense_amplifier_props() 351 rescale->numerator /= factor; in rescale_current_sense_amplifier_props() 355 rescale->numerator *= gain_div / factor; in rescale_current_sense_amplifier_props() [all …]
|
/linux-6.6.21/drivers/gpu/drm/amd/display/dc/basics/ |
D | conversion.c | 40 int32_t numerator; in fixed_point_to_int_frac() local 50 numerator = (uint16_t)dc_fixpt_round( in fixed_point_to_int_frac() 55 numerator = dc_fixpt_floor( in fixed_point_to_int_frac() 64 if (numerator >= 0) in fixed_point_to_int_frac() 65 result = (uint16_t)numerator; in fixed_point_to_int_frac() 68 (1 << (integer_bits + fractional_bits + 1)) + numerator); in fixed_point_to_int_frac()
|
D | fixpt31_32.c | 71 struct fixed31_32 dc_fixpt_from_fraction(long long numerator, long long denominator) in dc_fixpt_from_fraction() argument 75 bool arg1_negative = numerator < 0; in dc_fixpt_from_fraction() 78 unsigned long long arg1_value = arg1_negative ? -numerator : numerator; in dc_fixpt_from_fraction()
|
/linux-6.6.21/include/trace/events/ |
D | kyber.h | 17 unsigned int percentile, unsigned int numerator, 20 TP_ARGS(dev, domain, type, percentile, numerator, denominator, samples), 27 __field( u8, numerator ) 37 __entry->numerator = numerator; 44 __entry->type, __entry->percentile, __entry->numerator,
|
/linux-6.6.21/drivers/media/i2c/et8ek8/ |
D | et8ek8_mode.c | 49 .numerator = 100, 150 .numerator = 100, 206 .numerator = 100, 262 .numerator = 100, 318 .numerator = 100, 374 .numerator = 100, 429 .numerator = 100, 485 .numerator = 100, 541 .numerator = 100,
|
/linux-6.6.21/lib/ |
D | flex_proportions.c | 137 unsigned long *numerator, unsigned long *denominator) in fprop_fraction_single() argument 160 *numerator = num; in fprop_fraction_single() 226 unsigned long *numerator, unsigned long *denominator) in fprop_fraction_percpu() argument 249 *numerator = num; in fprop_fraction_percpu() 260 unsigned long numerator, denominator; in __fprop_add_percpu_max() local 263 fprop_fraction_percpu(p, pl, &numerator, &denominator); in __fprop_add_percpu_max() 266 ((u64)numerator << FPROP_FRAC_SHIFT); in __fprop_add_percpu_max()
|
/linux-6.6.21/drivers/media/test-drivers/vivid/ |
D | vivid-kthread-touch.c | 53 unsigned int numerator; in vivid_thread_touch_cap() local 88 numerator = dev->timeperframe_tch_cap.numerator; in vivid_thread_touch_cap() 94 (HZ * numerator) / 2; in vivid_thread_touch_cap() 95 do_div(buffers_since_start, HZ * numerator); in vivid_thread_touch_cap() 119 numerators_since_start = ++buffers_since_start * numerator; in vivid_thread_touch_cap()
|
D | vivid-kthread-out.c | 149 unsigned numerator; in vivid_thread_vid_out() local 183 numerator = dev->timeperframe_vid_out.numerator; in vivid_thread_vid_out() 193 (HZ * numerator) / 2; in vivid_thread_vid_out() 194 do_div(buffers_since_start, HZ * numerator); in vivid_thread_vid_out() 219 numerators_since_start = buffers_since_start * numerator; in vivid_thread_vid_out() 225 numerators_since_start += numerator; in vivid_thread_vid_out()
|
/linux-6.6.21/drivers/media/v4l2-core/ |
D | v4l2-dv-timings.c | 369 bt->picture_aspect.numerator, in v4l2_print_dv_timings() 388 ratio.numerator = t->bt.width * t->bt.picture_aspect.denominator; in v4l2_dv_timings_aspect_ratio() 389 ratio.denominator = t->bt.height * t->bt.picture_aspect.numerator; in v4l2_dv_timings_aspect_ratio() 391 rational_best_approximation(ratio.numerator, ratio.denominator, in v4l2_dv_timings_aspect_ratio() 392 ratio.numerator, ratio.denominator, &n, &d); in v4l2_dv_timings_aspect_ratio() 393 ratio.numerator = n; in v4l2_dv_timings_aspect_ratio() 432 fps_fract.numerator = d; in v4l2_calc_timeperframe() 746 if (aspect.numerator == 0 || aspect.denominator == 0) { in v4l2_detect_gtf() 747 aspect.numerator = 16; in v4l2_detect_gtf() 750 image_width = ((image_height * aspect.numerator) / aspect.denominator); in v4l2_detect_gtf() [all …]
|
/linux-6.6.21/drivers/media/i2c/ |
D | mt9v011.c | 201 static void calc_fps(struct v4l2_subdev *sd, u32 *numerator, u32 *denominator) in calc_fps() argument 225 if (numerator && denominator) { in calc_fps() 226 *numerator = 1000; in calc_fps() 231 static u16 calc_speed(struct v4l2_subdev *sd, u32 numerator, u32 denominator) in calc_speed() argument 239 if (!numerator || !denominator) in calc_speed() 250 t_time = core->xtal * ((u64)numerator); in calc_speed() 371 &ival->interval.numerator, in mt9v011_g_frame_interval() 383 speed = calc_speed(sd, tpf->numerator, tpf->denominator); in mt9v011_s_frame_interval() 389 calc_fps(sd, &tpf->numerator, &tpf->denominator); in mt9v011_s_frame_interval()
|
D | mt9v111.c | 451 unsigned int fps = tpf->numerator ? in mt9v111_calc_frame_rate() 452 tpf->denominator / tpf->numerator : in mt9v111_calc_frame_rate() 528 tpf->numerator = 1; in mt9v111_calc_frame_rate() 729 unsigned int fps = tpf->numerator ? in mt9v111_s_frame_interval() 730 tpf->denominator / tpf->numerator : in mt9v111_s_frame_interval() 734 if (!tpf->numerator) in mt9v111_s_frame_interval() 735 tpf->numerator = 1; in mt9v111_s_frame_interval() 784 tpf->numerator = 1; in mt9v111_g_frame_interval() 841 fie->interval.numerator = 1; in mt9v111_enum_frame_interval() 1196 tpf.numerator = 1; in mt9v111_probe()
|
/linux-6.6.21/drivers/phy/freescale/ |
D | phy-fsl-imx8-mipi-dphy.c | 192 u32 lp_t, numerator, denominator; in mixel_dphy_config_from_opts() local 201 numerator = dphy_opts->hs_clk_rate; in mixel_dphy_config_from_opts() 203 get_best_ratio(&numerator, &denominator, 255, 256); in mixel_dphy_config_from_opts() 204 if (!numerator || !denominator) { in mixel_dphy_config_from_opts() 206 numerator, denominator, in mixel_dphy_config_from_opts() 211 while ((numerator < 16) && (denominator <= 128)) { in mixel_dphy_config_from_opts() 212 numerator <<= 1; in mixel_dphy_config_from_opts() 225 cfg->cm = numerator; in mixel_dphy_config_from_opts() 234 numerator, denominator); in mixel_dphy_config_from_opts() 239 dphy_opts->hs_clk_rate, ref_clk, numerator, denominator); in mixel_dphy_config_from_opts()
|
/linux-6.6.21/drivers/media/usb/uvc/ |
D | uvc_v4l2.c | 432 u32 numerator, denominator; in uvc_v4l2_get_streamparm() local 438 numerator = stream->ctrl.dwFrameInterval; in uvc_v4l2_get_streamparm() 442 v4l2_simplify_fraction(&numerator, &denominator, 8, 333); in uvc_v4l2_get_streamparm() 450 parm->parm.capture.timeperframe.numerator = numerator; in uvc_v4l2_get_streamparm() 457 parm->parm.output.timeperframe.numerator = numerator; in uvc_v4l2_get_streamparm() 483 interval = v4l2_fraction_to_interval(timeperframe.numerator, in uvc_v4l2_set_streamparm() 486 timeperframe.numerator, timeperframe.denominator, interval); in uvc_v4l2_set_streamparm() 535 timeperframe.numerator = probe.dwFrameInterval; in uvc_v4l2_set_streamparm() 537 v4l2_simplify_fraction(&timeperframe.numerator, in uvc_v4l2_set_streamparm() 1325 fival->discrete.numerator = in uvc_ioctl_enum_frameintervals() [all …]
|
/linux-6.6.21/drivers/staging/sm750fb/ |
D | sm750.h | 188 unsigned long long numerator = 1000 * 1000 * 1000 * 1000ULL; in ps_to_hz() local 190 do_div(numerator, psvalue); in ps_to_hz() 191 return (unsigned long)numerator; in ps_to_hz()
|
/linux-6.6.21/drivers/gpu/drm/amd/display/dc/dml/calcs/ |
D | bw_fixed.c | 57 struct bw_fixed bw_frc_to_fixed(int64_t numerator, int64_t denominator) in bw_frc_to_fixed() argument 60 bool arg1_negative = numerator < 0; in bw_frc_to_fixed() 71 arg1_value = abs_i64(numerator); in bw_frc_to_fixed()
|
/linux-6.6.21/include/linux/ |
D | flex_proportions.h | 60 struct fprop_local_single *pl, unsigned long *numerator, 91 struct fprop_local_percpu *pl, unsigned long *numerator,
|
/linux-6.6.21/drivers/clk/ |
D | clk-fractional-divider.c | 100 fract->numerator = m; in clk_fd_get_div() 111 if (!fract.numerator || !fract.denominator) in clk_fd_recalc_rate() 114 ret = (u64)parent_rate * fract.numerator; in clk_fd_recalc_rate() 213 *val = fract.numerator; in clk_fd_numerator_get()
|
/linux-6.6.21/drivers/media/platform/st/sti/delta/ |
D | delta-debug.c | 28 s->pixelaspect.numerator, in delta_streaminfo_str() 49 f->pixelaspect.numerator, in delta_frameinfo_str()
|
/linux-6.6.21/drivers/media/usb/pvrusb2/ |
D | pvrusb2-std.c | 230 .numerator = 1, 241 .numerator = 1001, 250 .numerator = 1001, 259 .numerator = 1001,
|
/linux-6.6.21/drivers/staging/media/atomisp/pci/ |
D | sh_css_param_shading.c | 271 bds.numerator / bds.denominator - in prepare_shading_table() 275 bds.numerator - left_cropping) * bds.numerator / bds.denominator; in prepare_shading_table() 276 top_padding = binary->info->sp.pipeline.top_cropping * bds.numerator / in prepare_shading_table()
|
/linux-6.6.21/drivers/media/platform/amphion/ |
D | venc.c | 166 fival->stepwise.min.numerator = 1; in venc_enum_frameintervals() 168 fival->stepwise.max.numerator = USHRT_MAX; in venc_enum_frameintervals() 170 fival->stepwise.step.numerator = 1; in venc_enum_frameintervals() 285 timeperframe->numerator = venc->params.frame_rate.numerator; in venc_g_parm() 308 if (!timeperframe->numerator) in venc_s_parm() 309 timeperframe->numerator = venc->params.frame_rate.numerator; in venc_s_parm() 313 venc->params.frame_rate.numerator = timeperframe->numerator; in venc_s_parm() 316 rational_best_approximation(venc->params.frame_rate.numerator, in venc_s_parm() 318 venc->params.frame_rate.numerator, in venc_s_parm() 321 venc->params.frame_rate.numerator = n; in venc_s_parm() [all …]
|
/linux-6.6.21/include/media/ |
D | v4l2-common.h | 454 ((u64)(a).numerator * (b).denominator OP \ 455 (u64)(b).numerator * (a).denominator) 546 void v4l2_simplify_fraction(u32 *numerator, u32 *denominator, 548 u32 v4l2_fraction_to_interval(u32 numerator, u32 denominator);
|