[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <DM5PR12MB2471EA1640938E33767886E395D90@DM5PR12MB2471.namprd12.prod.outlook.com>
Date: Tue, 20 Nov 2018 16:32:49 +0000
From: "Moger, Babu" <Babu.Moger@....com>
To: Borislav Petkov <bp@...en8.de>
CC: "tglx@...utronix.de" <tglx@...utronix.de>,
"mingo@...hat.com" <mingo@...hat.com>,
"corbet@....net" <corbet@....net>,
"fenghua.yu@...el.com" <fenghua.yu@...el.com>,
"reinette.chatre@...el.com" <reinette.chatre@...el.com>,
"peterz@...radead.org" <peterz@...radead.org>,
"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
"davem@...emloft.net" <davem@...emloft.net>,
"akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
"hpa@...or.com" <hpa@...or.com>, "x86@...nel.org" <x86@...nel.org>,
"mchehab+samsung@...nel.org" <mchehab+samsung@...nel.org>,
"arnd@...db.de" <arnd@...db.de>,
"kstewart@...uxfoundation.org" <kstewart@...uxfoundation.org>,
"pombredanne@...b.com" <pombredanne@...b.com>,
"rafael@...nel.org" <rafael@...nel.org>,
"kirill.shutemov@...ux.intel.com" <kirill.shutemov@...ux.intel.com>,
"tony.luck@...el.com" <tony.luck@...el.com>,
"qianyue.zj@...baba-inc.com" <qianyue.zj@...baba-inc.com>,
"xiaochen.shen@...el.com" <xiaochen.shen@...el.com>,
"pbonzini@...hat.com" <pbonzini@...hat.com>,
"Singh, Brijesh" <brijesh.singh@....com>,
"Hurwitz, Sherry" <sherry.hurwitz@....com>,
"dwmw2@...radead.org" <dwmw2@...radead.org>,
"Lendacky, Thomas" <Thomas.Lendacky@....com>,
"luto@...nel.org" <luto@...nel.org>,
"joro@...tes.org" <joro@...tes.org>,
"jannh@...gle.com" <jannh@...gle.com>,
"vkuznets@...hat.com" <vkuznets@...hat.com>,
"rian@...m.mit.edu" <rian@...m.mit.edu>,
"jpoimboe@...hat.com" <jpoimboe@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-doc@...r.kernel.org" <linux-doc@...r.kernel.org>
Subject: RE: [PATCH v8 04/13] arch/resctrl: Bring all the macros to resctrl.h
Boris,
> -----Original Message-----
> From: Borislav Petkov <bp@...en8.de>
> Sent: Tuesday, November 20, 2018 3:36 AM
> To: Moger, Babu <Babu.Moger@....com>
> Cc: tglx@...utronix.de; mingo@...hat.com; corbet@....net;
> fenghua.yu@...el.com; reinette.chatre@...el.com; peterz@...radead.org;
> gregkh@...uxfoundation.org; davem@...emloft.net; akpm@...ux-
> foundation.org; hpa@...or.com; x86@...nel.org;
> mchehab+samsung@...nel.org; arnd@...db.de;
> kstewart@...uxfoundation.org; pombredanne@...b.com;
> rafael@...nel.org; kirill.shutemov@...ux.intel.com; tony.luck@...el.com;
> qianyue.zj@...baba-inc.com; xiaochen.shen@...el.com;
> pbonzini@...hat.com; Singh, Brijesh <brijesh.singh@....com>; Hurwitz,
> Sherry <sherry.hurwitz@....com>; dwmw2@...radead.org; Lendacky,
> Thomas <Thomas.Lendacky@....com>; luto@...nel.org; joro@...tes.org;
> jannh@...gle.com; vkuznets@...hat.com; rian@...m.mit.edu;
> jpoimboe@...hat.com; linux-kernel@...r.kernel.org; linux-
> doc@...r.kernel.org
> Subject: Re: [PATCH v8 04/13] arch/resctrl: Bring all the macros to resctrl.h
>
> On Fri, Nov 16, 2018 at 08:54:28PM +0000, Moger, Babu wrote:
> > diff --git a/arch/x86/kernel/cpu/resctrl_monitor.c
> b/arch/x86/kernel/cpu/resctrl_monitor.c
> > index 6d654f7b0eba..9fd62263dabd 100644
> > --- a/arch/x86/kernel/cpu/resctrl_monitor.c
> > +++ b/arch/x86/kernel/cpu/resctrl_monitor.c
> > @@ -28,9 +28,6 @@
> > #include <asm/cpu_device_id.h>
> > #include "resctrl.h"
> >
> > -#define MSR_IA32_QM_CTR 0x0c8e
> > -#define MSR_IA32_QM_EVTSEL 0x0c8d
> > -
> > struct rmid_entry {
> > u32 rmid;
> > int busy;
> > @@ -97,8 +94,8 @@ static u64 __rmid_read(u32 rmid, u32 eventid)
> > * IA32_QM_CTR.Error (bit 63) and IA32_QM_CTR.Unavailable (bit 62)
> > * are error bits.
> > */
> > - wrmsr(MSR_IA32_QM_EVTSEL, eventid, rmid);
> > - rdmsrl(MSR_IA32_QM_CTR, val);
> > + wrmsr(IA32_QM_EVTSEL, eventid, rmid);
> > + rdmsrl(IA32_QM_CTR, val);
>
> Well, if you have a look at arch/x86/include/asm/msr-index.h, you'll see
> that all MSR defines are prefixed with "MSR_" so dropping that prefix
> here loses information and staring at the define doesn't tell me what it
> is.
Ok. Sure. Will retain MSR_.
>
> --
> Regards/Gruss,
> Boris.
>
> Good mailing practices for 400: avoid top-posting and trim the reply.
Powered by blists - more mailing lists