Home
last modified time | relevance | path

Searched refs:mmcr (Results 1 – 17 of 17) sorted by relevance

/Linux-v6.6/arch/powerpc/kvm/
Dbook3s_hv_p9_perf.c94 mtspr(SPRN_MMCR1, vcpu->arch.mmcr[1]); in switch_pmu_to_guest()
95 mtspr(SPRN_MMCR2, vcpu->arch.mmcr[2]); in switch_pmu_to_guest()
101 mtspr(SPRN_MMCR3, vcpu->arch.mmcr[3]); in switch_pmu_to_guest()
108 mtspr(SPRN_MMCR0, vcpu->arch.mmcr[0]); in switch_pmu_to_guest()
137 vcpu->arch.mmcr[0] = mfspr(SPRN_MMCR0); in switch_pmu_to_host()
140 freeze_pmu(vcpu->arch.mmcr[0], vcpu->arch.mmcra); in switch_pmu_to_host()
148 vcpu->arch.mmcr[1] = mfspr(SPRN_MMCR1); in switch_pmu_to_host()
149 vcpu->arch.mmcr[2] = mfspr(SPRN_MMCR2); in switch_pmu_to_host()
155 vcpu->arch.mmcr[3] = mfspr(SPRN_MMCR3); in switch_pmu_to_host()
Dbook3s_hv.c2226 *val = get_reg_val(id, vcpu->arch.mmcr[i]); in kvmppc_get_one_reg_hv()
2229 *val = get_reg_val(id, vcpu->arch.mmcr[2]); in kvmppc_get_one_reg_hv()
2238 *val = get_reg_val(id, vcpu->arch.mmcr[3]); in kvmppc_get_one_reg_hv()
2472 vcpu->arch.mmcr[i] = set_reg_val(id, *val); in kvmppc_set_one_reg_hv()
2475 vcpu->arch.mmcr[2] = set_reg_val(id, *val); in kvmppc_set_one_reg_hv()
2484 *val = get_reg_val(id, vcpu->arch.mmcr[3]); in kvmppc_set_one_reg_hv()
2919 vcpu->arch.mmcr[0] = MMCR0_FC; in kvmppc_core_vcpu_create_hv()
2921 vcpu->arch.mmcr[0] |= MMCR0_PMCCEXT; in kvmppc_core_vcpu_create_hv()
/Linux-v6.6/arch/powerpc/perf/
Dmpc7450-pmu.c260 struct mmcr_regs *mmcr, in mpc7450_compute_mmcr() argument
325 mmcr->mmcr0 = mmcr0; in mpc7450_compute_mmcr()
326 mmcr->mmcr1 = mmcr1; in mpc7450_compute_mmcr()
327 mmcr->mmcr2 = mmcr2; in mpc7450_compute_mmcr()
334 mmcr->mmcra = mmcr2; in mpc7450_compute_mmcr()
342 static void mpc7450_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in mpc7450_disable_pmc() argument
345 mmcr->mmcr0 &= ~(pmcsel_mask[pmc] << pmcsel_shift[pmc]); in mpc7450_disable_pmc()
347 mmcr->mmcr1 &= ~(pmcsel_mask[pmc] << pmcsel_shift[pmc]); in mpc7450_disable_pmc()
Dppc970-pmu.c258 unsigned int hwc[], struct mmcr_regs *mmcr, in p970_compute_mmcr() argument
400 mmcr->mmcr0 = mmcr0; in p970_compute_mmcr()
401 mmcr->mmcr1 = mmcr1; in p970_compute_mmcr()
402 mmcr->mmcra = mmcra; in p970_compute_mmcr()
406 static void p970_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in p970_disable_pmc() argument
415 mmcr->mmcr0 = (mmcr->mmcr0 & ~(0x1fUL << shift)) | (0x08UL << shift); in p970_disable_pmc()
418 mmcr->mmcr1 = (mmcr->mmcr1 & ~(0x1fUL << shift)) | (0x08UL << shift); in p970_disable_pmc()
Dpower7-pmu.c247 unsigned int hwc[], struct mmcr_regs *mmcr, in power7_compute_mmcr() argument
305 mmcr->mmcr0 = 0; in power7_compute_mmcr()
307 mmcr->mmcr0 = MMCR0_PMC1CE; in power7_compute_mmcr()
309 mmcr->mmcr0 |= MMCR0_PMCjCE; in power7_compute_mmcr()
310 mmcr->mmcr1 = mmcr1; in power7_compute_mmcr()
311 mmcr->mmcra = mmcra; in power7_compute_mmcr()
315 static void power7_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in power7_disable_pmc() argument
318 mmcr->mmcr1 &= ~(0xffUL << MMCR1_PMCSEL_SH(pmc)); in power7_disable_pmc()
Dpower6-pmu.c176 unsigned int hwc[], struct mmcr_regs *mmcr, struct perf_event *pevents[], in p6_compute_mmcr() argument
249 mmcr->mmcr0 = 0; in p6_compute_mmcr()
251 mmcr->mmcr0 = MMCR0_PMC1CE; in p6_compute_mmcr()
253 mmcr->mmcr0 |= MMCR0_PMCjCE; in p6_compute_mmcr()
254 mmcr->mmcr1 = mmcr1; in p6_compute_mmcr()
255 mmcr->mmcra = mmcra; in p6_compute_mmcr()
463 static void p6_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in p6_disable_pmc() argument
467 mmcr->mmcr1 &= ~(0xffUL << MMCR1_PMCSEL_SH(pmc)); in p6_disable_pmc()
Dpower5-pmu.c384 unsigned int hwc[], struct mmcr_regs *mmcr, in power5_compute_mmcr() argument
535 mmcr->mmcr0 = 0; in power5_compute_mmcr()
537 mmcr->mmcr0 = MMCR0_PMC1CE; in power5_compute_mmcr()
539 mmcr->mmcr0 |= MMCR0_PMCjCE; in power5_compute_mmcr()
540 mmcr->mmcr1 = mmcr1; in power5_compute_mmcr()
541 mmcr->mmcra = mmcra; in power5_compute_mmcr()
545 static void power5_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in power5_disable_pmc() argument
548 mmcr->mmcr1 &= ~(0x7fUL << MMCR1_PMCSEL_SH(pmc)); in power5_disable_pmc()
Disa207-common.c559 unsigned int hwc[], struct mmcr_regs *mmcr, in isa207_compute_mmcr() argument
704 mmcr->mmcr0 = 0; in isa207_compute_mmcr()
708 mmcr->mmcr0 = MMCR0_PMC1CE; in isa207_compute_mmcr()
711 mmcr->mmcr0 |= MMCR0_PMCjCE; in isa207_compute_mmcr()
715 mmcr->mmcr0 |= MMCR0_FC56; in isa207_compute_mmcr()
723 mmcr->mmcr0 |= MMCR0_PMCCEXT; in isa207_compute_mmcr()
725 mmcr->mmcr1 = mmcr1; in isa207_compute_mmcr()
726 mmcr->mmcra = mmcra; in isa207_compute_mmcr()
727 mmcr->mmcr2 = mmcr2; in isa207_compute_mmcr()
728 mmcr->mmcr3 = mmcr3; in isa207_compute_mmcr()
[all …]
Dpower5+-pmu.c453 unsigned int hwc[], struct mmcr_regs *mmcr, in power5p_compute_mmcr() argument
593 mmcr->mmcr0 = 0; in power5p_compute_mmcr()
595 mmcr->mmcr0 = MMCR0_PMC1CE; in power5p_compute_mmcr()
597 mmcr->mmcr0 |= MMCR0_PMCjCE; in power5p_compute_mmcr()
598 mmcr->mmcr1 = mmcr1; in power5p_compute_mmcr()
599 mmcr->mmcra = mmcra; in power5p_compute_mmcr()
603 static void power5p_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr) in power5p_disable_pmc() argument
606 mmcr->mmcr1 &= ~(0x7fUL << MMCR1_PMCSEL_SH(pmc)); in power5p_disable_pmc()
Dcore-book3s.c42 struct mmcr_regs mmcr; member
130 return cpuhw->mmcr.mmcr0; in ebb_switch_in()
649 unsigned long mmcr0 = cpuhw->mmcr.mmcr0; in ebb_switch_in()
683 mtspr(SPRN_MMCR2, cpuhw->mmcr.mmcr2 | current->thread.mmcr2); in ebb_switch_in()
1369 val = mmcra = cpuhw->mmcr.mmcra; in power_pmu_disable()
1374 if (cpuhw->mmcr.mmcra & MMCRA_SAMPLE_ENABLE) in power_pmu_disable()
1469 mtspr(SPRN_MMCRA, cpuhw->mmcr.mmcra & ~MMCRA_SAMPLE_ENABLE); in power_pmu_enable()
1470 mtspr(SPRN_MMCR1, cpuhw->mmcr.mmcr1); in power_pmu_enable()
1472 mtspr(SPRN_MMCR3, cpuhw->mmcr.mmcr3); in power_pmu_enable()
1479 memset(&cpuhw->mmcr, 0, sizeof(cpuhw->mmcr)); in power_pmu_enable()
[all …]
Dgeneric-compat-pmu.c293 unsigned int hwc[], struct mmcr_regs *mmcr, in generic_compute_mmcr() argument
298 ret = isa207_compute_mmcr(event, n_ev, hwc, mmcr, pevents, flags); in generic_compute_mmcr()
300 mmcr->mmcr0 |= MMCR0_C56RUN; in generic_compute_mmcr()
Disa207-common.h282 unsigned int hwc[], struct mmcr_regs *mmcr,
284 void isa207_disable_pmc(unsigned int pmc, struct mmcr_regs *mmcr);
Dpower10-pmu.c569 unsigned int hwc[], struct mmcr_regs *mmcr, in power10_compute_mmcr() argument
574 ret = isa207_compute_mmcr(event, n_ev, hwc, mmcr, pevents, flags); in power10_compute_mmcr()
576 mmcr->mmcr0 |= MMCR0_C56RUN; in power10_compute_mmcr()
/Linux-v6.6/drivers/mtd/maps/
Dsc520cdp.c172 unsigned long __iomem *mmcr; in sc520cdp_setup_par() local
177 mmcr = ioremap(SC520_MMCR_BASE, SC520_MMCR_EXTENT); in sc520cdp_setup_par()
178 if(!mmcr) { /* ioremap failed: skip the PAR reprogramming */ in sc520cdp_setup_par()
192 mmcr_val = readl(&mmcr[SC520_PAR(j)]); in sc520cdp_setup_par()
196 writel(par_table[i].new_par, &mmcr[SC520_PAR(j)]); in sc520cdp_setup_par()
209 iounmap(mmcr); in sc520cdp_setup_par()
/Linux-v6.6/arch/powerpc/include/asm/
Dperf_event_server.h38 unsigned int hwc[], struct mmcr_regs *mmcr,
51 void (*disable_pmc)(unsigned int pmc, struct mmcr_regs *mmcr);
Dkvm_host.h643 u64 mmcr[4]; /* MMCR0, MMCR1, MMCR2, MMCR3 */ member
/Linux-v6.6/arch/powerpc/kernel/
Dasm-offsets.c456 OFFSET(VCPU_MMCR, kvm_vcpu, arch.mmcr); in main()