[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5c227ef8-72d2-9254-f061-128974a6dc7d@gmail.com>
Date: Thu, 28 Apr 2022 21:40:05 +0800
From: Like Xu <like.xu.linux@...il.com>
To: Sandipan Das <sandipan.das@....com>
Cc: peterz@...radead.org, bp@...en8.de, dave.hansen@...ux.intel.com,
acme@...nel.org, mark.rutland@....com,
alexander.shishkin@...ux.intel.com, namhyung@...nel.org,
jolsa@...nel.org, tglx@...utronix.de, mingo@...hat.com,
pbonzini@...hat.com, jmattson@...gle.com, eranian@...gle.com,
puwen@...on.cn, ananth.narayan@....com, ravi.bangoria@....com,
santosh.shukla@....com,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
linux-perf-users@...r.kernel.org, x86@...nel.org
Subject: Re: [PATCH v4 6/7] perf/x86/amd/core: Add PerfMonV2 overflow handling
On 27/4/2022 7:31 pm, Sandipan Das wrote:
> +static inline void amd_pmu_ack_global_status(u64 status)
> +{
> + /*
> + * PerfCntrGlobalStatus is read-only but an overflow acknowledgment
If wrmsrl PerfCntrGlobalStatus, remain silent or report #GP ?
> + * mechanism exists; writing 1 to a bit in PerfCntrGlobalStatusClr
> + * clears the same bit in PerfCntrGlobalStatus
> + */
> +
> + /* Only allow modifications to PerfCntrGlobalStatus.PerfCntrOvfl */
> + status &= amd_pmu_global_cntr_mask;
> + wrmsrl(MSR_AMD64_PERF_CNTR_GLOBAL_STATUS_CLR, status);
If rdmsrl PerfCntrGlobalStatusClr, does it return 0 or the value of
PerfCntrGlobalStatus ?
> +}
Powered by blists - more mailing lists