Linux Perf Users
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Sandipan Das <sandipan.das@amd.com>
Cc: Breno Leitao <leitao@debian.org>,
	mingo@redhat.com, acme@kernel.org, jolsa@kernel.org,
	namhyung@kernel.org, thomas.lendacky@amd.com,
	linux-perf-users@vger.kernel.org, x86@kernel.org, leit@fb.com
Subject: Re: [PATCH] perf/x86/amd/core: always clear status for idx
Date: Tue, 21 Mar 2023 14:43:09 +0100	[thread overview]
Message-ID: <20230321134309.GA2264331@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <ad31a4ea-8e91-dad0-7944-3893189b918b@amd.com>

On Tue, Mar 21, 2023 at 06:26:11PM +0530, Sandipan Das wrote:
> On 3/21/2023 6:12 PM, Peter Zijlstra wrote:
> > On Tue, Mar 21, 2023 at 04:33:38AM -0700, Breno Leitao wrote:
> >> The variable 'status' (which contains the unhandled overflow bits) is
> >> not being properly masked in some cases, displaying the following
> >> warning:
> >>
> >>   WARNING: CPU: 156 PID: 475601 at arch/x86/events/amd/core.c:972 amd_pmu_v2_handle_irq+0x216/0x270
> >>
> >> This seems to be happening because the loop is being continued before
> >> the status bit being unset, in case x86_perf_event_set_period()
> >> returns 0. This is also causing an inconsistency because the "handled"
> >> counter is incremented, but the status bit is not cleaned.
> >>
> >> Move the bit cleaning together above, together when the "handled"
> >> counter is incremented.
> >>
> >> Signed-off-by: Breno Leitao <leitao@debian.org>
> > 
> > Can I get a Fixes: tag so I can consider it for perf/urgent ?
> 
> That would be
> 
> Fixes: 7685665c390d ("perf/x86/amd/core: Add PerfMonV2 overflow handling")
> 

Cheers!

      reply	other threads:[~2023-03-21 13:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-21 11:33 [PATCH] perf/x86/amd/core: always clear status for idx Breno Leitao
2023-03-21 11:56 ` Sandipan Das
2023-03-21 12:42 ` Peter Zijlstra
2023-03-21 12:56   ` Sandipan Das
2023-03-21 13:43     ` Peter Zijlstra [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=20230321134309.GA2264331@hirez.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=acme@kernel.org \
    --cc=jolsa@kernel.org \
    --cc=leit@fb.com \
    --cc=leitao@debian.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=sandipan.das@amd.com \
    --cc=thomas.lendacky@amd.com \
    --cc=x86@kernel.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