Home
last modified time | relevance | path

Searched full:denominator (Results 1 – 25 of 294) sorted by relevance

12345678910>>...12

/linux/drivers/iio/test/
H A Diio-test-rescale.c20 const s32 denominator; member
39 .denominator = 8060,
47 .denominator = 8060,
55 .denominator = 8060,
64 .denominator = 8060,
73 .denominator = 53,
82 .denominator = 53,
91 .denominator = 8060,
100 .denominator = 8060,
109 .denominator = 8060,
[all …]
/linux/drivers/iio/afe/
H A Diio-rescale.c34 if (rescale->denominator == 1) in rescale_process_scale()
36 *val2 = rescale->denominator; in rescale_process_scale()
45 !check_mul_overflow(*val2, rescale->denominator, &_val2)) { in rescale_process_scale()
53 tmp = div_s64(tmp, rescale->denominator); in rescale_process_scale()
87 *val = div_s64_rem(tmp, abs(rescale->denominator), &rem); in rescale_process_scale()
90 tmp = div_s64(tmp, abs(rescale->denominator)); in rescale_process_scale()
98 if (neg ^ ((rescale->numerator < 0) ^ (rescale->denominator < 0))) { in rescale_process_scale()
344 * numerator/denominator from overflowing. in rescale_current_sense_amplifier_props()
348 rescale->denominator = sense / factor; in rescale_current_sense_amplifier_props()
352 rescale->denominator *= gain_mult / factor; in rescale_current_sense_amplifier_props()
[all …]
/linux/include/trace/events/
H A Dkyber.h18 unsigned int denominator, unsigned int samples),
20 TP_ARGS(dev, domain, type, percentile, numerator, denominator, samples),
28 __field( u8, denominator )
38 __entry->denominator = denominator;
45 __entry->denominator, __entry->samples)
/linux/drivers/media/platform/qcom/camss/
H A Dcamss-format.h17 .hsub[(plane)].denominator = (h_fract_den), \
19 .vsub[(plane)].denominator = (v_fract_den), \
25 * @denominator: Store the denominator part of the fraction
29 u8 denominator; member
/linux/drivers/iio/adc/
H A Dqcom-vadc-common.c293 { .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 },
417 voltage *= prescale->denominator; in qcom_vadc_scale_volt()
[all …]
H A Dqcom-spmi-vadc.c129 { .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
416 vadc_prescale_ratios[pre].denominator == denominator) in vadc_prescaling_from_dt()
/linux/lib/
H A Dflex_proportions.c21 * This formula can be straightforwardly computed by maintaining denominator
149 unsigned long *numerator, unsigned long *denominator) in fprop_fraction_percpu() argument
162 * Make fraction <= 1 and denominator > 0 even in presence of percpu in fprop_fraction_percpu()
171 *denominator = den; in fprop_fraction_percpu()
183 unsigned long numerator, denominator; in __fprop_add_percpu_max() local
186 fprop_fraction_percpu(p, pl, &numerator, &denominator); in __fprop_add_percpu_max()
188 tmp = (u64)denominator * max_frac - in __fprop_add_percpu_max()
/linux/drivers/media/test-drivers/vivid/
H A Dvivid-kthread-touch.c54 unsigned int denominator; in vivid_thread_touch_cap() local
87 denominator = dev->timeperframe_tch_cap.denominator; in vivid_thread_touch_cap()
93 buffers_since_start = (u64)jiffies_since_start * denominator + in vivid_thread_touch_cap()
131 denominator / 2; in vivid_thread_touch_cap()
132 do_div(next_jiffies_since_start, denominator); in vivid_thread_touch_cap()
H A Dvivid-kthread-out.c150 unsigned denominator; in vivid_thread_vid_out() local
184 denominator = dev->timeperframe_vid_out.denominator; in vivid_thread_vid_out()
187 denominator *= 2; in vivid_thread_vid_out()
192 buffers_since_start = (u64)jiffies_since_start * denominator + in vivid_thread_vid_out()
231 denominator / 2; in vivid_thread_vid_out()
232 do_div(next_jiffies_since_start, denominator); in vivid_thread_vid_out()
/linux/drivers/clk/
H A Dclk-fractional-divider.c13 * m (numerator) and n (denominator) values to be provided to satisfy
36 * we get the denominator to satisfy the desired range (2) and
101 fract->denominator = n; in clk_fd_get_div()
111 if (!fract.numerator || !fract.denominator) in clk_fd_recalc_rate()
115 do_div(ret, fract.denominator); in clk_fd_recalc_rate()
238 *val = fract.denominator; in clk_fd_denominator_get()
247 debugfs_create_file("denominator", 0444, dentry, hw, &clk_fd_denominator_fops); in clk_fd_debug_init()
H A Dclk-fractional-divider_test.c11 * Test the maximum denominator case for fd clock without flags.
13 * Expect the highest possible denominator to be used in order to get as close as possible to the
69 * Test the maximum denominator case for zero based fd clock.
71 * Expect the highest possible denominator to be used in order to get as close as possible to the
/linux/drivers/media/i2c/
H A Dmt9v011.c199 static void calc_fps(struct v4l2_subdev *sd, u32 *numerator, u32 *denominator) in calc_fps() argument
223 if (numerator && denominator) { in calc_fps()
225 *denominator = (u32)frames_per_ms; in calc_fps()
229 static u16 calc_speed(struct v4l2_subdev *sd, u32 numerator, u32 denominator) in calc_speed() argument
237 if (!numerator || !denominator) in calc_speed()
250 t_time += denominator / 2; in calc_speed()
251 do_div(t_time, denominator); in calc_speed()
378 &ival->interval.denominator); in mt9v011_get_frame_interval()
397 speed = calc_speed(sd, tpf->numerator, tpf->denominator); in mt9v011_set_frame_interval()
403 calc_fps(sd, &tpf->numerator, &tpf->denominator); in mt9v011_set_frame_interval()
/linux/drivers/phy/freescale/
H A Dphy-fsl-imx8-mipi-dphy.c157 * nominator, denominator.
192 u32 lp_t, numerator, denominator; in mixel_dphy_config_from_opts() local
202 denominator = ref_clk; 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()
213 denominator <<= 1; in mixel_dphy_config_from_opts()
220 i = __ffs(denominator); in mixel_dphy_config_from_opts()
223 cfg->cn = denominator >> i; in mixel_dphy_config_from_opts()
[all …]
/linux/drivers/media/v4l2-core/
H A Dv4l2-dv-timings.c370 bt->picture_aspect.denominator); 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()
394 ratio.denominator = d; in v4l2_dv_timings_aspect_ratio()
433 fps_fract.denominator = n; in v4l2_calc_timeperframe()
746 if (aspect.numerator == 0 || aspect.denominator == 0) { in v4l2_detect_gtf()
748 aspect.denominator = 9; in v4l2_detect_gtf()
750 image_width = ((image_height * aspect.numerator) / aspect.denominator); in v4l2_detect_gtf()
[all …]
/linux/drivers/media/i2c/et8ek8/
H A Det8ek8_mode.c50 .denominator = 1207
151 .denominator = 1292
207 .denominator = 3000
263 .denominator = 2988
319 .denominator = 2993
375 .denominator = 399
430 .denominator = 499
486 .denominator = 501
542 .denominator = 2500
/linux/drivers/gpu/drm/amd/display/dc/basics/
H A Dbw_fixed.c58 struct bw_fixed bw_frc_to_fixed(int64_t numerator, int64_t denominator) in bw_frc_to_fixed() argument
62 bool arg2_negative = denominator < 0; in bw_frc_to_fixed()
70 ASSERT(denominator != 0); in bw_frc_to_fixed()
73 arg2_value = abs_i64(denominator); in bw_frc_to_fixed()
/linux/drivers/gpu/drm/amd/amdgpu/
H A Damdgpu_pll.c36 * @den: denominator
38 * @den_min: minimum value for denominator
41 * denominator, but make nominator and denominator are at least as large
61 /* make sure the denominator is large enough */ in amdgpu_pll_reduce_ratio()
74 * @den: denominator
/linux/drivers/media/usb/uvc/
H A Duvc_v4l2.c432 u32 numerator, denominator; in uvc_v4l2_get_streamparm() local
441 denominator = 10000000; in uvc_v4l2_get_streamparm()
442 v4l2_simplify_fraction(&numerator, &denominator, 8, 333); in uvc_v4l2_get_streamparm()
451 parm->parm.capture.timeperframe.denominator = denominator; in uvc_v4l2_get_streamparm()
458 parm->parm.output.timeperframe.denominator = denominator; in uvc_v4l2_get_streamparm()
484 timeperframe.denominator); in uvc_v4l2_set_streamparm()
486 timeperframe.numerator, timeperframe.denominator, interval); in uvc_v4l2_set_streamparm()
536 timeperframe.denominator = 10000000; in uvc_v4l2_set_streamparm()
538 &timeperframe.denominator, 8, 333); in uvc_v4l2_set_streamparm()
1327 fival->discrete.denominator = 10000000; in uvc_ioctl_enum_frameintervals()
[all …]
/linux/drivers/media/platform/amphion/
H A Dvenc.c167 fival->stepwise.min.denominator = USHRT_MAX; in venc_enum_frameintervals()
169 fival->stepwise.max.denominator = 1; in venc_enum_frameintervals()
171 fival->stepwise.step.denominator = 1; in venc_enum_frameintervals()
286 timeperframe->denominator = venc->params.frame_rate.denominator; in venc_g_parm()
310 if (!timeperframe->denominator) in venc_s_parm()
311 timeperframe->denominator = venc->params.frame_rate.denominator; in venc_s_parm()
314 venc->params.frame_rate.denominator = timeperframe->denominator; in venc_s_parm()
317 venc->params.frame_rate.denominator, in venc_s_parm()
319 venc->params.frame_rate.denominator, in venc_s_parm()
322 venc->params.frame_rate.denominator = d; in venc_s_parm()
[all …]
/linux/include/video/
H A Dcirrus.h57 #define CL_SEQR1B 0x1b /* VCLK0 Denominator and Post-Scalar Value */
58 #define CL_SEQR1C 0x1c /* VCLK1 Denominator and Post-Scalar Value */
59 #define CL_SEQR1D 0x1d /* VCLK2 Denominator and Post-Scalar Value */
60 #define CL_SEQR1E 0x1e /* VCLK3 Denominator and Post-Scalar Value */
/linux/lib/crypto/mpi/
H A Dmpi-div.c148 /* Normalize the denominator, i.e. make its most significant bit set by in mpi_tdiv_qr()
156 /* Shift up the denominator setting the most significant bit of in mpi_tdiv_qr()
158 * the original contents of the denominator. in mpi_tdiv_qr()
177 /* The denominator is already normalized, as required. Copy it to in mpi_tdiv_qr()
/linux/drivers/media/pci/mgb4/
H A Dmgb4_io.h21 #define MGB4_PERIOD(numerator, denominator) \ argument
22 ((u32)div_u64((MGB4_HW_FREQ * (u64)(numerator)), (denominator)))
/linux/drivers/clk/mmp/
H A Dclk-frac.c19 * numerator/denominator = Fin / (Fout * factor)
63 /* calculate denominator */ in clk_factor_recalc_rate()
133 /* calculate denominator */ in clk_factor_init()
/linux/drivers/media/usb/pvrusb2/
H A Dpvrusb2-std.c231 .denominator= 25
242 .denominator= 30000
251 .denominator= 30000
260 .denominator= 30000
/linux/drivers/gpu/drm/amd/display/dc/spl/
H A Dspl_fixpt31_32.c49 struct spl_fixed31_32 spl_fixpt_from_fraction(long long numerator, long long denominator) in spl_fixpt_from_fraction() argument
54 bool arg2_negative = denominator < 0; in spl_fixpt_from_fraction()
57 unsigned long long arg2_value = arg2_negative ? -denominator : denominator; in spl_fixpt_from_fraction()

12345678910>>...12