Home
last modified time | relevance | path

Searched full:tcnt (Results 1 – 25 of 38) sorted by relevance

12

/openbmc/qemu/hw/timer/
H A Drenesas_tmr.c43 REG8(TCNT, 8)
83 diff[cmia] = concat_reg(tmr->tcora) - concat_reg(tmr->tcnt); in update_events()
84 diff[cmib] = concat_reg(tmr->tcorb) - concat_reg(tmr->tcnt); in update_events()
85 diff[ovi] = 0x10000 - concat_reg(tmr->tcnt); in update_events()
88 diff[cmia] = tmr->tcora[ch] - tmr->tcnt[ch]; in update_events()
89 diff[cmib] = tmr->tcorb[ch] - tmr->tcnt[ch]; in update_events()
90 diff[ovi] = 0x100 - tmr->tcnt[ch]; in update_events()
128 uint16_t tcnt[2]; in read_tcnt() local
142 tcnt[1] = tmr->tcnt[1] + (elapsed & 0xff); in read_tcnt()
147 tcnt[1] = tmr->tcnt[1]; in read_tcnt()
[all …]
H A Dsh_timer.c38 uint32_t tcnt; member
97 s->tcnt = value; in sh_timer_write()
99 ptimer_set_count(s->timer, s->tcnt); in sh_timer_write()
236 s->tcnt = 0xffffffff; in sh_timer_init()
245 sh_timer_write(s, OFFSET_TCNT >> 2, s->tcnt); in sh_timer_init()
H A Dexynos4210_mct.c47 * local timer contains two counters: TCNT and ICNT. TCNT == 0 -> ICNT--.
48 * IRQ is generated when ICNT riches zero. Implementation where TCNT == 0
50 * uint64_t counter equal to TCNT*ICNT and arm ptimer.c for a minimum(TCNT*ICNT,
51 * MCT_GT_COUNTER_STEP); (yes, if target tunes ICNT * TCNT to be too low values,
/openbmc/linux/drivers/media/usb/pvrusb2/
H A Dpvrusb2-eeprom.c41 unsigned pcnt,tcnt; in pvr2_eeprom_fetch() local
77 for (tcnt = 0; tcnt < EEPROM_SIZE; tcnt += pcnt) { in pvr2_eeprom_fetch()
79 if (pcnt + tcnt > EEPROM_SIZE) pcnt = EEPROM_SIZE-tcnt; in pvr2_eeprom_fetch()
80 offs = tcnt + (eepromSize - EEPROM_SIZE); in pvr2_eeprom_fetch()
88 msg[1].buf = eeprom+tcnt; in pvr2_eeprom_fetch()
H A Dpvrusb2-i2c-core.c385 u16 tcnt,bcnt,offs; in pvr2_i2c_xfer() local
398 tcnt = msgs[0].len; in pvr2_i2c_xfer()
400 while (tcnt) { in pvr2_i2c_xfer()
401 bcnt = tcnt; in pvr2_i2c_xfer()
411 tcnt -= bcnt; in pvr2_i2c_xfer()
432 u16 tcnt,bcnt,wcnt,offs; in pvr2_i2c_xfer() local
437 tcnt = msgs[1].len; in pvr2_i2c_xfer()
440 while (tcnt || wcnt) { in pvr2_i2c_xfer()
441 bcnt = tcnt; in pvr2_i2c_xfer()
452 tcnt -= bcnt; in pvr2_i2c_xfer()
H A Dpvrusb2-hdw.c3336 unsigned pcnt,tcnt; in pvr2_full_eeprom_fetch() local
3372 for (tcnt = 0; tcnt < EEPROM_SIZE; tcnt += pcnt) { in pvr2_full_eeprom_fetch()
3374 if (pcnt + tcnt > EEPROM_SIZE) pcnt = EEPROM_SIZE-tcnt; in pvr2_full_eeprom_fetch()
3375 offs = tcnt + (eepromSize - EEPROM_SIZE); in pvr2_full_eeprom_fetch()
3383 msg[1].buf = eeprom+tcnt; in pvr2_full_eeprom_fetch()
4681 unsigned int tcnt = 0; in print_input_mask() local
4684 ccnt = scnprintf(buf+tcnt, in print_input_mask()
4685 acnt-tcnt, in print_input_mask()
4687 (tcnt ? ", " : ""), in print_input_mask()
4689 tcnt += ccnt; in print_input_mask()
[all …]
/openbmc/linux/Documentation/devicetree/bindings/timer/
H A Drenesas,rz-mtu3.yaml25 - Simultaneous writing to multiple timer counters (TCNT)
80 clocks is detected and the corresponding TCNT is incremented or
125 - description: MTU0.TCNT overflow
130 - description: MTU1.TCNT overflow
131 - description: MTU1.TCNT underflow
134 - description: MTU2.TCNT overflow
135 - description: MTU2.TCNT underflow
140 - description: MTU3.TCNT overflow
145 - description: MTU4.TCNT overflow/underflow
153 - description: MTU6.TCNT overflow
[all …]
/openbmc/linux/drivers/phy/microchip/
H A Dsparx5_serdes.h51 int id, int tinst, int tcnt, in sdx5_addr() argument
57 WARN_ON((tinst) >= tcnt); in sdx5_addr()
79 int id, int tinst, int tcnt, in sdx5_rmw() argument
85 sdx5_addr(priv->regs, id, tinst, tcnt, in sdx5_rmw()
94 int id, int tinst, int tcnt, in sdx5_inst_rmw() argument
124 int id, int tinst, int tcnt, in sdx5_inst_addr() argument
/openbmc/linux/drivers/net/ethernet/microchip/sparx5/
H A Dsparx5_main.h571 static inline __pure int spx5_offset(int id, int tinst, int tcnt, in spx5_offset() argument
577 WARN_ON((tinst) >= tcnt); in spx5_offset()
588 int id, int tinst, int tcnt, in spx5_addr() argument
594 WARN_ON((tinst) >= tcnt); in spx5_addr()
615 static inline u32 spx5_rd(struct sparx5 *sparx5, int id, int tinst, int tcnt, in spx5_rd() argument
619 return readl(spx5_addr(sparx5->regs, id, tinst, tcnt, gbase, ginst, in spx5_rd()
623 static inline u32 spx5_inst_rd(void __iomem *iomem, int id, int tinst, int tcnt, in spx5_inst_rd() argument
632 int id, int tinst, int tcnt, in spx5_wr() argument
636 writel(val, spx5_addr(sparx5->regs, id, tinst, tcnt, in spx5_wr()
642 int id, int tinst, int tcnt, in spx5_inst_wr() argument
[all …]
/openbmc/u-boot/drivers/pwm/
H A Dexynos_pwm.c26 u32 tcnt, tcmp, tcon; in exynos_pwm_set_config() local
42 tcnt = period_ns / rate_ns; in exynos_pwm_set_config()
44 debug("%s: tcnt %u, tcmp %u\n", __func__, tcnt, tcmp); in exynos_pwm_set_config()
46 writel(tcnt, &regs->tcntb0 + offset); in exynos_pwm_set_config()
/openbmc/u-boot/arch/arm/cpu/armv7/s5p-common/
H A Dpwm.c67 unsigned long tcnt; in pwm_config() local
87 tcnt = period_ns / tin_ns; in pwm_config()
91 tcmp = tcnt - tcmp; in pwm_config()
96 writel(tcnt, &pwm->tcntb0 + offset); in pwm_config()
/openbmc/u-boot/arch/m68k/cpu/mcf547x_8x/
H A Dslicetimer.c37 out_be32(&timerp->tcnt, usec * freq); in __udelay()
68 out_be32(&timerp->tcnt, 0); in timer_init()
76 out_be32(&timerp->tcnt, 1000 * CONFIG_SYS_TIMER_PRESCALER); in timer_init()
/openbmc/linux/drivers/watchdog/
H A Dmeson_gxbb_wdt.c84 unsigned long tcnt = timeout * 1000; in meson_gxbb_wdt_set_timeout() local
86 if (tcnt > GXBB_WDT_TCNT_SETUP_MASK) in meson_gxbb_wdt_set_timeout()
87 tcnt = GXBB_WDT_TCNT_SETUP_MASK; in meson_gxbb_wdt_set_timeout()
93 writel(tcnt, data->reg_base + GXBB_WDT_TCNT_REG); in meson_gxbb_wdt_set_timeout()
/openbmc/linux/drivers/pwm/
H A Dpwm-berlin.c29 * implemented by internally shifting TCNT left without adding additional
30 * bits. So, the max TCNT that actually works for a modulus of 4 is 0x3fff;
46 u32 tcnt; member
279 channel->tcnt = berlin_pwm_readl(bpc, i, BERLIN_PWM_TCNT); in berlin_pwm_suspend()
306 berlin_pwm_writel(bpc, i, channel->tcnt, BERLIN_PWM_TCNT); in berlin_pwm_resume()
H A Dpwm-samsung.c322 u32 tin_ns = chan->tin_ns, tcnt, tcmp, oldtcmp; in __pwm_samsung_config() local
324 tcnt = readl(our_chip->base + REG_TCNTB(pwm->hwpwm)); in __pwm_samsung_config()
328 ++tcnt; in __pwm_samsung_config()
345 tcnt = period_ns / tin_ns; in __pwm_samsung_config()
349 if (tcnt <= 1) in __pwm_samsung_config()
359 tcmp = tcnt - tcmp; in __pwm_samsung_config()
362 --tcnt; in __pwm_samsung_config()
367 "tin_ns=%u, tcmp=%u/%u\n", tin_ns, tcmp, tcnt); in __pwm_samsung_config()
370 writel(tcnt, our_chip->base + REG_TCNTB(pwm->hwpwm)); in __pwm_samsung_config()
/openbmc/linux/drivers/net/ethernet/microchip/lan966x/
H A Dlan966x_main.h746 int id, int tinst, int tcnt, in lan_addr() argument
752 WARN_ON((tinst) >= tcnt); in lan_addr()
760 static inline u32 lan_rd(struct lan966x *lan966x, int id, int tinst, int tcnt, in lan_rd() argument
764 return readl(lan_addr(lan966x->regs, id, tinst, tcnt, gbase, ginst, in lan_rd()
769 int id, int tinst, int tcnt, in lan_wr() argument
773 writel(val, lan_addr(lan966x->regs, id, tinst, tcnt, in lan_wr()
779 int id, int tinst, int tcnt, in lan_rmw() argument
785 nval = readl(lan_addr(lan966x->regs, id, tinst, tcnt, gbase, ginst, in lan_rmw()
788 writel(nval, lan_addr(lan966x->regs, id, tinst, tcnt, gbase, ginst, in lan_rmw()
/openbmc/linux/drivers/infiniband/hw/hfi1/
H A Diowait.c118 u8 cnt, tcnt; in iowait_priority_update_top() local
122 tcnt = (top->priority << IOWAIT_PRIORITY_STARVE_SHIFT) + in iowait_priority_update_top()
124 if (cnt > tcnt) in iowait_priority_update_top()
/openbmc/qemu/hw/net/
H A Dne2000.c284 if (index + s->tcnt <= NE2000_PMEM_END) { in ne2000_ioport_write()
286 s->tcnt); in ne2000_ioport_write()
322 s->tcnt = (s->tcnt & 0xff00) | val; in ne2000_ioport_write()
325 s->tcnt = (s->tcnt & 0x00ff) | (val << 8); in ne2000_ioport_write()
617 VMSTATE_UINT16(tcnt, NE2000State),
H A Dne2000.h20 uint16_t tcnt; member
/openbmc/linux/drivers/clocksource/
H A Dsh_mtu2.c61 #define TCNT 5 /* channel register */ macro
152 [TCNT] = 6,
165 if ((reg_nr == TCNT) || (reg_nr == TGR)) in sh_mtu2_read()
181 if ((reg_nr == TCNT) || (reg_nr == TGR)) in sh_mtu2_write()
235 sh_mtu2_write(ch, TCNT, 0); in sh_mtu2_enable()
H A Dsh_tmu.c72 #define TCNT 1 /* channel register */ macro
161 sh_tmu_write(ch, TCNT, 0xffffffff); in __sh_tmu_enable()
227 sh_tmu_write(ch, TCNT, delta); in sh_tmu_set_next()
257 return sh_tmu_read(ch, TCNT) ^ 0xffffffff; in sh_tmu_clocksource_read()
H A Dsamsung_pwm_timer.c136 static void samsung_time_setup(unsigned int channel, unsigned long tcnt) in samsung_time_setup() argument
152 writel_relaxed(tcnt, pwm.base + REG_TCNTB(channel)); in samsung_time_setup()
153 writel_relaxed(tcnt, pwm.base + REG_TCMPB(channel)); in samsung_time_setup()
/openbmc/qemu/include/hw/timer/
H A Drenesas_tmr.h43 uint8_t tcnt[TMR_CH]; member
/openbmc/linux/drivers/ntb/test/
H A Dntb_perf.c199 u8 tcnt; member
1051 static int perf_set_tcnt(struct perf_ctx *perf, u8 tcnt) in perf_set_tcnt() argument
1053 if (tcnt == 0 || tcnt > MAX_THREADS_CNT) in perf_set_tcnt()
1059 perf->tcnt = tcnt; in perf_set_tcnt()
1093 atomic_set(&perf->tsync, perf->tcnt); in perf_submit_test()
1101 if (tidx < perf->tcnt) in perf_submit_test()
1157 perf->tcnt = DEF_THREADS_CNT; in perf_init_threads()
1323 pos = scnprintf(buf, sizeof(buf), "%hhu\n", perf->tcnt); in perf_dbgfs_read_tcnt()
/openbmc/linux/tools/perf/tests/shell/lib/
H A Dperf_metric_validation.py149 tcnt = 0
157 tcnt += 1
167 self.failtests['PositiveValueTest']['Total Tests'] = tcnt

12