| /linux/drivers/perf/ |
| H A D | starfive_starlink_pmu.c | 70 struct starlink_hw_events __percpu *hw_events; member 292 struct starlink_hw_events *hw_events = in starlink_pmu_add() local 293 this_cpu_ptr(starlink_pmu->hw_events); in starlink_pmu_add() 295 unsigned long *used_mask = hw_events->used_mask; in starlink_pmu_add() 318 hw_events->events[idx] = event; in starlink_pmu_add() 332 struct starlink_hw_events *hw_events = in starlink_pmu_del() local 333 this_cpu_ptr(starlink_pmu->hw_events); in starlink_pmu_del() 337 hw_events->events[hwc->idx] = NULL; in starlink_pmu_del() 338 clear_bit(hwc->idx, hw_events->used_mask); in starlink_pmu_del() 399 struct starlink_hw_events *hw_events = in starlink_pmu_handle_irq() local [all …]
|
| H A D | arm_pmu.c | 320 struct pmu_hw_events *hw_events = this_cpu_ptr(armpmu->hw_events); in armpmu_del() local 327 hw_events->branch_users--; in armpmu_del() 331 hw_events->events[idx] = NULL; in armpmu_del() 332 armpmu->clear_event_idx(hw_events, event); in armpmu_del() 342 struct pmu_hw_events *hw_events = this_cpu_ptr(armpmu->hw_events); in armpmu_add() local 351 idx = armpmu->get_event_idx(hw_events, event); in armpmu_add() 356 WARN_ON_ONCE(hw_events->events[idx]); in armpmu_add() 359 hw_events->branch_users++; in armpmu_add() 364 hw_events->events[idx] = event; in armpmu_add() 377 validate_event(struct pmu *pmu, struct pmu_hw_events *hw_events, in validate_event() argument [all …]
|
| H A D | arm-cci.c | 105 struct cci_pmu_hw_events hw_events; member 640 struct cci_pmu_hw_events *cci_hw = &cci_pmu->hw_events; in cci_pmu_sync_counters() 644 for_each_set_bit(i, cci_pmu->hw_events.used_mask, cci_pmu->num_cntrs) { in cci_pmu_sync_counters() 886 struct cci_pmu_hw_events *cci_hw = &cci_pmu->hw_events; in __pmu_write_counters() 951 struct perf_event *event = cci_pmu->hw_events.events[i]; in cci5xx_pmu_write_counters() 1017 struct cci_pmu_hw_events *events = &cci_pmu->hw_events; in pmu_handle_irq() 1085 struct cci_pmu_hw_events *hw_events = &cci_pmu->hw_events; in cci_pmu_enable() local 1086 bool enabled = !bitmap_empty(hw_events->used_mask, cci_pmu->num_cntrs); in cci_pmu_enable() 1092 raw_spin_lock_irqsave(&hw_events->pmu_lock, flags); in cci_pmu_enable() 1094 raw_spin_unlock_irqrestore(&hw_events->pmu_lock, flags); in cci_pmu_enable() [all …]
|
| H A D | nvidia_t410_cmem_latency_pmu.c | 79 struct cmem_lat_pmu_hw_events hw_events; member 93 static int cmem_lat_pmu_get_event_idx(struct cmem_lat_pmu_hw_events *hw_events, in cmem_lat_pmu_get_event_idx() argument 98 idx = find_first_zero_bit(hw_events->used_ctrs, CMEM_LAT_MAX_ACTIVE_EVENTS); in cmem_lat_pmu_get_event_idx() 102 set_bit(idx, hw_events->used_ctrs); in cmem_lat_pmu_get_event_idx() 108 struct cmem_lat_pmu_hw_events *hw_events, in cmem_lat_pmu_validate_event() argument 120 ret = cmem_lat_pmu_get_event_idx(hw_events, event); in cmem_lat_pmu_validate_event() 312 struct cmem_lat_pmu_hw_events *hw_events = &cmem_lat_pmu->hw_events; in cmem_lat_pmu_add() local 320 idx = cmem_lat_pmu_get_event_idx(hw_events, event); in cmem_lat_pmu_add() 324 hw_events->events[idx] = event; in cmem_lat_pmu_add() 340 struct cmem_lat_pmu_hw_events *hw_events = &cmem_lat_pmu->hw_events; in cmem_lat_pmu_del() local [all …]
|
| H A D | arm_dsu_pmu.c | 112 struct dsu_hw_events hw_events; member 278 static int dsu_pmu_get_event_idx(struct dsu_hw_events *hw_events, in dsu_pmu_get_event_idx() argument 284 unsigned long *used_mask = hw_events->used_mask; in dsu_pmu_get_event_idx() 294 set_bit(idx, hw_events->used_mask); in dsu_pmu_get_event_idx() 377 struct dsu_hw_events *hw_events = &dsu_pmu->hw_events; in dsu_pmu_handle_irq() local 385 struct perf_event *event = hw_events->events[i]; in dsu_pmu_handle_irq() 425 struct dsu_hw_events *hw_events = &dsu_pmu->hw_events; in dsu_pmu_add() local 433 idx = dsu_pmu_get_event_idx(hw_events, event); in dsu_pmu_add() 438 hw_events->events[idx] = event; in dsu_pmu_add() 451 struct dsu_hw_events *hw_events = &dsu_pmu->hw_events; in dsu_pmu_del() local [all …]
|
| H A D | nvidia_t410_c2c_pmu.c | 149 struct nv_c2c_pmu_hw_events hw_events; member 184 static int nv_c2c_pmu_get_event_idx(struct nv_c2c_pmu_hw_events *hw_events, in nv_c2c_pmu_get_event_idx() argument 189 idx = find_first_zero_bit(hw_events->used_ctrs, C2C_MAX_ACTIVE_EVENTS); in nv_c2c_pmu_get_event_idx() 193 set_bit(idx, hw_events->used_ctrs); in nv_c2c_pmu_get_event_idx() 200 struct nv_c2c_pmu_hw_events *hw_events, in nv_c2c_pmu_validate_event() argument 210 return nv_c2c_pmu_get_event_idx(hw_events, event) >= 0; in nv_c2c_pmu_validate_event() 403 struct nv_c2c_pmu_hw_events *hw_events = &c2c_pmu->hw_events; in nv_c2c_pmu_add() local 411 idx = nv_c2c_pmu_get_event_idx(hw_events, event); in nv_c2c_pmu_add() 415 hw_events->events[idx] = event; in nv_c2c_pmu_add() 431 struct nv_c2c_pmu_hw_events *hw_events = &c2c_pmu->hw_events; in nv_c2c_pmu_del() local [all …]
|
| H A D | riscv_pmu_sbi.c | 541 struct cpu_hw_events *cpuc = this_cpu_ptr(rvpmu->hw_events); in pmu_sbi_ctr_get_idx() 600 struct cpu_hw_events *cpuc = this_cpu_ptr(rvpmu->hw_events); in pmu_sbi_ctr_clear_idx() 660 struct cpu_hw_events *cpu_hw_evt = per_cpu_ptr(pmu->hw_events, cpu); in pmu_sbi_snapshot_free() 677 struct cpu_hw_events *cpu_hw_evt = per_cpu_ptr(pmu->hw_events, cpu); in pmu_sbi_snapshot_alloc() 710 cpu_hw_evt = per_cpu_ptr(pmu->hw_events, cpu); in pmu_sbi_snapshot_setup() 745 struct cpu_hw_events *cpu_hw_evt = this_cpu_ptr(pmu->hw_events); in pmu_sbi_ctr_read() 826 struct cpu_hw_events *cpu_hw_evt = this_cpu_ptr(pmu->hw_events); in pmu_sbi_ctr_stop() 911 struct cpu_hw_events *cpu_hw_evt = this_cpu_ptr(pmu->hw_events); in pmu_sbi_stop_hw_ctrs() 1032 struct cpu_hw_events *cpu_hw_evt = this_cpu_ptr(pmu->hw_events); in pmu_sbi_start_overflow_mask() 1150 struct cpu_hw_events *cpu_hw_evt = this_cpu_ptr(pmu->hw_events); in pmu_sbi_starting_cpu() [all …]
|
| H A D | riscv_pmu.c | 260 struct cpu_hw_events *cpuc = this_cpu_ptr(rvpmu->hw_events); in riscv_pmu_add() 284 struct cpu_hw_events *cpuc = this_cpu_ptr(rvpmu->hw_events); in riscv_pmu_del() 396 pmu->hw_events = alloc_percpu_gfp(struct cpu_hw_events, GFP_KERNEL); in riscv_pmu_alloc() 397 if (!pmu->hw_events) { in riscv_pmu_alloc() 403 cpuc = per_cpu_ptr(pmu->hw_events, cpuid); in riscv_pmu_alloc()
|
| H A D | cxl_pmu.c | 102 struct perf_event **hw_events; member 860 info->hw_events[idx] = event; in cxl_pmu_event_add() 876 info->hw_events[hwc->idx] = NULL; in cxl_pmu_event_del() 896 struct perf_event *event = info->hw_events[i]; in cxl_pmu_irq() 950 info->hw_events = devm_kcalloc(dev, info->num_counters, in cxl_pmu_probe() 951 sizeof(*info->hw_events), GFP_KERNEL); in cxl_pmu_probe() 952 if (!info->hw_events) in cxl_pmu_probe()
|
| H A D | arm_brbe.c | 496 struct pmu_hw_events *cpuc = this_cpu_ptr(arm_pmu->hw_events); in brbe_enable()
|
| /linux/drivers/perf/arm_cspmu/ |
| H A D | arm_cspmu.c | 584 disabled = bitmap_empty(cspmu->hw_events.used_ctrs, in arm_cspmu_enable() 600 static int arm_cspmu_get_event_idx(struct arm_cspmu_hw_events *hw_events, in arm_cspmu_get_event_idx() argument 611 hw_events->used_ctrs)) in arm_cspmu_get_event_idx() 622 idx = find_first_zero_bit(hw_events->used_ctrs, in arm_cspmu_get_event_idx() 626 hw_events->used_ctrs, in arm_cspmu_get_event_idx() 631 idx = find_first_zero_bit(hw_events->used_ctrs, in arm_cspmu_get_event_idx() 644 set_bit(idx, hw_events->used_ctrs); in arm_cspmu_get_event_idx() 650 struct arm_cspmu_hw_events *hw_events, in arm_cspmu_validate_event() argument 660 return (arm_cspmu_get_event_idx(hw_events, event) >= 0); in arm_cspmu_validate_event() 932 struct arm_cspmu_hw_events *hw_events = &cspmu->hw_events; in arm_cspmu_add() local [all …]
|
| /linux/drivers/perf/hisilicon/ |
| H A D | hisi_pcie_pmu.c | 66 struct perf_event *hw_events[HISI_PCIE_MAX_COUNTERS]; member 430 sibling = pcie_pmu->hw_events[idx]; in hisi_pcie_pmu_get_event_idx() 590 if (!pcie_pmu->hw_events[idx]) { in hisi_pcie_pmu_add() 592 pcie_pmu->hw_events[idx] = event; in hisi_pcie_pmu_add() 607 pcie_pmu->hw_events[hwc->idx] = NULL; in hisi_pcie_pmu_del() 617 if (pcie_pmu->hw_events[num]) in hisi_pcie_pmu_enable() 649 event = pcie_pmu->hw_events[idx]; in hisi_pcie_pmu_irq()
|
| H A D | hisi_uncore_pmu.c | 171 event = hisi_pmu->pmu_events.hw_events[idx]; in hisi_uncore_pmu_isr() 387 hisi_pmu->pmu_events.hw_events[idx] = event; in hisi_uncore_pmu_add() 404 hisi_pmu->pmu_events.hw_events[hwc->idx] = NULL; in hisi_uncore_pmu_del()
|
| H A D | hisi_uncore_pmu.h | 82 struct perf_event *hw_events[HISI_MAX_COUNTERS]; member
|
| H A D | hisi_uncore_noc_pmu.c | 85 !hisi_noc_pmu_check_global_filter(pmu_events->hw_events[cur_idx], event)) in hisi_noc_pmu_get_event_idx()
|
| /linux/drivers/accel/habanalabs/gaudi2/ |
| H A D | gaudi2.c | 4072 gaudi2->hw_events[gaudi2->num_of_valid_hw_events++] = gaudi2_irq_map_table[i].fc_id; in gaudi2_sw_init() 7499 irq_arr_size = gaudi2->num_of_valid_hw_events * sizeof(gaudi2->hw_events[0]); in gaudi2_compute_reset_late_init() 7500 return hl_fw_unmask_irq_arr(hdev, gaudi2->hw_events, irq_arr_size); in gaudi2_compute_reset_late_init()
|