diff options
-rw-r--r-- | arch/powerpc/oprofile/op_model_fsl_emb.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/powerpc/oprofile/op_model_fsl_emb.c b/arch/powerpc/oprofile/op_model_fsl_emb.c index 62312abffa28..d4e6507277b5 100644 --- a/arch/powerpc/oprofile/op_model_fsl_emb.c +++ b/arch/powerpc/oprofile/op_model_fsl_emb.c | |||
@@ -2,7 +2,7 @@ | |||
2 | * Freescale Embedded oprofile support, based on ppc64 oprofile support | 2 | * Freescale Embedded oprofile support, based on ppc64 oprofile support |
3 | * Copyright (C) 2004 Anton Blanchard <anton@au.ibm.com>, IBM | 3 | * Copyright (C) 2004 Anton Blanchard <anton@au.ibm.com>, IBM |
4 | * | 4 | * |
5 | * Copyright (c) 2004 Freescale Semiconductor, Inc | 5 | * Copyright (c) 2004, 2010 Freescale Semiconductor, Inc |
6 | * | 6 | * |
7 | * Author: Andy Fleming | 7 | * Author: Andy Fleming |
8 | * Maintainer: Kumar Gala <galak@kernel.crashing.org> | 8 | * Maintainer: Kumar Gala <galak@kernel.crashing.org> |
@@ -321,9 +321,6 @@ static void fsl_emb_handle_interrupt(struct pt_regs *regs, | |||
321 | int val; | 321 | int val; |
322 | int i; | 322 | int i; |
323 | 323 | ||
324 | /* set the PMM bit (see comment below) */ | ||
325 | mtmsr(mfmsr() | MSR_PMM); | ||
326 | |||
327 | pc = regs->nip; | 324 | pc = regs->nip; |
328 | is_kernel = is_kernel_addr(pc); | 325 | is_kernel = is_kernel_addr(pc); |
329 | 326 | ||
@@ -340,9 +337,13 @@ static void fsl_emb_handle_interrupt(struct pt_regs *regs, | |||
340 | } | 337 | } |
341 | 338 | ||
342 | /* The freeze bit was set by the interrupt. */ | 339 | /* The freeze bit was set by the interrupt. */ |
343 | /* Clear the freeze bit, and reenable the interrupt. | 340 | /* Clear the freeze bit, and reenable the interrupt. The |
344 | * The counters won't actually start until the rfi clears | 341 | * counters won't actually start until the rfi clears the PMM |
345 | * the PMM bit */ | 342 | * bit. The PMM bit should not be set until after the interrupt |
343 | * is cleared to avoid it getting lost in some hypervisor | ||
344 | * environments. | ||
345 | */ | ||
346 | mtmsr(mfmsr() | MSR_PMM); | ||
346 | pmc_start_ctrs(1); | 347 | pmc_start_ctrs(1); |
347 | } | 348 | } |
348 | 349 | ||