[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7d97606b-67b6-4eb7-48ca-99250edc3fba@linux.intel.com>
Date: Mon, 16 Jul 2018 10:29:49 -0400
From: "Liang, Kan" <kan.liang@...ux.intel.com>
To: Ingo Molnar <mingo@...nel.org>,
Masayoshi Mizuma <msys.mizuma@...il.com>,
Kan Liang <kan.liang@...el.com>
Cc: Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>, x86@...nel.org,
linux-kernel@...r.kernel.org,
Masayoshi Mizuma <m.mizuma@...fujitsu.com>
Subject: Re: [PATCH] [RESEND] perf/x86/intel/uncore: Fix the index of PCU.3
Broadwell CPUs
On 7/15/2018 6:34 PM, Ingo Molnar wrote:
>
> * Masayoshi Mizuma <msys.mizuma@...il.com> wrote:
>
>> From: Masayoshi Mizuma <m.mizuma@...fujitsu.com>
>>
>> commit 15a3e845b01c ("perf/x86/intel/uncore: Fix SBOX support for
>> Broadwell CPUs") introduced PCU.3 for Broadwell CPU. Unfortunately,
>> the driver_data of PCU.3 conflicts to QPI Port 2 filter.
>>
>> { /* QPI Port 2 filter */
>> PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x6f46),
>> .driver_data = UNCORE_PCI_DEV_DATA(UNCORE_EXTRA_PCI_DEV, 2),
>>
>> { /* PCU.3 (for Capability registers) */
>> PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x6fc0),
>> .driver_data = UNCORE_PCI_DEV_DATA(UNCORE_EXTRA_PCI_DEV,
>> HSWEP_PCI_PCU_3),
>> // HSWEP_PCI_PCU_3 == 2
>
>> --- a/arch/x86/events/intel/uncore_snbep.c
>> +++ b/arch/x86/events/intel/uncore_snbep.c
>> @@ -1030,6 +1030,7 @@ enum {
>> SNBEP_PCI_QPI_PORT0_FILTER,
>> SNBEP_PCI_QPI_PORT1_FILTER,
>> HSWEP_PCI_PCU_3,
>> + BDX_PCI_PCU_3,
>> };
>
> So we use a magic '2' enumerator in the 'QPI Port 2 filter', and that overlaps
> with HSWEP_PCI_PCU_3, right?
>
> Shouldn't we clean up all the enumerators and not use magic numbers, and this fix
> the conflict?
>
Yes, it should fix the conflict. I will clean up the code.
Thanks,
Kan
> Thanks,
>
> Ingo
>
Powered by blists - more mailing lists