/drivers/video/fbdev/vermilion/ |
D | cr_pll.c | 105 int diff; in crvml_nearest_index() local 110 diff = clock - crvml_clocks[i]; in crvml_nearest_index() 111 diff = (diff < 0) ? -diff : diff; in crvml_nearest_index() 112 if (diff < cur_diff) { in crvml_nearest_index() 114 cur_diff = diff; in crvml_nearest_index()
|
/drivers/net/fddi/skfp/ |
D | hwt.c | 229 long diff ; in hwt_wait_time() local 244 diff = (long)(start - hwt_quick_read(smc)) ; in hwt_wait_time() 245 if (diff < 0) { in hwt_wait_time() 246 diff += interval ; in hwt_wait_time() 248 } while (diff <= duration) ; in hwt_wait_time() 251 diff = interval ; in hwt_wait_time() 256 diff += interval ; in hwt_wait_time() 265 } while (diff <= duration) ; in hwt_wait_time()
|
/drivers/gpu/drm/ |
D | drm_rect.c | 72 int diff; in drm_rect_clip_scaled() local 74 diff = clip->x1 - dst->x1; in drm_rect_clip_scaled() 75 if (diff > 0) { in drm_rect_clip_scaled() 76 int64_t tmp = src->x1 + (int64_t) diff * hscale; in drm_rect_clip_scaled() 79 diff = clip->y1 - dst->y1; in drm_rect_clip_scaled() 80 if (diff > 0) { in drm_rect_clip_scaled() 81 int64_t tmp = src->y1 + (int64_t) diff * vscale; in drm_rect_clip_scaled() 84 diff = dst->x2 - clip->x2; in drm_rect_clip_scaled() 85 if (diff > 0) { in drm_rect_clip_scaled() 86 int64_t tmp = src->x2 - (int64_t) diff * hscale; in drm_rect_clip_scaled() [all …]
|
/drivers/net/ethernet/broadcom/bnx2x/ |
D | bnx2x_stats.h | 390 DIFF_64(diff.hi, new->s##_hi, pstats->mac_stx[0].t##_hi, \ 391 diff.lo, new->s##_lo, pstats->mac_stx[0].t##_lo); \ 394 ADD_64(pstats->mac_stx[1].t##_hi, diff.hi, \ 395 pstats->mac_stx[1].t##_lo, diff.lo); \ 400 DIFF_64(diff.hi, new->s##_hi, old->s##_hi, \ 401 diff.lo, new->s##_lo, old->s##_lo); \ 402 ADD_64(estats->t##_hi, diff.hi, \ 403 estats->t##_lo, diff.lo); \ 413 #define ADD_STAT64(diff, t) \ argument 415 ADD_64(pstats->mac_stx[1].t##_hi, new->diff##_hi, \ [all …]
|
/drivers/video/fbdev/geode/ |
D | video_cs5530.c | 77 long min, diff; in cs5530_set_dclk_frequency() local 84 diff = cs5530_pll_table[i].pixclock - info->var.pixclock; in cs5530_set_dclk_frequency() 85 if (diff < 0L) diff = -diff; in cs5530_set_dclk_frequency() 86 if (diff < min) { in cs5530_set_dclk_frequency() 87 min = diff; in cs5530_set_dclk_frequency()
|
/drivers/infiniband/hw/hfi1/ |
D | affinity.c | 433 cpumask_var_t diff; in get_irq_affinity() local 474 if (!zalloc_cpumask_var(&diff, GFP_KERNEL)) in get_irq_affinity() 485 cpumask_andnot(diff, &set->mask, &set->used); in get_irq_affinity() 486 cpu = cpumask_first(diff); in get_irq_affinity() 489 free_cpumask_var(diff); in get_irq_affinity() 594 cpumask_var_t diff, hw_thread_mask, available_mask, intrs_mask; in hfi1_get_proc_affinity() local 643 ret = zalloc_cpumask_var(&diff, GFP_KERNEL); in hfi1_get_proc_affinity() 701 cpumask_andnot(diff, hw_thread_mask, &set->used); in hfi1_get_proc_affinity() 702 if (!cpumask_empty(diff)) in hfi1_get_proc_affinity() 735 cpumask_andnot(diff, available_mask, intrs_mask); in hfi1_get_proc_affinity() [all …]
|
/drivers/staging/vboxvideo/ |
D | vbva_base.c | 43 s32 diff = vbva->data_offset - vbva->free_offset; in vbva_buffer_available() local 45 return diff > 0 ? diff : vbva->data_len + diff; in vbva_buffer_available() 54 s32 diff = len - bytes_till_boundary; in vbva_buffer_place_data_at() local 56 if (diff <= 0) { in vbva_buffer_place_data_at() 62 memcpy(&vbva->data[0], (u8 *)p + bytes_till_boundary, diff); in vbva_buffer_place_data_at()
|
/drivers/media/platform/coda/ |
D | coda-h264.c | 72 int diff; in coda_h264_padding() local 74 diff = size - (size & ~0x7); in coda_h264_padding() 75 if (diff == 0) in coda_h264_padding() 78 nal_size = coda_filler_size[diff]; in coda_h264_padding()
|
/drivers/staging/rtlwifi/phydm/ |
D | phydm_adaptivity.c | 449 s8 diff; in phydm_search_pwdb_lower_bound() local 461 diff = igi_target - (s8)IGI; in phydm_search_pwdb_lower_bound() 462 th_l2h_dmc = dm->th_l2h_ini + diff; in phydm_search_pwdb_lower_bound() 714 s8 diff = 0, igi_target; in phydm_adaptivity() local 778 diff = adaptivity->adajust_igi_level - IGI; in phydm_adaptivity() 780 th_l2h_dmc = dm->th_l2h_ini - diff + igi_target; in phydm_adaptivity() 783 diff = igi_target - (s8)IGI; in phydm_adaptivity() 784 th_l2h_dmc = dm->th_l2h_ini + diff; in phydm_adaptivity() 820 s8 diff = 0; in phydm_pause_edcca() local 828 diff = adaptivity->adajust_igi_level - IGI; in phydm_pause_edcca() [all …]
|
/drivers/video/fbdev/core/ |
D | modedb.c | 646 u32 best, diff, tdiff; in fb_find_mode() local 768 diff = -1; in fb_find_mode() 787 if (score < diff) { in fb_find_mode() 788 diff = score; in fb_find_mode() 798 diff = 2 * (xres + yres); in fb_find_mode() 814 if (diff > tdiff) { in fb_find_mode() 815 diff = tdiff; in fb_find_mode() 958 u32 diff = -1; in fb_find_best_mode() local 969 if (diff > d) { in fb_find_best_mode() 970 diff = d; in fb_find_best_mode() [all …]
|
/drivers/video/fbdev/i810/ |
D | i810_gtf.c | 228 u32 i, size = 0, pixclock, wm_best = 0, min, diff; in i810_get_watermark() local 266 diff = wmark[i].freq - pixclock; in i810_get_watermark() 268 diff = pixclock - wmark[i].freq; in i810_get_watermark() 269 if (diff < min) { in i810_get_watermark() 271 min = diff; in i810_get_watermark()
|
D | i810_dvt.c | 217 u32 diff = 0, diff_best = 0xFFFFFFFF, i = 0, i_best = 0; in i810fb_find_best_mode() local 223 diff = pixclock - std_modes[i].pixclock; in i810fb_find_best_mode() 224 if (diff < diff_best) { in i810fb_find_best_mode() 226 diff_best = diff; in i810fb_find_best_mode()
|
/drivers/infiniband/core/ |
D | umem.c | 240 umem->mm->pinned_vm -= umem->diff; in ib_umem_account() 255 unsigned long diff; in ib_umem_release() local 272 diff = ib_umem_num_pages(umem); in ib_umem_release() 286 umem->diff = diff; in ib_umem_release() 294 mm->pinned_vm -= diff; in ib_umem_release()
|
/drivers/staging/rtlwifi/rtl8822be/ |
D | hw.c | 1436 static inline s8 power_diff(s8 diff) in power_diff() argument 1439 if (diff & BIT(3)) in power_diff() 1440 diff |= 0xF0; in power_diff() 1442 return diff; in power_diff() 1453 s8 diff; in _rtl8822be_read_power_value_fromprom() local 1525 diff = (hwinfo[addr] & 0xF0) >> 4; in _rtl8822be_read_power_value_fromprom() 1526 pwr2g->bw20_diff[rf][i] = power_diff(diff); in _rtl8822be_read_power_value_fromprom() 1528 diff = hwinfo[addr] & 0x0F; in _rtl8822be_read_power_value_fromprom() 1529 pwr2g->ofdm_diff[rf][i] = power_diff(diff); in _rtl8822be_read_power_value_fromprom() 1535 diff = (hwinfo[addr] & 0xF0) >> 4; in _rtl8822be_read_power_value_fromprom() [all …]
|
/drivers/net/ethernet/stmicro/stmmac/ |
D | stmmac_ptp.c | 36 u32 diff, addend; in stmmac_adjust_freq() local 48 diff = div_u64(adj, 1000000000ULL); in stmmac_adjust_freq() 49 addend = neg_adj ? (addend - diff) : (addend + diff); in stmmac_adjust_freq()
|
/drivers/gpu/drm/nouveau/nvkm/engine/disp/ |
D | nv50.c | 297 u32 calc, diff; in nv50_disp_super_2_2_dp() local 302 diff = tu_valid - calc; in nv50_disp_super_2_2_dp() 303 if (diff) { in nv50_disp_super_2_2_dp() 304 if (diff >= (symbol / 2)) { in nv50_disp_super_2_2_dp() 305 VTUf = symbol / (symbol - diff); in nv50_disp_super_2_2_dp() 306 if (symbol - (VTUf * diff)) in nv50_disp_super_2_2_dp() 319 VTUf = min((int)(symbol / diff), 15); in nv50_disp_super_2_2_dp() 323 diff = calc - tu_valid; in nv50_disp_super_2_2_dp() 334 if (diff < best_diff) { in nv50_disp_super_2_2_dp() 335 best_diff = diff; in nv50_disp_super_2_2_dp() [all …]
|
/drivers/net/ethernet/amd/xgbe/ |
D | xgbe-ptp.c | 144 u32 addend, diff; in xgbe_adjfreq() local 154 diff = div_u64(adjust, 1000000000UL); in xgbe_adjfreq() 156 addend = (neg_adjust) ? pdata->tstamp_addend - diff : in xgbe_adjfreq() 157 pdata->tstamp_addend + diff; in xgbe_adjfreq()
|
/drivers/s390/cio/ |
D | blacklist.c | 80 int diff; in pure_hex() local 82 diff = 0; in pure_hex() 85 while (diff <= max_digit) { in pure_hex() 92 diff++; in pure_hex() 95 if ((diff < min_digit) || (diff > max_digit) || (*val > max_val)) in pure_hex()
|
/drivers/virtio/ |
D | virtio_balloon.c | 404 s64 diff; in update_balloon_size_func() local 408 diff = towards_target(vb); in update_balloon_size_func() 410 if (diff > 0) in update_balloon_size_func() 411 diff -= fill_balloon(vb, diff); in update_balloon_size_func() 412 else if (diff < 0) in update_balloon_size_func() 413 diff += leak_balloon(vb, -diff); in update_balloon_size_func() 416 if (diff) in update_balloon_size_func()
|
/drivers/input/keyboard/ |
D | adc-keys.c | 40 u32 diff, closest = 0xffffffff; in adc_keys_poll() local 49 diff = abs(st->map[i].voltage - value); in adc_keys_poll() 50 if (diff < closest) { in adc_keys_poll() 51 closest = diff; in adc_keys_poll()
|
/drivers/gpu/drm/amd/amdgpu/ |
D | amdgpu_pll.c | 200 unsigned diff; in amdgpu_pll_compute() local 203 diff = abs(target_clock - (pll->reference_freq * fb_div) / in amdgpu_pll_compute() 206 if (diff < diff_best || (diff == diff_best && in amdgpu_pll_compute() 210 diff_best = diff; in amdgpu_pll_compute()
|
/drivers/cpufreq/ |
D | freq_table.c | 130 unsigned int freq, diff, i = 0; in cpufreq_table_index_unsorted() local 184 diff = abs(freq - target_freq); in cpufreq_table_index_unsorted() 185 if (diff < optimal.frequency || in cpufreq_table_index_unsorted() 186 (diff == optimal.frequency && in cpufreq_table_index_unsorted() 188 optimal.frequency = diff; in cpufreq_table_index_unsorted()
|
/drivers/staging/media/atomisp/pci/atomisp2/css2400/isp/kernels/s3a/s3a_1.0/ |
D | ia_css_s3a.host.c | 239 int sum_r, diff; in ia_css_s3a_hmem_decode() 288 diff = sum_r - count_for_3a; in ia_css_s3a_hmem_decode() 289 out_ptr[0].r -= diff; in ia_css_s3a_hmem_decode() 290 out_ptr[0].g -= diff; in ia_css_s3a_hmem_decode() 291 out_ptr[0].b -= diff; in ia_css_s3a_hmem_decode() 292 out_ptr[0].y -= diff; in ia_css_s3a_hmem_decode()
|
/drivers/gpu/drm/via/ |
D | via_dma.c | 407 uint32_t diff; in via_hook_segment() local 430 diff = (uint32_t) (ptr - reader) - dev_priv->dma_diff; in via_hook_segment() 432 while (diff == 0 && count--) { in via_hook_segment() 437 diff = (uint32_t) (ptr - reader) - dev_priv->dma_diff; in via_hook_segment() 444 diff = (uint32_t) (ptr - reader) - dev_priv->dma_diff; in via_hook_segment() 445 diff &= (dev_priv->dma_high - 1); in via_hook_segment() 446 if (diff != 0 && diff < (dev_priv->dma_high >> 1)) { in via_hook_segment() 450 } else if (diff == 0) { in via_hook_segment()
|
/drivers/gpu/drm/nouveau/nvkm/subdev/clk/ |
D | gt215.c | 189 s32 diff; in gt215_clk_info() local 207 diff = ((khz + 3000) - oclk); in gt215_clk_info() 211 if (diff < 0) { in gt215_clk_info() 238 int P, N, M, diff; in gt215_pll_info() local 246 diff = khz - ret; in gt215_pll_info() 247 if (!pll || (diff >= -2000 && diff < 3000)) { in gt215_pll_info()
|