Lines Matching refs:cpuc
308 static int mipsxx_pmu_alloc_counter(struct cpu_hw_events *cpuc, in mipsxx_pmu_alloc_counter() argument
331 !test_and_set_bit(i, cpuc->used_mask)) in mipsxx_pmu_alloc_counter()
340 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in mipsxx_pmu_enable_event() local
344 cpuc->saved_ctrl[idx] = M_PERFCTL_EVENT(evt->event_base & 0xff) | in mipsxx_pmu_enable_event()
355 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in mipsxx_pmu_disable_event() local
361 cpuc->saved_ctrl[idx] = mipsxx_pmu_read_control(idx) & in mipsxx_pmu_disable_event()
363 mipsxx_pmu_write_control(idx, cpuc->saved_ctrl[idx]); in mipsxx_pmu_disable_event()
455 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in mipspmu_add() local
463 idx = mipsxx_pmu_alloc_counter(cpuc, hwc); in mipspmu_add()
475 cpuc->events[idx] = event; in mipspmu_add()
491 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in mipspmu_del() local
498 cpuc->events[idx] = NULL; in mipspmu_del()
499 clear_bit(idx, cpuc->used_mask); in mipspmu_del()
732 static void handle_associated_event(struct cpu_hw_events *cpuc, in handle_associated_event() argument
736 struct perf_event *event = cpuc->events[idx]; in handle_associated_event()
1278 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in pause_local_counters() local
1285 cpuc->saved_ctrl[ctr] = mipsxx_pmu_read_control(ctr); in pause_local_counters()
1286 mipsxx_pmu_write_control(ctr, cpuc->saved_ctrl[ctr] & in pause_local_counters()
1294 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in resume_local_counters() local
1299 mipsxx_pmu_write_control(ctr, cpuc->saved_ctrl[ctr]); in resume_local_counters()
1305 struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events); in mipsxx_pmu_handle_shared_irq() local
1333 if (test_bit(n, cpuc->used_mask)) { \ in mipsxx_pmu_handle_shared_irq()
1336 handle_associated_event(cpuc, n, &data, regs); \ in mipsxx_pmu_handle_shared_irq()