Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 147193
b: refs/heads/master
c: 16b0679
h: refs/heads/master
i:
  147191: a2f9167
v: v3
  • Loading branch information
Paul Mackerras committed Jan 10, 2009
1 parent a589196 commit b13887a
Show file tree
Hide file tree
Showing 4 changed files with 390 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4574910e5087085a1f330ff8373cee4503f5c77c
refs/heads/master: 16b067993dee3dfde61b20027e0b168dc06201ee
2 changes: 1 addition & 1 deletion trunk/arch/powerpc/kernel/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ obj-$(CONFIG_AUDIT) += audit.o
obj64-$(CONFIG_AUDIT) += compat_audit.o

obj-$(CONFIG_DYNAMIC_FTRACE) += ftrace.o
obj-$(CONFIG_PERF_COUNTERS) += perf_counter.o
obj-$(CONFIG_PERF_COUNTERS) += perf_counter.o ppc970-pmu.o

obj-$(CONFIG_8XX_MINIMAL_FPEMU) += softemu8xx.o

Expand Down
13 changes: 13 additions & 0 deletions trunk/arch/powerpc/kernel/perf_counter.c
Original file line number Diff line number Diff line change
Expand Up @@ -741,13 +741,26 @@ static void perf_counter_interrupt(struct pt_regs *regs)
}
}

extern struct power_pmu ppc970_pmu;

static int init_perf_counters(void)
{
unsigned long pvr;

if (reserve_pmc_hardware(perf_counter_interrupt)) {
printk(KERN_ERR "Couldn't init performance monitor subsystem\n");
return -EBUSY;
}

/* XXX should get this from cputable */
pvr = mfspr(SPRN_PVR);
switch (PVR_VER(pvr)) {
case PV_970:
case PV_970FX:
case PV_970MP:
ppmu = &ppc970_pmu;
break;
}
return 0;
}

Expand Down
Loading

0 comments on commit b13887a

Please sign in to comment.