Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 147619
b: refs/heads/master
c: a328810
h: refs/heads/master
i:
  147617: ee4abdc
  147615: dc50df1
v: v3
  • Loading branch information
Yong Wang authored and Ingo Molnar committed Jun 3, 2009
1 parent 36e7f13 commit b24cd35
Show file tree
Hide file tree
Showing 8 changed files with 7 additions and 27 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: addc2785ce92ff05da8edf18317b6b4719e10d9f
refs/heads/master: a32881066e58346f2901afe0ebdfbf0c562877e5
1 change: 0 additions & 1 deletion trunk/arch/x86/include/asm/entry_arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ BUILD_INTERRUPT(error_interrupt,ERROR_APIC_VECTOR)
BUILD_INTERRUPT(spurious_interrupt,SPURIOUS_APIC_VECTOR)

#ifdef CONFIG_PERF_COUNTERS
BUILD_INTERRUPT(perf_counter_interrupt, LOCAL_PERF_VECTOR)
BUILD_INTERRUPT(perf_pending_interrupt, LOCAL_PENDING_VECTOR)
#endif

Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/include/asm/hw_irq.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
extern void apic_timer_interrupt(void);
extern void generic_interrupt(void);
extern void error_interrupt(void);
extern void perf_counter_interrupt(void);
extern void perf_pending_interrupt(void);

extern void spurious_interrupt(void);
Expand Down
5 changes: 0 additions & 5 deletions trunk/arch/x86/include/asm/irq_vectors.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,6 @@
*/
#define LOCAL_TIMER_VECTOR 0xef

/*
* Performance monitoring interrupt vector:
*/
#define LOCAL_PERF_VECTOR 0xee

/*
* Generic system vector for platform specific use
*/
Expand Down
21 changes: 6 additions & 15 deletions trunk/arch/x86/kernel/cpu/perf_counter.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ struct cpu_hw_counters {
struct x86_pmu {
const char *name;
int version;
int (*handle_irq)(struct pt_regs *, int);
int (*handle_irq)(struct pt_regs *);
void (*disable_all)(void);
void (*enable_all)(void);
void (*enable)(struct hw_perf_counter *, int);
Expand Down Expand Up @@ -755,7 +755,7 @@ static void intel_pmu_reset(void)
* This handler is triggered by the local APIC, so the APIC IRQ handling
* rules apply:
*/
static int intel_pmu_handle_irq(struct pt_regs *regs, int nmi)
static int intel_pmu_handle_irq(struct pt_regs *regs)
{
struct cpu_hw_counters *cpuc;
struct cpu_hw_counters;
Expand Down Expand Up @@ -794,7 +794,7 @@ static int intel_pmu_handle_irq(struct pt_regs *regs, int nmi)
if (!intel_pmu_save_and_restart(counter))
continue;

if (perf_counter_overflow(counter, nmi, regs, 0))
if (perf_counter_overflow(counter, 1, regs, 0))
intel_pmu_disable_counter(&counter->hw, bit);
}

Expand All @@ -812,7 +812,7 @@ static int intel_pmu_handle_irq(struct pt_regs *regs, int nmi)
return 1;
}

static int amd_pmu_handle_irq(struct pt_regs *regs, int nmi)
static int amd_pmu_handle_irq(struct pt_regs *regs)
{
int cpu, idx, handled = 0;
struct cpu_hw_counters *cpuc;
Expand Down Expand Up @@ -840,22 +840,13 @@ static int amd_pmu_handle_irq(struct pt_regs *regs, int nmi)
if (!x86_perf_counter_set_period(counter, hwc, idx))
continue;

if (perf_counter_overflow(counter, nmi, regs, 0))
if (perf_counter_overflow(counter, 1, regs, 0))
amd_pmu_disable_counter(hwc, idx);
}

return handled;
}

void smp_perf_counter_interrupt(struct pt_regs *regs)
{
irq_enter();
apic_write(APIC_LVTPC, LOCAL_PERF_VECTOR);
ack_APIC_irq();
x86_pmu.handle_irq(regs, 0);
irq_exit();
}

void smp_perf_pending_interrupt(struct pt_regs *regs)
{
irq_enter();
Expand Down Expand Up @@ -910,7 +901,7 @@ perf_counter_nmi_handler(struct notifier_block *self,
* If the first NMI handles both, the latter will be empty and daze
* the CPU.
*/
x86_pmu.handle_irq(regs, 1);
x86_pmu.handle_irq(regs);

return NOTIFY_STOP;
}
Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/x86/kernel/entry_64.S
Original file line number Diff line number Diff line change
Expand Up @@ -1026,8 +1026,6 @@ apicinterrupt SPURIOUS_APIC_VECTOR \
spurious_interrupt smp_spurious_interrupt

#ifdef CONFIG_PERF_COUNTERS
apicinterrupt LOCAL_PERF_VECTOR \
perf_counter_interrupt smp_perf_counter_interrupt
apicinterrupt LOCAL_PENDING_VECTOR \
perf_pending_interrupt smp_perf_pending_interrupt
#endif
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/kernel/irqinit_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,6 @@ static void __init apic_intr_init(void)
alloc_intr_gate(SPURIOUS_APIC_VECTOR, spurious_interrupt);
alloc_intr_gate(ERROR_APIC_VECTOR, error_interrupt);
# ifdef CONFIG_PERF_COUNTERS
alloc_intr_gate(LOCAL_PERF_VECTOR, perf_counter_interrupt);
alloc_intr_gate(LOCAL_PENDING_VECTOR, perf_pending_interrupt);
# endif

Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/kernel/irqinit_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,6 @@ static void __init apic_intr_init(void)

/* Performance monitoring interrupt: */
#ifdef CONFIG_PERF_COUNTERS
alloc_intr_gate(LOCAL_PERF_VECTOR, perf_counter_interrupt);
alloc_intr_gate(LOCAL_PENDING_VECTOR, perf_pending_interrupt);
#endif
}
Expand Down

0 comments on commit b24cd35

Please sign in to comment.