Home
last modified time | relevance | path

Searched refs:n1 (Results 1 – 25 of 29) sorted by relevance

12

/drivers/clk/
Dclk-si570.c71 unsigned int n1; member
95 unsigned int *n1, unsigned int *hs_div) in si570_get_divs() argument
107 *n1 = ((reg[0] & N1_6_2_MASK) << 2) + ((reg[1] & N1_1_0_MASK) >> 6) + 1; in si570_get_divs()
109 if (*n1 > 1) in si570_get_divs()
110 *n1 &= ~1; in si570_get_divs()
139 err = si570_get_divs(data, &data->rfreq, &data->n1, &data->hs_div); in si570_get_defaults()
147 fdco = fout * data->n1 * data->hs_div; in si570_get_defaults()
167 reg[0] = ((data->n1 - 1) << 6) | in si570_update_rfreq()
194 unsigned int n1, hs_div; in si570_calc_divs() local
201 n1 = div_u64(div_u64(FDCO_MIN, hs_div), frequency); in si570_calc_divs()
[all …]
/drivers/clk/meson/
Dclk-dualdiv.c41 return DIV_ROUND_CLOSEST(parent_rate, p->n1); in __dualdiv_param_to_rate()
44 p->n1 * p->m1 + p->n2 * p->m2); in __dualdiv_param_to_rate()
55 setting.n1 = meson_parm_read(clk->map, &dualdiv->n1) + 1; in meson_clk_dualdiv_recalc_rate()
74 for (i = 0; table[i].n1; i++) { in __dualdiv_get_setting()
115 meson_parm_write(clk->map, &dualdiv->n1, setting->n1 - 1); in meson_clk_dualdiv_set_rate()
Dclk-dualdiv.h14 unsigned int n1; member
22 struct parm n1; member
Dg12a-aoclk.c95 .n1 = 733,
121 .n1 = {
212 .n1 = {
Dgxbb-aoclk.c79 .n1 = 733,
88 .n1 = {
Daxg-aoclk.c93 .n1 = 733,
102 .n1 = {
/drivers/media/pci/cobalt/
Dcobalt-cpld.c124 unsigned mult, hsdiv, n1; member
236 u8 n1, hsdiv; in cobalt_cpld_set_freq() local
259 n1 = multipliers[i_best].n1 - 1; in cobalt_cpld_set_freq()
267 regs[0] = (hsdiv << 5) | (n1 >> 2); in cobalt_cpld_set_freq()
268 regs[1] = ((n1 & 0x3) << 6) | (rfreq >> 32); in cobalt_cpld_set_freq()
/drivers/mfd/
Dpcf50633-core.c85 int n, n1, idx = 0; in dump_regs_show() local
97 for (n1 = 0; n1 < sizeof(dump); n1++) in dump_regs_show()
100 dump[n1] = 0x00; in dump_regs_show()
102 dump[n1] = pcf50633_reg_read(pcf, n + n1); in dump_regs_show()
/drivers/md/bcache/
Dbtree.c1381 struct bset *n1 = btree_bset_first(new_nodes[i]); in btree_gc_coalesce() local
1391 if (__set_blocks(n1, n1->keys + keys + in btree_gc_coalesce()
1408 if (__set_blocks(n1, n1->keys + n2->keys, in btree_gc_coalesce()
1418 BUG_ON(__set_blocks(n1, n1->keys + keys, block_bytes(b->c->cache)) > in btree_gc_coalesce()
1424 memcpy(bset_bkey_last(n1), in btree_gc_coalesce()
1428 n1->keys += keys; in btree_gc_coalesce()
1429 r[i].keys = n1->keys; in btree_gc_coalesce()
2213 struct btree *n1, *n2 = NULL, *n3 = NULL; in btree_split() local
2228 n1 = btree_node_alloc_replacement(b, op); in btree_split()
2229 if (IS_ERR(n1)) in btree_split()
[all …]
/drivers/media/tuners/
Dmc44s803.c205 u32 r1, r2, n1, n2, lo1, lo2, freq, val; in mc44s803_set_params() local
213 n1 = (c->frequency + MC44S803_IF1 + 500000) / 1000000; in mc44s803_set_params()
214 freq = MC44S803_OSC / r1 * n1; in mc44s803_set_params()
215 lo1 = ((60 * n1) + (r1 / 2)) / r1; in mc44s803_set_params()
234 MC44S803_REG_SM(n1-2, MC44S803_LO1); in mc44s803_set_params()
Dmt20xx.c71 int n1=1,n2,f; in mt2032_spurcheck() local
82 n2=-n1; in mt2032_spurcheck()
83 f=n1*(f1-f2); in mt2032_spurcheck()
87 tuner_dbg("spurtest n1=%d n2=%d ftest=%d\n",n1,n2,f); in mt2032_spurcheck()
90 tuner_dbg("mt2032 spurcheck triggered: %d\n",n1); in mt2032_spurcheck()
92 n1++; in mt2032_spurcheck()
93 } while (n1<5); in mt2032_spurcheck()
/drivers/staging/fbtft/
Dfb_ssd1325.c139 u8 n1; in write_vmem() local
148 n1 = rgb565_to_g16(vmem16[y * par->info->var.xres + x]); in write_vmem()
151 *buf = (n1 << 4) | n2; in write_vmem()
/drivers/clk/baikal-t1/
Dccu-pll.c172 unsigned long num, denom, n1, d1, nri; in ccu_pll_calc_factors() local
209 n1 = nf_max; in ccu_pll_calc_factors()
212 n1 = 1; in ccu_pll_calc_factors()
216 &n1, &d1); in ccu_pll_calc_factors()
220 freq = ccu_pll_calc_freq(parent_rate, nri, n1, d1); in ccu_pll_calc_factors()
225 *nf = n1; in ccu_pll_calc_factors()
/drivers/video/fbdev/savage/
Dsavagefb_driver.c421 unsigned char n1, n2, best_n1=16+2, best_n2=2, best_m=125+2; in SavageCalcClock() local
436 for (n1=min_n1+2; n1<=max_n1+2; n1++) { in SavageCalcClock()
437 m = (freq * n1 * (1 << n2) + HALF_BASE_FREQ) / in SavageCalcClock()
441 if ((m * BASE_FREQ >= freq_min * n1) && in SavageCalcClock()
442 (m * BASE_FREQ <= freq_max * n1)) { in SavageCalcClock()
443 diff = freq * (1 << n2) * n1 - BASE_FREQ * m; in SavageCalcClock()
449 best_n1 = n1; in SavageCalcClock()
468 unsigned char n1, n2; in common_calc_clock() local
474 for (n1 = min_n1+2; n1 <= max_n1+2; n1++) { in common_calc_clock()
475 m = (freq * n1 * (1 << n2) + HALF_BASE_FREQ) / in common_calc_clock()
[all …]
/drivers/ssb/
Dmain.c846 u32 n1, n2, clock, m1, m2, m3, mc; in ssb_calc_clock_rate() local
848 n1 = (n & SSB_CHIPCO_CLK_N1); in ssb_calc_clock_rate()
860 n1 = clkfactor_f6_resolve(n1); in ssb_calc_clock_rate()
864 n1 += SSB_CHIPCO_CLK_T2_BIAS; in ssb_calc_clock_rate()
866 WARN_ON(!((n1 >= 2) && (n1 <= 7))); in ssb_calc_clock_rate()
878 clock = SSB_CHIPCO_CLK_BASE2 * n1 * n2; in ssb_calc_clock_rate()
881 clock = SSB_CHIPCO_CLK_BASE1 * n1 * n2; in ssb_calc_clock_rate()
/drivers/media/cec/platform/meson/
Dao-cec-g12a.c228 unsigned long n1; in meson_ao_cec_g12a_dualdiv_clk_recalc_rate() local
240 n1 = FIELD_GET(CECB_CLK_CNTL_N1, reg0) + 1; in meson_ao_cec_g12a_dualdiv_clk_recalc_rate()
246 f1 = DIV_ROUND_CLOSEST(parent_rate, n1); in meson_ao_cec_g12a_dualdiv_clk_recalc_rate()
255 n1 = FIELD_GET(CECB_CLK_CNTL_N1, reg0) + 1; in meson_ao_cec_g12a_dualdiv_clk_recalc_rate()
257 return DIV_ROUND_CLOSEST(parent_rate, n1); in meson_ao_cec_g12a_dualdiv_clk_recalc_rate()
/drivers/crypto/ux500/cryp/
Dcryp_core.c131 u8 n1; in swap_bits_in_byte() local
136 n1 = ((b & R_SHIFT_4_MASK) >> 4) | (b & ~(R_SHIFT_4_MASK >> 4)); in swap_bits_in_byte()
138 n1 = ((n1 & R_SHIFT_2_MASK) >> 2) | (n1 & ~(R_SHIFT_2_MASK >> 2)); in swap_bits_in_byte()
140 n1 = (n1 & R_SHIFT_1_MASK) >> 1; in swap_bits_in_byte()
150 return n1 | n2; in swap_bits_in_byte()
/drivers/of/
Dresolver.c142 const char *n1 = kbasename(dn1->full_name); in node_name_cmp() local
145 return of_node_cmp(n1, n2); in node_name_cmp()
Dunittest.c816 struct device_node *n1, *n2, *n21, *nchangeset, *nremove, *parent, *np; in of_unittest_changeset() local
819 n1 = __of_node_dup(NULL, "n1"); in of_unittest_changeset()
820 unittest(n1, "testcase setup failure\n"); in of_unittest_changeset()
848 n1->parent = parent; in of_unittest_changeset()
857 unittest(!of_changeset_attach_node(&chgset, n1), "fail attach n1\n"); in of_unittest_changeset()
858 unittest(!of_changeset_add_property(&chgset, n1, ppname_n1), "fail add prop name\n"); in of_unittest_changeset()
885 of_node_put(n1); in of_unittest_changeset()
/drivers/pinctrl/
Ddevicetree.c52 struct pinctrl_dt_map *dt_map, *n1; in pinctrl_dt_free_maps() local
54 list_for_each_entry_safe(dt_map, n1, &p->dt_maps, node) { in pinctrl_dt_free_maps()
/drivers/thermal/
Dimx_thermal.c435 int n1; in imx_init_calib() local
471 n1 = ocotp_ana1 >> 20; in imx_init_calib()
475 do_div(temp64, 15423 * n1 - 4148468); in imx_init_calib()
477 data->c2 = n1 * data->c1 + 28581; in imx_init_calib()
/drivers/media/usb/gspca/
Dt613.c577 static const u8 n1[] = in sd_init() local
607 reg_w_buf(gspca_dev, n1, sizeof n1); in sd_init()
/drivers/comedi/
Dcomedi_fops.c2502 unsigned int wp, n1, n2; in comedi_write() local
2542 n1 = min(n, async->prealloc_bufsz - wp); in comedi_write()
2543 n2 = n - n1; in comedi_write()
2544 m = copy_from_user(async->prealloc_buf + wp, buf, n1); in comedi_write()
2548 m = copy_from_user(async->prealloc_buf, buf + n1, n2); in comedi_write()
2637 unsigned int rp, n1, n2; in comedi_read() local
2676 n1 = min(n, async->prealloc_bufsz - rp); in comedi_read()
2677 n2 = n - n1; in comedi_read()
2678 m = copy_to_user(buf, async->prealloc_buf + rp, n1); in comedi_read()
2682 m = copy_to_user(buf + n1, async->prealloc_buf, n2); in comedi_read()
/drivers/video/fbdev/intelfb/
Dintelfbhw.c940 u32 m1, m2, n, p1, p2, n1, testm; in calc_pll_params() local
1010 n1 = n - 2; in calc_pll_params()
1014 m, m1, m2, n, n1, p, p1, p2, in calc_pll_params()
1016 calc_vclock(index, m1, m2, n1, p1, p2, 0), in calc_pll_params()
1020 *retn = n1; in calc_pll_params()
1023 *retclock = calc_vclock(index, m1, m2, n1, p1, p2, 0); in calc_pll_params()
/drivers/hid/
Dhid-core.c2249 int n1 = strrchr(hdev_a->phys, separator) - hdev_a->phys; in hid_compare_device_paths() local
2252 if (n1 != n2 || n1 <= 0 || n2 <= 0) in hid_compare_device_paths()
2255 return !strncmp(hdev_a->phys, hdev_b->phys, n1); in hid_compare_device_paths()

12