lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <90282397-fb9c-427b-80e7-5bbc325527de@intel.com>
Date: Thu, 1 Aug 2024 11:56:26 -0700
From: Reinette Chatre <reinette.chatre@...el.com>
To: <babu.moger@....com>, Peter Newman <peternewman@...gle.com>
CC: <corbet@....net>, <fenghua.yu@...el.com>, <tglx@...utronix.de>,
	<mingo@...hat.com>, <bp@...en8.de>, <dave.hansen@...ux.intel.com>,
	<x86@...nel.org>, <hpa@...or.com>, <paulmck@...nel.org>,
	<rdunlap@...radead.org>, <tj@...nel.org>, <peterz@...radead.org>,
	<yanjiewtw@...il.com>, <kim.phillips@....com>, <lukas.bulwahn@...il.com>,
	<seanjc@...gle.com>, <jmattson@...gle.com>, <leitao@...ian.org>,
	<jpoimboe@...nel.org>, <rick.p.edgecombe@...el.com>,
	<kirill.shutemov@...ux.intel.com>, <jithu.joseph@...el.com>,
	<kai.huang@...el.com>, <kan.liang@...ux.intel.com>,
	<daniel.sneddon@...ux.intel.com>, <pbonzini@...hat.com>,
	<sandipan.das@....com>, <ilpo.jarvinen@...ux.intel.com>,
	<maciej.wieczor-retman@...el.com>, <linux-doc@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>, <eranian@...gle.com>, <james.morse@....com>
Subject: Re: [PATCH v5 20/20] x86/resctrl: Introduce interface to modify
 assignment states of the groups

Hi Babu and Peter,

On 7/25/24 10:28 AM, Moger, Babu wrote:
> Hi Peter,
> 
> On 7/25/24 12:11, Peter Newman wrote:
>> Hi Babu,
>>
>> On Wed, Jul 24, 2024 at 6:23 PM Moger, Babu <bmoger@....com> wrote:
>>>
>>> Hi Peter,
>>>
>>> On 7/24/2024 7:03 PM, Peter Newman wrote:
>>>> Hi Babu,
>>>>
>>>> On Wed, Jul 3, 2024 at 2:51 PM Babu Moger <babu.moger@....com> wrote:
>>>>>
>>>>> Introduce the interface to enable events in ABMC mode.
>>>>>
>>>>> Events can be enabled or disabled by writing to file
>>>>> /sys/fs/resctrl/info/L3_MON/mbm_control
>>>>>
>>>>> Format is similar to the list format with addition of op-code for the
>>>>> assignment operation.
>>>>>    "<CTRL_MON group>/<MON group>/<op-code><flags>"
>>>>>
>>>>> Format for specific type of groups:
>>>>>
>>>>>    * Default CTRL_MON group:
>>>>>            "//<domain_id><op-code><flags>"
>>>>>
>>>>>    * Non-default CTRL_MON group:
>>>>>            "<CTRL_MON group>//<domain_id><op-code><flags>"
>>>>>
>>>>>    * Child MON group of default CTRL_MON group:
>>>>>            "/<MON group>/<domain_id><op-code><flags>"
>>>>>
>>>>>    * Child MON group of non-default CTRL_MON group:
>>>>>            "<CTRL_MON group>/<MON group>/<domain_id><op-code><flags>"
>>>>
>>>> Just a reminder, Reinette and I had discussed[1] omitting the
>>>> domain_id for performing the same operation on all domains.
>>>
>>> Yes. I remember. Lets refresh our memory.
>>>>
>>>> I would really appreciate this, otherwise our most typical operations
>>>> could be really tedious and needlessly serialized.
>>>
>>>>
>>>> # cat mbm_control
>>>> //0=tl;1=tl;2=tl;3=tl;4=tl;5=tl;6=tl;7=tl;8=tl;9=tl;10=tl;11=tl;12=tl;13=tl;14=tl;15=tl;16=tl;17=tl;18=tl;19=tl;20=tl;21=tl;22=tl;23=tl;24=tl;25=tl;26=tl;27=tl;28=tl;29=tl;30=tl;31=tl;
>>>> # echo '//-l' > mbm_control
>>>
>>> What is the expectation here?
>>> You want to unassign local event on all the domains?
>>
>> Correct.
>>
>>>
>>> Domain id makes it easy to parse the command. Without that it parsing
>>> code becomes  messy.
>>>
>>> How about something like this? We can use the max domain id to mean all
>>> the domains. In the above case there are 32 domains(0-31). 32 is total
>>> number of domains. We can get that details looking through all the
>>> domains. We can print that detail when we list it.
>>
>> This sounds like only a minor simplification to the parsing code. It
>> seems like it would be easy to determine if the final '/' is
>> immediately followed by an opcode (+-=_) rather than a number.
> 
> Ok. Will try to get that working. Will let you know if there are
> complexities with that.--
> Thanks
> Babu Moger

Dave suggested [1]  "*" to indicate "all domains". This seems an intuitive
addition to the interface to accomplish this goal.

Reinette

[1] https://lore.kernel.org/lkml/ZierjRNDMfg5swT8@e133380.arm.com/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ