Home
last modified time | relevance | path

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

12

/drivers/i2c/busses/
Di2c-designware-platdrv.c180 dev->clk_freq = 400000; in dw_i2c_plat_probe()
183 dev->clk_freq = pdata->i2c_scl_freq; in dw_i2c_plat_probe()
192 &dev->clk_freq); in dw_i2c_plat_probe()
197 dev->clk_freq = acpi_speed; in dw_i2c_plat_probe()
206 if (dev->clk_freq != 100000 && dev->clk_freq != 400000 in dw_i2c_plat_probe()
207 && dev->clk_freq != 1000000 && dev->clk_freq != 3400000) { in dw_i2c_plat_probe()
228 switch (dev->clk_freq) { in dw_i2c_plat_probe()
Di2c-sun6i-p2wi.c189 u32 clk_freq = 100000; in p2wi_probe() local
197 of_property_read_u32(np, "clock-frequency", &clk_freq); in p2wi_probe()
198 if (clk_freq > P2WI_MAX_FREQ) { in p2wi_probe()
201 clk_freq); in p2wi_probe()
291 clk_div = parent_clk_freq / clk_freq; in p2wi_probe()
Di2c-nomadik.c179 u32 clk_freq; member
402 div = (dev->clk_freq > 100000) ? 3 : 2; in setup_i2c_controller()
412 brcr2 = (i2c_clk/(dev->clk_freq * div)) & 0xffff; in setup_i2c_controller()
954 if (of_property_read_u32(np, "clock-frequency", &nmk->clk_freq)) in nmk_i2c_of_probe()
955 nmk->clk_freq = 100000; in nmk_i2c_of_probe()
958 if (nmk->clk_freq <= 100000) in nmk_i2c_of_probe()
Di2c-designware-core.h105 u32 clk_freq; member
Di2c-qup.c1368 u32 clk_freq = 100000; in qup_i2c_probe() local
1379 of_property_read_u32(node, "clock-frequency", &clk_freq); in qup_i2c_probe()
1438 if (!clk_freq || clk_freq > 400000) { in qup_i2c_probe()
1440 clk_freq); in qup_i2c_probe()
1516 fs_div = ((src_clk_freq / clk_freq) / 2) - 3; in qup_i2c_probe()
1524 one_bit_t = (USEC_PER_SEC / clk_freq) + 1; in qup_i2c_probe()
Di2c-jz4780.c737 unsigned int clk_freq = 0; in jz4780_i2c_probe() local
773 &clk_freq); in jz4780_i2c_probe()
779 i2c->speed = clk_freq / 1000; in jz4780_i2c_probe()
/drivers/pwm/
Dpwm-atmel-hlcdc.c60 unsigned long clk_freq; in atmel_hlcdc_pwm_config() local
66 clk_freq = clk_get_rate(new_clk); in atmel_hlcdc_pwm_config()
67 if (!clk_freq) in atmel_hlcdc_pwm_config()
71 do_div(clk_period_ns, clk_freq); in atmel_hlcdc_pwm_config()
78 clk_freq = clk_get_rate(new_clk); in atmel_hlcdc_pwm_config()
79 if (!clk_freq) in atmel_hlcdc_pwm_config()
83 do_div(clk_period_ns, clk_freq); in atmel_hlcdc_pwm_config()
/drivers/hwmon/
Dg762.c139 u32 clk_freq; member
183 static inline unsigned int rpm_from_cnt(u8 cnt, u32 clk_freq, u16 p, in rpm_from_cnt() argument
189 return (clk_freq * 30 * gear_mult) / ((cnt ? cnt : 1) * p * clk_div); in rpm_from_cnt()
196 static inline unsigned char cnt_from_rpm(unsigned long rpm, u32 clk_freq, u16 p, in cnt_from_rpm() argument
199 unsigned long f1 = clk_freq * 30 * gear_mult; in cnt_from_rpm()
279 data->clk_freq = val; in do_set_clk_freq()
525 data->set_cnt = cnt_from_rpm(val, data->clk_freq, in do_set_fan_target()
600 unsigned long clk_freq; in g762_of_clock_enable() local
619 clk_freq = clk_get_rate(clk); in g762_of_clock_enable()
620 ret = do_set_clk_freq(&client->dev, clk_freq); in g762_of_clock_enable()
[all …]
/drivers/net/wireless/ti/wl18xx/
Dmain.c725 u16 clk_freq; in wl18xx_set_clk() local
734 ret = wl18xx_top_reg_read(wl, PRIMARY_CLK_DETECT, &clk_freq); in wl18xx_set_clk()
738 wl1271_debug(DEBUG_BOOT, "clock freq %d (%d, %d, %d, %d, %s)", clk_freq, in wl18xx_set_clk()
739 wl18xx_clk_table[clk_freq].n, wl18xx_clk_table[clk_freq].m, in wl18xx_set_clk()
740 wl18xx_clk_table[clk_freq].p, wl18xx_clk_table[clk_freq].q, in wl18xx_set_clk()
741 wl18xx_clk_table[clk_freq].swallow ? "swallow" : "spit"); in wl18xx_set_clk()
745 wl18xx_clk_table_coex[clk_freq].n); in wl18xx_set_clk()
750 wl18xx_clk_table_coex[clk_freq].m); in wl18xx_set_clk()
761 wl18xx_clk_table[clk_freq].n); in wl18xx_set_clk()
766 wl18xx_clk_table[clk_freq].m); in wl18xx_set_clk()
[all …]
/drivers/spi/
Dspi-pl022.c1723 ssp_clock_params * clk_freq) in calculate_effective_freq() argument
1787 clk_freq->cpsdvsr = (u8) (best_cpsdvsr & 0xFF); in calculate_effective_freq()
1788 clk_freq->scr = (u8) (best_scr & 0xFF); in calculate_effective_freq()
1793 clk_freq->cpsdvsr, clk_freq->scr); in calculate_effective_freq()
1832 struct ssp_clock_params clk_freq = { .cpsdvsr = 0, .scr = 0}; in pl022_setup() local
1891 if ((0 == chip_info->clk_freq.cpsdvsr) in pl022_setup()
1892 && (0 == chip_info->clk_freq.scr)) { in pl022_setup()
1895 &clk_freq); in pl022_setup()
1899 memcpy(&clk_freq, &chip_info->clk_freq, sizeof(clk_freq)); in pl022_setup()
1900 if ((clk_freq.cpsdvsr % 2) != 0) in pl022_setup()
[all …]
Dspi-mxs.c463 int devid, clk_freq; in mxs_spi_probe() local
488 &clk_freq); in mxs_spi_probe()
490 clk_freq = clk_freq_default; in mxs_spi_probe()
528 clk_set_rate(ssp->clk, clk_freq); in mxs_spi_probe()
/drivers/bus/
Dsunxi-rsb.c630 u32 clk_delay, clk_freq = 3000000; in sunxi_rsb_probe() local
634 of_property_read_u32(np, "clock-frequency", &clk_freq); in sunxi_rsb_probe()
635 if (clk_freq > RSB_MAX_FREQ) { in sunxi_rsb_probe()
638 clk_freq); in sunxi_rsb_probe()
702 clk_div = p_clk_freq / clk_freq / 2; in sunxi_rsb_probe()
/drivers/media/pci/cx25821/
Dcx25821-cards.c38 .clk_freq = 0,
Dcx25821.h152 u32 clk_freq; member
253 u32 clk_freq; member
/drivers/scsi/
Dmac53c94.c48 int clk_freq; member
133 writeb(CLKF_VAL(state->clk_freq), &regs->clk_factor); in mac53c94_init()
460 state->clk_freq = 25000000; in mac53c94_probe()
462 state->clk_freq = *(int *)clkprop; in mac53c94_probe()
Dmesh.c171 int clk_freq; member
657 v = (ms->clk_freq / 5000) * period; in set_sdtr()
662 tr = (ms->clk_freq + 250000) / 500000; in set_sdtr()
668 tr = ((ms->clk_freq / (v + 2)) + 199999) / 200000; in set_sdtr()
1937 ms->clk_freq = *cfp; in mesh_probe()
1940 ms->clk_freq = 50000000; in mesh_probe()
1946 minper = 1000000000 / (ms->clk_freq / 5); /* ns */ in mesh_probe()
/drivers/media/pci/cobalt/
Dm00473_freewheel_memmap_package.h33 uint32_t clk_freq; /* Reg 0x0018 */ member
Dcobalt-v4l2.c303 u32 clk_freq; in cobalt_start_streaming() local
327 clk_freq = ioread32(&fw->clk_freq); in cobalt_start_streaming()
328 iowrite32(clk_freq / 1000000, &clkloss->ref_clk_cnt_val); in cobalt_start_streaming()
335 iowrite32(div_u64((u64)clk_freq * tot_size, bt->pixelclock), in cobalt_start_streaming()
/drivers/staging/greybus/
Dgb-camera.h47 unsigned int clk_freq; member
Dcamera.c386 unsigned int clk_freq; in gb_camera_setup_data_connection() local
422 clk_freq = resp->data_rate / 2 / GB_CAMERA_CSI_NUM_DATA_LANES; in gb_camera_setup_data_connection()
423 clk_freq = clamp(clk_freq + GB_CAMERA_CSI_CLK_FREQ_MARGIN, in gb_camera_setup_data_connection()
426 csi_cfg.csi_clk_freq = clk_freq; in gb_camera_setup_data_connection()
444 csi_params->clk_freq = csi_cfg.csi_clk_freq; in gb_camera_setup_data_connection()
/drivers/staging/media/st-cec/
Dstih-cec.c141 unsigned long clk_freq = clk_get_rate(cec->clk); in stih_cec_adap_enable() local
142 u32 cec_clk_div = clk_freq / 10000; in stih_cec_adap_enable()
/drivers/mmc/host/
Dtifm_sd.c98 unsigned int clk_freq; member
603 ((1000000000UL / host->clk_freq) * host->clk_div); in tifm_sd_set_data_timeout()
834 host->clk_freq = 20000000; in tifm_sd_ios()
840 host->clk_freq = 24000000; in tifm_sd_ios()
893 host->clk_freq = 20000000; in tifm_sd_initialize_host()
/drivers/media/pci/cx23885/
Dcx23885.h220 u32 clk_freq; member
373 u32 clk_freq; member
Dcx23885-core.c844 dev->clk_freq = 25000000; in cx23885_dev_setup()
850 dev->clk_freq = 28000000; in cx23885_dev_setup()
872 if (cx23885_boards[dev->board].clk_freq > 0) in cx23885_dev_setup()
873 dev->clk_freq = cx23885_boards[dev->board].clk_freq; in cx23885_dev_setup()
/drivers/net/ethernet/freescale/fman/
Dfman.c549 u16 clk_freq; member
565 u16 clk_freq; /* FMan clock freq (In Mhz) */ member
819 iowrite32be((cfg->dma_watchdog * cfg->clk_freq), &dma_rg->fmdmwcr); in dma_init()
1785 fman->state->fm_clk_freq = fman->dts_params.clk_freq; in fman_config()
2049 cfg->clk_freq = fman->state->fm_clk_freq; in fman_init()
2803 fman->dts_params.clk_freq = DIV_ROUND_UP(clk_rate, 1000000); in read_dts_node()

12