Lines Matching refs:idx
56 static unsigned long read_pmc(int idx) in read_pmc() argument
60 switch (idx) { in read_pmc()
80 printk(KERN_ERR "oops trying to read PMC%d\n", idx); in read_pmc()
89 static void write_pmc(int idx, unsigned long val) in write_pmc() argument
91 switch (idx) { in write_pmc()
111 printk(KERN_ERR "oops trying to write PMC%d\n", idx); in write_pmc()
120 static void write_pmlca(int idx, unsigned long val) in write_pmlca() argument
122 switch (idx) { in write_pmlca()
142 printk(KERN_ERR "oops trying to write PMLCA%d\n", idx); in write_pmlca()
151 static void write_pmlcb(int idx, unsigned long val) in write_pmlcb() argument
153 switch (idx) { in write_pmlcb()
173 printk(KERN_ERR "oops trying to write PMLCB%d\n", idx); in write_pmlcb()
194 val = read_pmc(event->hw.idx); in fsl_emb_pmu_read()
321 event->hw.idx = i; in fsl_emb_pmu_add()
357 int i = event->hw.idx; in fsl_emb_pmu_del()
367 WARN_ON(event != cpuhw->event[event->hw.idx]); in fsl_emb_pmu_del()
374 event->hw.idx = -1; in fsl_emb_pmu_del()
397 if (event->hw.idx < 0 || !event->hw.sample_period) in fsl_emb_pmu_start()
414 write_pmc(event->hw.idx, val); in fsl_emb_pmu_start()
425 if (event->hw.idx < 0 || !event->hw.sample_period) in fsl_emb_pmu_stop()
436 write_pmc(event->hw.idx, 0); in fsl_emb_pmu_stop()
551 event->hw.idx = -1; in fsl_emb_pmu_event_init()
614 write_pmc(event->hw.idx, 0); in record_and_restart()
641 write_pmc(event->hw.idx, val); in record_and_restart()