Home
last modified time | relevance | path

Searched refs:period (Results 1 – 25 of 153) sorted by relevance

1234567

/drivers/input/misc/
Dpwm-beeper.c26 unsigned long period; member
36 unsigned long period; in pwm_beeper_event() local
55 period = HZ_TO_NANOSECONDS(value); in pwm_beeper_event()
56 ret = pwm_config(beeper->pwm, period / 2, period); in pwm_beeper_event()
62 beeper->period = period; in pwm_beeper_event()
152 if (beeper->period) in pwm_beeper_suspend()
162 if (beeper->period) { in pwm_beeper_resume()
163 pwm_config(beeper->pwm, beeper->period / 2, beeper->period); in pwm_beeper_resume()
/drivers/watchdog/
Dbooke_wdt.c56 static unsigned long long period_to_sec(unsigned int period) in period_to_sec() argument
58 unsigned long long tmp = 1ULL << (64 - period); in period_to_sec()
77 unsigned int period; in sec_to_period() local
78 for (period = 63; period > 0; period--) { in sec_to_period()
79 if (period_to_sec(period) >= secs) in sec_to_period()
80 return period; in sec_to_period()
89 static unsigned long long period_to_sec(unsigned int period) in period_to_sec() argument
91 return period; in period_to_sec()
/drivers/usb/host/whci/
Dpzl.c28 static void update_pzl_pointers(struct whc *whc, int period, u64 addr) in update_pzl_pointers() argument
30 switch (period) { in update_pzl_pointers()
78 int period; in qset_insert_in_sw_list() local
80 period = qset_get_period(whc, qset); in qset_insert_in_sw_list()
83 list_move(&qset->list_node, &whc->periodic_list[period]); in qset_insert_in_sw_list()
210 int period; in update_pzl_hw_view() local
213 for (period = 0; period < 5; period++) { in update_pzl_hw_view()
214 list_for_each_entry_safe(qset, t, &whc->periodic_list[period], list_node) { in update_pzl_hw_view()
219 update_pzl_pointers(whc, period, tmp_qh); in update_pzl_hw_view()
236 int period; in scan_periodic_work() local
[all …]
Ddebug.c125 int period; in pzl_print() local
127 for (period = 0; period < 5; period++) { in pzl_print()
128 seq_printf(s, "Period %d\n", period); in pzl_print()
129 list_for_each_entry(qset, &whc->periodic_list[period], list_node) { in pzl_print()
/drivers/scsi/
Dscsi_transport_spi.c422 static int period_to_str(char *buf, int period) in period_to_str() argument
426 if (period < 0 || period > 0xff) { in period_to_str()
428 } else if (period <= SPI_STATIC_PPR) { in period_to_str()
429 picosec = ppr_to_ps[period]; in period_to_str()
431 picosec = period * 4000; in period_to_str()
444 show_spi_transport_period_helper(char *buf, int period) in show_spi_transport_period_helper() argument
446 int len = period_to_str(buf, period); in show_spi_transport_period_helper()
456 int j, picosec, period = -1; in store_spi_transport_period_helper() local
474 period = j; in store_spi_transport_period_helper()
478 if (period == -1) in store_spi_transport_period_helper()
[all …]
/drivers/char/hw_random/
Dtimeriomem-rng.c39 unsigned int period; member
77 delay = priv->period - (delay % priv->period); in timeriomem_rng_data_read()
103 int period; in timeriomem_rng_probe() local
134 period = i; in timeriomem_rng_probe()
141 period = pdata->period; in timeriomem_rng_probe()
143 priv->period = usecs_to_jiffies(period); in timeriomem_rng_probe()
144 if (priv->period < 1) { in timeriomem_rng_probe()
184 priv->io_base, period); in timeriomem_rng_probe()
/drivers/pwm/
Dpwm-jz4740.c113 unsigned long period, duty; in jz4740_pwm_config() local
120 period = tmp; in jz4740_pwm_config()
122 while (period > 0xffff && prescaler < 6) { in jz4740_pwm_config()
123 period >>= 2; in jz4740_pwm_config()
130 tmp = (unsigned long long)period * duty_ns; in jz4740_pwm_config()
132 duty = period - tmp; in jz4740_pwm_config()
134 if (duty >= period) in jz4740_pwm_config()
135 duty = period - 1; in jz4740_pwm_config()
143 jz4740_timer_set_period(pwm->hwpwm, period); in jz4740_pwm_config()
Dpwm-bfin.c69 unsigned long period, duty; in bfin_pwm_config() local
74 period = val; in bfin_pwm_config()
76 val = (unsigned long long)period * duty_ns; in bfin_pwm_config()
78 duty = period - val; in bfin_pwm_config()
80 if (duty >= period) in bfin_pwm_config()
81 duty = period - 1; in bfin_pwm_config()
85 set_gptimer_period(priv->pin, period); in bfin_pwm_config()
Dpwm-atmel-tcb.c37 unsigned period; /* PWM period expressed in clk cycles */ member
88 tcbpwm->period = 0; in atmel_tcb_pwm_request()
106 tcbpwm->period = __raw_readl(regs + ATMEL_TC_REG(group, RC)); in atmel_tcb_pwm_request()
238 if (tcbpwm->duty != tcbpwm->period && tcbpwm->duty > 0) { in atmel_tcb_pwm_enable()
259 __raw_writel(tcbpwm->period, regs + ATMEL_TC_REG(group, RC)); in atmel_tcb_pwm_enable()
279 unsigned period; in atmel_tcb_pwm_config() local
316 period = div_u64(period_ns, min); in atmel_tcb_pwm_config()
336 atcbpwm->duty != atcbpwm->period) && in atmel_tcb_pwm_config()
337 (atcbpwm->div != i || atcbpwm->period != period)) { in atmel_tcb_pwm_config()
343 tcbpwm->period = period; in atmel_tcb_pwm_config()
/drivers/net/wireless/iwlwifi/dvm/
Dpower.c158 enum iwl_power_level lvl, int period) in iwl_static_sleep_cmd() argument
168 if (period <= IWL_DTIM_RANGE_1_MAX) in iwl_static_sleep_cmd()
170 if (period <= IWL_DTIM_RANGE_0_MAX) in iwl_static_sleep_cmd()
174 if (period <= IWL_DTIM_RANGE_1_MAX) in iwl_static_sleep_cmd()
176 if (period <= IWL_DTIM_RANGE_0_MAX) in iwl_static_sleep_cmd()
185 if (period == 0) { in iwl_static_sleep_cmd()
187 period = 1; in iwl_static_sleep_cmd()
202 cpu_to_le32(period * (skip + 1)); in iwl_static_sleep_cmd()
205 if (slp_itrvl > period) in iwl_static_sleep_cmd()
207 cpu_to_le32((slp_itrvl / period) * period); in iwl_static_sleep_cmd()
[all …]
/drivers/leds/trigger/
Dledtrig-heartbeat.c28 unsigned int period; member
53 heartbeat_data->period = 300 + in led_heartbeat_function()
55 heartbeat_data->period = in led_heartbeat_function()
56 msecs_to_jiffies(heartbeat_data->period); in led_heartbeat_function()
62 delay = heartbeat_data->period / 4 - msecs_to_jiffies(70); in led_heartbeat_function()
71 delay = heartbeat_data->period - heartbeat_data->period / 4 - in led_heartbeat_function()
/drivers/usb/host/
Dehci-sched.c315 unsigned period, in tt_available() argument
322 if ((period == 0) || (uframe >= 7)) /* error */ in tt_available()
325 for (; frame < ehci->periodic_size; frame += period) { in tt_available()
384 unsigned period, in tt_no_collision() argument
390 if (period == 0) /* error */ in tt_no_collision()
397 for (; frame < ehci->periodic_size; frame += period) { in tt_no_collision()
492 unsigned period = qh->period; in qh_link_periodic() local
496 period, hc32_to_cpup(ehci, &qh->hw->hw_info2) in qh_link_periodic()
501 if (period == 0) in qh_link_periodic()
502 period = 1; in qh_link_periodic()
[all …]
/drivers/md/
Dfaulty.c86 int period[Modes]; member
96 if (conf->period[mode] == 0 && in check_mode()
102 if (conf->period[mode]) in check_mode()
103 atomic_set(&conf->counters[mode], conf->period[mode]); in check_mode()
231 n, conf->period[WriteTransient]); in status()
235 n, conf->period[ReadTransient]); in status()
239 n, conf->period[WritePersistent]); in status()
243 n, conf->period[ReadPersistent]); in status()
248 n, conf->period[ReadFixable]); in status()
272 conf->period[i] = 0; in reshape()
[all …]
/drivers/mmc/core/
Dsdio_irq.c86 unsigned long period, idle_period; in sdio_irq_thread() local
98 period = (host->caps & MMC_CAP_SDIO_IRQ) ? in sdio_irq_thread()
102 mmc_hostname(host), period); in sdio_irq_thread()
143 period /= 2; in sdio_irq_thread()
145 period++; in sdio_irq_thread()
146 if (period > idle_period) in sdio_irq_thread()
147 period = idle_period; in sdio_irq_thread()
158 schedule_timeout(period); in sdio_irq_thread()
/drivers/scsi/aic7xxx/
Daic79xx_osm.c645 spi_min_period(starget) = tinfo->user.period; in ahd_linux_target_alloc()
1720 if (tinfo->curr.period != tinfo->goal.period in ahd_send_async()
1745 if (tinfo->curr.period == spi_period(starget) in ahd_send_async()
1752 spi_period(starget) = tinfo->curr.period; in ahd_send_async()
2414 static void ahd_linux_set_period(struct scsi_target *starget, int period) in ahd_linux_set_period() argument
2431 printk("%s: set period to %d\n", ahd_name(ahd), period); in ahd_linux_set_period()
2436 if (period < 8) in ahd_linux_set_period()
2437 period = 8; in ahd_linux_set_period()
2438 if (period < 10) { in ahd_linux_set_period()
2441 if (period == 8) in ahd_linux_set_period()
[all …]
Daic7xxx_osm.c1653 if (tinfo->curr.period != tinfo->goal.period in ahc_send_async()
1677 if (tinfo->curr.period == spi_period(starget) in ahc_send_async()
1684 spi_period(starget) = tinfo->curr.period; in ahc_send_async()
2372 static void ahc_linux_set_period(struct scsi_target *starget, int period) in ahc_linux_set_period() argument
2390 if (period < 9) in ahc_linux_set_period()
2391 period = 9; /* 12.5ns is our minimum */ in ahc_linux_set_period()
2392 if (period == 9) { in ahc_linux_set_period()
2397 period = 10; in ahc_linux_set_period()
2409 syncrate = ahc_find_syncrate(ahc, &period, &ppr_options, AHC_SYNCRATE_DT); in ahc_linux_set_period()
2411 ahc_set_syncrate(ahc, &devinfo, syncrate, period, offset, in ahc_linux_set_period()
[all …]
/drivers/leds/
Dleds-pwm.c33 unsigned int period; member
47 pwm_config(led_dat->pwm, new_duty, led_dat->period); in __led_pwm_set()
69 unsigned int period = led_dat->period; in led_pwm_set() local
71 led_dat->duty = brightness * period / max; in led_pwm_set()
115 led_dat->period = pwm_get_period(led_dat->pwm); in led_pwm_create_of()
177 led_dat->period = cur_led->pwm_period_ns; in led_pwm_probe()
Dleds-lp3944.c108 static int lp3944_dim_set_period(struct i2c_client *client, u8 dim, u16 period) in lp3944_dim_set_period() argument
122 if (period > LP3944_PERIOD_MAX) in lp3944_dim_set_period()
125 psc_value = (period * 255) / LP3944_PERIOD_MAX; in lp3944_dim_set_period()
232 u16 period; in lp3944_led_set_blink() local
249 period = (*delay_on) + (*delay_off); in lp3944_led_set_blink()
252 duty_cycle = 100 * (*delay_on) / period; in lp3944_led_set_blink()
267 err = lp3944_dim_set_period(led->client, LP3944_DIM0, period); in lp3944_led_set_blink()
/drivers/video/backlight/
Dpwm_bl.c27 unsigned int period; member
53 pwm_config(pb->pwm, 0, pb->period); in pwm_backlight_update_status()
66 (duty_cycle * (pb->period - pb->lth_brightness) / max); in pwm_backlight_update_status()
67 pwm_config(pb->pwm, duty_cycle, pb->period); in pwm_backlight_update_status()
231 pb->period = pwm_get_period(pb->pwm); in pwm_backlight_probe()
232 pb->lth_brightness = data->lth_brightness * (pb->period / max); in pwm_backlight_probe()
270 pwm_config(pb->pwm, 0, pb->period); in pwm_backlight_remove()
285 pwm_config(pb->pwm, 0, pb->period); in pwm_backlight_suspend()
/drivers/staging/comedi/drivers/
Dni_at_a2150.c169 static int a2150_get_timing(struct comedi_device *dev, unsigned int *period,
600 static int a2150_get_timing(struct comedi_device *dev, unsigned int *period, in a2150_get_timing() argument
618 if (*period < glb) in a2150_get_timing()
619 *period = glb; in a2150_get_timing()
620 if (*period > lub) in a2150_get_timing()
621 *period = lub; in a2150_get_timing()
630 if (temp < lub && temp >= *period) { in a2150_get_timing()
635 if (temp > glb && temp <= *period) { in a2150_get_timing()
647 if (lub - *period < *period - glb) in a2150_get_timing()
648 *period = lub; in a2150_get_timing()
[all …]
/drivers/scsi/aic7xxx_old/
Daic7xxx_proc.c191 int period = aic_dev->cur.period; in aic7xxx_show_info() local
195 sync_rate = aic7xxx_find_syncrate(p, &period, 0, &options); in aic7xxx_show_info()
210 aic_dev->cur.period, in aic7xxx_show_info()
215 aic_dev->goal.period, in aic7xxx_show_info()
220 p->user[tindex].period, in aic7xxx_show_info()
/drivers/hwmon/
Dultra45_env.c101 int rpm, period; in show_fan_speed() local
105 period = (int) val << 8; in show_fan_speed()
106 if (FAN_DATA_VALID(period)) in show_fan_speed()
107 rpm = FAN_PERIOD_TO_RPM(period); in show_fan_speed()
120 int period; in set_fan_speed() local
131 period = FAN_RPM_TO_PERIOD(rpm); in set_fan_speed()
132 val = period >> 8; in set_fan_speed()
/drivers/misc/
Dioc4.c149 uint64_t start, end, period; in ioc4_clock_calibrate() local
197 period = (end - start) / in ioc4_clock_calibrate()
201 if (period > IOC4_CALIBRATE_LOW_LIMIT || in ioc4_clock_calibrate()
202 period < IOC4_CALIBRATE_HIGH_LIMIT) { in ioc4_clock_calibrate()
208 period = IOC4_CALIBRATE_DEFAULT; in ioc4_clock_calibrate()
210 u64 ns = period; in ioc4_clock_calibrate()
223 idd->count_period = period; in ioc4_clock_calibrate()
/drivers/oprofile/
Dnmi_timer_int.c128 u64 period; in nmi_timer_setup() local
131 period = (u64)cpu_khz * 1000; in nmi_timer_setup()
132 do_div(period, HZ); in nmi_timer_setup()
133 nmi_timer_attr.sample_period = period; in nmi_timer_setup()
/drivers/rtc/
Dinterface.c374 rtc->aie_timer.period = ktime_set(0, 0); in rtc_set_alarm()
402 rtc->aie_timer.period = ktime_set(0, 0); in rtc_initialize_alarm()
474 rtc->uie_rtctimer.period = ktime_set(1, 0); in rtc_update_irq_enable()
563 ktime_t period; in rtc_pie_update_irq() local
567 period = ktime_set(0, NSEC_PER_SEC/rtc->irq_freq); in rtc_pie_update_irq()
568 count = hrtimer_forward_now(timer, period); in rtc_pie_update_irq()
675 ktime_t period = ktime_set(0, NSEC_PER_SEC / rtc->irq_freq); in rtc_update_hrtimer() local
677 hrtimer_start(&rtc->pie_timer, period, HRTIMER_MODE_REL); in rtc_update_hrtimer()
863 if (ktime_to_ns(timer->period)) { in rtc_timer_do_work()
865 timer->period); in rtc_timer_do_work()
[all …]

1234567