Home
last modified time | relevance | path

Searched refs:cntr (Results 1 – 25 of 65) sorted by relevance

123

/openbmc/u-boot/arch/arm/mach-orion5x/
H A Dtimer.c44 #define CTCR_ARM_TIMER_EN_OFFS(cntr) (cntr * 2) argument
45 #define CTCR_ARM_TIMER_EN_MASK(cntr) (1 << CTCR_ARM_TIMER_EN_OFFS) argument
46 #define CTCR_ARM_TIMER_EN(cntr) (1 << CTCR_ARM_TIMER_EN_OFFS(cntr)) argument
47 #define CTCR_ARM_TIMER_DIS(cntr) (0 << CTCR_ARM_TIMER_EN_OFFS(cntr)) argument
49 #define CTCR_ARM_TIMER_AUTO_OFFS(cntr) ((cntr * 2) + 1) argument
50 #define CTCR_ARM_TIMER_AUTO_MASK(cntr) (1 << 1) argument
51 #define CTCR_ARM_TIMER_AUTO_EN(cntr) (1 << CTCR_ARM_TIMER_AUTO_OFFS(cntr)) argument
52 #define CTCR_ARM_TIMER_AUTO_DIS(cntr) (0 << CTCR_ARM_TIMER_AUTO_OFFS(cntr)) argument
/openbmc/linux/drivers/dma/idxd/
H A Dperfmon.h95 #define FLTCFG_REG(idxd, cntr, flt) \ argument
96 (PERFMON_REG_OFFSET(idxd, IDXD_FLTCFG_OFFSET) + ((cntr) * 32) + ((flt) * 4))
98 #define CNTRCFG_REG(idxd, cntr) \ argument
99 (PERFMON_REG_OFFSET(idxd, IDXD_CNTRCFG_OFFSET) + ((cntr) * 8))
100 #define CNTRDATA_REG(idxd, cntr) \ argument
101 (PERFMON_REG_OFFSET(idxd, IDXD_CNTRDATA_OFFSET) + ((cntr) * 8))
102 #define CNTRCAP_REG(idxd, cntr) \ argument
103 (PERFMON_REG_OFFSET(idxd, IDXD_CNTRCAP_OFFSET) + ((cntr) * 8))
H A Dperfmon.c234 int cntr = hwc->idx; in perfmon_pmu_read_counter() local
238 return ioread64(CNTRDATA_REG(idxd, cntr)); in perfmon_pmu_read_counter()
328 int cntr; in perfmon_pmu_event_start() local
333 cntr = hwc->idx; in perfmon_pmu_event_start()
349 iowrite32(flt_wq, FLTCFG_REG(idxd, cntr, FLT_WQ)); in perfmon_pmu_event_start()
360 cntrdata = ioread64(CNTRDATA_REG(idxd, cntr)); in perfmon_pmu_event_start()
369 iowrite64(cntr_cfg, CNTRCFG_REG(idxd, cntr)); in perfmon_pmu_event_start()
376 int i, cntr = hwc->idx; in perfmon_pmu_event_stop() local
392 cntr_cfg = ioread64(CNTRCFG_REG(idxd, cntr)); in perfmon_pmu_event_stop()
394 iowrite64(cntr_cfg, CNTRCFG_REG(idxd, cntr)); in perfmon_pmu_event_stop()
[all …]
/openbmc/qemu/hw/i2c/
H A Dallwinner-i2c.c165 return s->cntr & TWI_CNTR_BUS_EN; in allwinner_i2c_bus_is_enabled()
170 return s->cntr & TWI_CNTR_INT_EN; in allwinner_i2c_interrupt_is_enabled()
184 s->cntr = TWI_CNTR_RESET; in allwinner_i2c_reset_hold()
200 s->cntr |= TWI_CNTR_INT_FLAG; in allwinner_i2c_raise_interrupt()
228 if (s->cntr & TWI_CNTR_A_ACK) { in allwinner_i2c_read()
238 value = s->cntr; in allwinner_i2c_read()
247 if (s->cntr & TWI_CNTR_A_ACK) { in allwinner_i2c_read()
342 if (s->cntr & TWI_CNTR_M_STA) { in allwinner_i2c_write()
352 s->cntr &= ~TWI_CNTR_M_STA; in allwinner_i2c_write()
354 if (s->cntr & TWI_CNTR_M_STP) { in allwinner_i2c_write()
[all …]
/openbmc/linux/arch/x86/events/intel/
H A Dp4.c84 .cntr = { {4, 5, -1}, {6, 7, -1} },
91 .cntr = { {0, -1, -1}, {2, -1, -1} },
100 .cntr = { {0, -1, -1}, {2, -1, -1} },
108 .cntr = { {8, 9, -1}, {10, 11, -1} },
116 .cntr = { {8, 9, -1}, {10, 11, -1} },
123 .cntr = { {8, 9, -1}, {10, 11, -1} },
130 .cntr = { {8, 9, -1}, {10, 11, -1} },
320 .cntr = { {4, 5, -1}, {6, 7, -1} },
334 .cntr = { {4, 5, -1}, {6, 7, -1} },
343 .cntr = { {4, 5, -1}, {6, 7, -1} },
[all …]
/openbmc/linux/arch/mips/sibyte/common/
H A Dbus_watcher.c155 unsigned long cntr; in sibyte_bw_int() local
176 stats->l2_err = cntr = csr_in32(IOADDR(A_BUS_L2_ERRORS)); in sibyte_bw_int()
177 stats->l2_cor_d += G_SCD_L2ECC_CORR_D(cntr); in sibyte_bw_int()
178 stats->l2_bad_d += G_SCD_L2ECC_BAD_D(cntr); in sibyte_bw_int()
179 stats->l2_cor_t += G_SCD_L2ECC_CORR_T(cntr); in sibyte_bw_int()
180 stats->l2_bad_t += G_SCD_L2ECC_BAD_T(cntr); in sibyte_bw_int()
183 stats->memio_err = cntr = csr_in32(IOADDR(A_BUS_MEM_IO_ERRORS)); in sibyte_bw_int()
184 stats->mem_cor_d += G_SCD_MEM_ECC_CORR(cntr); in sibyte_bw_int()
185 stats->mem_bad_d += G_SCD_MEM_ECC_BAD(cntr); in sibyte_bw_int()
186 stats->bus_error += G_SCD_MEM_BUSERR(cntr); in sibyte_bw_int()
/openbmc/linux/arch/x86/events/amd/
H A Diommu.c158 u32 shift, bank, cntr; in get_next_avail_iommu_bnk_cntr() local
165 for (cntr = 0; cntr < max_cntrs; cntr++) { in get_next_avail_iommu_bnk_cntr()
166 shift = bank + (bank*3) + cntr; in get_next_avail_iommu_bnk_cntr()
172 event->hw.iommu_cntr = cntr; in get_next_avail_iommu_bnk_cntr()
185 u8 bank, u8 cntr) in clear_avail_iommu_bnk_cntr() argument
194 if ((bank > max_banks) || (cntr > max_cntrs)) in clear_avail_iommu_bnk_cntr()
197 shift = bank + cntr + (bank*3); in clear_avail_iommu_bnk_cntr()
242 u8 cntr = hwc->iommu_cntr; in perf_iommu_enable_event() local
246 amd_iommu_pc_set_reg(iommu, bank, cntr, IOMMU_PC_COUNTER_SRC_REG, &reg); in perf_iommu_enable_event()
252 amd_iommu_pc_set_reg(iommu, bank, cntr, IOMMU_PC_DEVID_MATCH_REG, &reg); in perf_iommu_enable_event()
[all …]
/openbmc/linux/drivers/net/ethernet/marvell/octeontx2/af/
H A Drvu_npc.c1849 int cntr; in npc_mcam_rsrcs_init() local
1954 for (cntr = 0; cntr < mcam->counters.max; cntr++) in npc_mcam_rsrcs_init()
2202 int cntr; in rvu_npc_get_mcam_counter_alloc_info() local
2207 for (cntr = 0; cntr < mcam->counters.max; cntr++) { in rvu_npc_get_mcam_counter_alloc_info()
2340 u16 cntr; in npc_mcam_free_all_counters() local
2343 for (cntr = 0; cntr < mcam->counters.max; cntr++) { in npc_mcam_free_all_counters()
2734 u16 cntr; in rvu_mbox_handler_npc_mcam_free_entry() local
3013 for (cntr = index; cntr < (index + max_contig); cntr++) { in rvu_mbox_handler_npc_mcam_alloc_counter()
3021 for (cntr = 0; cntr < req->count; cntr++) { in rvu_mbox_handler_npc_mcam_alloc_counter()
3229 cntr = cntr_rsp.cntr; in rvu_mbox_handler_npc_mcam_alloc_and_write_entry()
[all …]
/openbmc/u-boot/drivers/timer/
H A Drockchip_timer.c31 uint64_t cntr; in rockchip_timer_get_curr_value() local
36 cntr = timebase_h << 32 | timebase_l; in rockchip_timer_get_curr_value()
37 return cntr; in rockchip_timer_get_curr_value()
91 uint64_t cntr = rockchip_timer_get_curr_value(priv->timer); in rockchip_timer_get_count() local
94 *count = ~0ull - cntr; in rockchip_timer_get_count()
/openbmc/qemu/hw/net/
H A Dnet_rx_pkt.c476 uint32_t cntr; in net_rx_pkt_validate_l3_csum() local
489 cntr = net_checksum_add_iov(pkt->vec, pkt->vec_len, in net_rx_pkt_validate_l3_csum()
493 csum = net_checksum_finish(cntr); in net_rx_pkt_validate_l3_csum()
498 cntr, csum, *csum_valid); in net_rx_pkt_validate_l3_csum()
506 uint32_t cntr; in _net_rx_pkt_calc_l4_csum() local
523 cntr = eth_calc_ip4_pseudo_hdr_csum(&pkt->ip4hdr_info.ip4_hdr, in _net_rx_pkt_calc_l4_csum()
525 trace_net_rx_pkt_l4_csum_calc_ph_csum(cntr, csl); in _net_rx_pkt_calc_l4_csum()
542 trace_net_rx_pkt_l4_csum_calc_ph_csum(cntr, csl); in _net_rx_pkt_calc_l4_csum()
545 cntr += net_checksum_add_iov(pkt->vec, pkt->vec_len, in _net_rx_pkt_calc_l4_csum()
548 csum = net_checksum_finish_nozero(cntr); in _net_rx_pkt_calc_l4_csum()
[all …]
/openbmc/linux/drivers/scsi/
H A Da2091.c56 unsigned short cntr = CNTR_PDMD | CNTR_INTEN; in dma_setup() local
116 cntr |= CNTR_DDIR; in dma_setup()
121 regs->CNTR = cntr; in dma_setup()
144 unsigned short cntr = CNTR_PDMD; in dma_stop() local
147 cntr |= CNTR_DDIR; in dma_stop()
150 regs->CNTR = cntr; in dma_stop()
H A Da3000.c61 unsigned short cntr = CNTR_PDMD | CNTR_INTEN; in dma_setup() local
118 cntr |= CNTR_DDIR; in dma_setup()
123 regs->CNTR = cntr; in dma_setup()
148 unsigned short cntr = CNTR_PDMD; in dma_stop() local
151 cntr |= CNTR_DDIR; in dma_stop()
153 regs->CNTR = cntr; in dma_stop()
/openbmc/linux/drivers/media/usb/gspca/gl860/
H A Dgl860-ov2640.c343 s32 cntr = sd->vcur.contrast; in ov2640_camera_settings() local
383 if (cntr != sd->vold.contrast) { in ov2640_camera_settings()
384 sd->vold.contrast = cntr; in ov2640_camera_settings()
385 if (cntr < 0 || cntr > sd->vmax.contrast) in ov2640_camera_settings()
386 cntr = 0; in ov2640_camera_settings()
390 ctrl_out(gspca_dev, 0x40, 1, 0x6000 + cntr, 0x007d, 0, NULL); in ov2640_camera_settings()
H A Dgl860-mi1320.c370 s32 cntr = sd->vcur.contrast; in mi1320_camera_settings() local
529 if (cntr != sd->vold.contrast) { in mi1320_camera_settings()
530 sd->vold.contrast = cntr; in mi1320_camera_settings()
531 if (cntr < 0 || cntr > sd->vmax.contrast) in mi1320_camera_settings()
532 cntr = 0; in mi1320_camera_settings()
536 ctrl_out(gspca_dev, 0x40, 1, 0xba00 + tbl_cntr1[cntr], 0x0035, in mi1320_camera_settings()
538 ctrl_out(gspca_dev, 0x40, 1, 0xba00 + tbl_cntr2[cntr], 0x00f1, in mi1320_camera_settings()
H A Dgl860-mi2020.c629 s32 cntr = sd->vcur.contrast; in mi2020_camera_settings() local
734 if (cntr != sd->vold.contrast || gam != sd->vold.gamma) { in mi2020_camera_settings()
735 sd->vold.contrast = cntr; in mi2020_camera_settings()
736 if (cntr < 0 || cntr > sd->vmax.contrast) in mi2020_camera_settings()
737 cntr = 0; in mi2020_camera_settings()
744 if (cntr == 0) in mi2020_camera_settings()
745 cntr = 4; in mi2020_camera_settings()
746 dat_multi4[2] = dat_multi2[2] = cntr * 0x10 + 2 - gam; in mi2020_camera_settings()
/openbmc/linux/drivers/gpu/drm/gma500/
H A Doaktrail_crtc.c271 temp = REG_READ_WITH_AUX(map->cntr, i); in oaktrail_crtc_dpms()
273 REG_WRITE_WITH_AUX(map->cntr, in oaktrail_crtc_dpms()
297 temp = REG_READ_WITH_AUX(map->cntr, i); in oaktrail_crtc_dpms()
299 REG_WRITE_WITH_AUX(map->cntr, in oaktrail_crtc_dpms()
491 dspcntr = REG_READ(map->cntr); in oaktrail_crtc_mode_set()
583 REG_WRITE_WITH_AUX(map->cntr, dspcntr, i); in oaktrail_crtc_mode_set()
620 dspcntr = REG_READ(map->cntr); in oaktrail_pipe_set_base()
642 REG_WRITE(map->cntr, dspcntr); in oaktrail_pipe_set_base()
H A Dgma_display.c93 dspcntr = REG_READ(map->cntr); in gma_pipe_set_base()
115 REG_WRITE(map->cntr, dspcntr); in gma_pipe_set_base()
240 temp = REG_READ(map->cntr); in gma_crtc_dpms()
242 REG_WRITE(map->cntr, in gma_crtc_dpms()
289 temp = REG_READ(map->cntr); in gma_crtc_dpms()
291 REG_WRITE(map->cntr, in gma_crtc_dpms()
590 crtc_state->saveDSPCNTR = REG_READ(map->cntr); in gma_crtc_save()
667 REG_WRITE(map->cntr, crtc_state->saveDSPCNTR); in gma_crtc_restore()
/openbmc/linux/drivers/pwm/
H A Dpwm-rockchip.c43 unsigned long cntr; member
238 .cntr = 0x00,
251 .cntr = 0x00,
265 .cntr = 0x0c,
279 .cntr = 0x00,
/openbmc/linux/include/linux/
H A Damd-iommu.h202 int amd_iommu_pc_set_reg(struct amd_iommu *iommu, u8 bank, u8 cntr, u8 fxn,
204 int amd_iommu_pc_get_reg(struct amd_iommu *iommu, u8 bank, u8 cntr, u8 fxn,
/openbmc/linux/drivers/gpu/drm/i915/gt/
H A Dselftest_rps.c541 dc = READ_ONCE(*cntr); in __measure_frequency()
544 dc = READ_ONCE(*cntr) - dc; in __measure_frequency()
557 x[i] = __measure_frequency(cntr, 2); in measure_frequency_at()
633 u32 *cancel, *cntr; in live_rps_frequency_cs() local
643 &cancel, &cntr); in live_rps_frequency_cs()
772 u32 *cancel, *cntr; in live_rps_frequency_srm() local
782 &cancel, &cntr); in live_rps_frequency_srm()
804 if (wait_for(READ_ONCE(*cntr), 10)) { in live_rps_frequency_srm()
811 min.count = measure_frequency_at(rps, cntr, &min.freq); in live_rps_frequency_srm()
814 max.count = measure_frequency_at(rps, cntr, &max.freq); in live_rps_frequency_srm()
[all …]
/openbmc/linux/drivers/accel/habanalabs/common/
H A Dcommand_submission.c884 struct hl_cs_counters_atomic *cntr; in allocate_cs() local
890 cntr = &hdev->aggregated_cs_counters; in allocate_cs()
898 atomic64_inc(&cntr->out_of_mem_drop_cnt); in allocate_cs()
927 atomic64_inc(&cntr->out_of_mem_drop_cnt); in allocate_cs()
1477 struct hl_cs_counters_atomic *cntr; in cs_ioctl_default() local
1486 cntr = &hdev->aggregated_cs_counters; in cs_ioctl_default()
1606 atomic64_inc(&cntr->parsing_drop_cnt); in cs_ioctl_default()
1927 struct hl_cs_counters_atomic *cntr; in cs_ioctl_signal_wait_create_jobs() local
1932 cntr = &hdev->aggregated_cs_counters; in cs_ioctl_signal_wait_create_jobs()
2198 struct hl_cs_counters_atomic *cntr; in cs_ioctl_signal_wait() local
[all …]
/openbmc/linux/drivers/usb/class/
H A Dcdc-wdm.c522 int rv, cntr; in wdm_read() local
531 cntr = READ_ONCE(desc->length); in wdm_read()
532 if (cntr == 0) { in wdm_read()
597 cntr = desc->length; in wdm_read()
601 if (cntr > count) in wdm_read()
602 cntr = count; in wdm_read()
603 rv = copy_to_user(buffer, desc->ubuf, cntr); in wdm_read()
611 for (i = 0; i < desc->length - cntr; i++) in wdm_read()
612 desc->ubuf[i] = desc->ubuf[i + cntr]; in wdm_read()
614 desc->length -= cntr; in wdm_read()
[all …]
/openbmc/linux/drivers/infiniband/hw/hfi1/
H A Daffinity.c247 u16 cntr; in per_cpu_affinity_get() local
269 cntr = *per_cpu_ptr(comp_vect_affinity, curr_cpu); in per_cpu_affinity_get()
271 if (cntr < prev_cntr) { in per_cpu_affinity_get()
273 prev_cntr = cntr; in per_cpu_affinity_get()
288 u16 cntr; in per_cpu_affinity_put_max() local
303 cntr = *per_cpu_ptr(comp_vect_affinity, curr_cpu); in per_cpu_affinity_put_max()
305 if (cntr > prev_cntr) { in per_cpu_affinity_put_max()
307 prev_cntr = cntr; in per_cpu_affinity_put_max()
/openbmc/linux/drivers/iommu/amd/
H A Damd_iommu.h49 int amd_iommu_pc_get_reg(struct amd_iommu *iommu, u8 bank, u8 cntr,
51 int amd_iommu_pc_set_reg(struct amd_iommu *iommu, u8 bank, u8 cntr,
/openbmc/qemu/include/hw/i2c/
H A Dallwinner-i2c.h51 uint8_t cntr; member

123