From: Ingo Molnar <mingo@elte.hu>
To: Paul Mackerras <paulus@samba.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] perfcounters/powerpc: Make exclude_kernel bit work on Apple G5 processors
Date: Tue, 24 Feb 2009 19:52:00 +0100 [thread overview]
Message-ID: <20090224185200.GA23109@elte.hu> (raw)
In-Reply-To: <18851.20328.847510.730956@cargo.ozlabs.ibm.com>
* Paul Mackerras <paulus@samba.org> wrote:
> Currently, setting hw_event.exclude_kernel does nothing on the PPC970
> variants used in Apple G5 machines, because they have the HV (hypervisor)
> bit in the MSR forced to 1, so as far as the PMU is concerned, the
> kernel runs in hypervisor mode. Thus we have to use the MMCR0_FCHV
> (freeze counters in hypervisor mode) bit rather than the MMCR0_FCS
> (freeze counters in supervisor mode) bit.
>
> This checks the MSR.HV bit at startup, and if it is set, we set the
> freeze_counters_kernel variable to MMCR0_FCHV (it was initialized to
> MMCR0_FCS). We then use that whenever we need to exclude kernel events.
>
> Signed-off-by: Paul Mackerras <paulus@samba.org>
> ---
> Ingo, please pull this from my perfcounters.git tree master branch at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/paulus/perfcounters.git master
>
> arch/powerpc/kernel/perf_counter.c | 23 ++++++++++++++++++-----
> 1 files changed, 18 insertions(+), 5 deletions(-)
pulled, thanks Paul!
Ingo
prev parent reply other threads:[~2009-02-24 18:52 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-24 1:37 Paul Mackerras
2009-02-24 18:52 ` Ingo Molnar [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090224185200.GA23109@elte.hu \
--to=mingo@elte.hu \
--cc=linux-kernel@vger.kernel.org \
--cc=paulus@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®