[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <bdeda732-7b5e-1a99-29e4-e68d165822d1@linux.intel.com>
Date: Tue, 16 Mar 2021 10:53:51 -0400
From: "Liang, Kan" <kan.liang@...ux.intel.com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: mingo@...nel.org, acme@...hat.com, linux-kernel@...r.kernel.org,
alexander.shishkin@...ux.intel.com, jolsa@...hat.com,
eranian@...gle.com, namhyung@...nel.org, ak@...ux.intel.com
Subject: Re: [PATCH 1/5] perf/x86/intel/uncore: Parse uncore discovery tables
On 3/16/2021 10:05 AM, Peter Zijlstra wrote:
> On Tue, Mar 16, 2021 at 08:42:25AM -0400, Liang, Kan wrote:
>>
>>
>> On 3/16/2021 7:43 AM, Peter Zijlstra wrote:
>>> On Fri, Mar 12, 2021 at 08:34:34AM -0800, kan.liang@...ux.intel.com wrote:
>>>> From: Kan Liang <kan.liang@...ux.intel.com>
>>>>
>>>> A self-describing mechanism for the uncore PerfMon hardware has been
>>>> introduced with the latest Intel platforms. By reading through an MMIO
>>>> page worth of information, perf can 'discover' all the standard uncore
>>>> PerfMon registers in a machine.
>>>>
>>>> The discovery mechanism relies on BIOS's support. With a proper BIOS,
>>>> a PCI device with the unique capability ID 0x23 can be found on each
>>>> die. Perf can retrieve the information of all available uncore PerfMons
>>>> from the device via MMIO. The information is composed of one global
>>>> discovery table and several unit discovery tables.
>>>
>>>> If a BIOS doesn't support the 'discovery' mechanism, there is nothing
>>>> changed.
>>>
>>> What if the BIOS got it wrong? Will the driver still get it correct if
>>> it is a known platform?
>>
>> Yes, I will submit a platform specific patch to fix this case.
>>
>>>
>>> Do we need a chicken flag to kill the discovery? uncore_no_discover?
>>>
>>
>> Yes, I plan to introduce a .use_discovery_tables flag to indicate whether to
>> use the discovery tables for the known platform.
>>
>> The below codes is part of the upcoming SPR uncore patches.
>> The first SPR uncore patch will still rely on the BIOS discovery tables,
>> because some uncore block information hasn't been published yet. We have to
>> retrieve the information fro the tables. Once all the information is
>> published, we can kill the discovery by removing the ".use_discovery_tables
>> = true".
>
> I was thinking of a module parameter, such that we can tell it to skip
> discovery on module load time etc.
>
Sure, I will add a module parameter, uncore_no_discover.
If users don't want the discovery feature, they can set
uncore_no_discover=true.
Thanks,
Kan
Powered by blists - more mailing lists