mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Reinette Chatre <reinette.chatre@intel.com>
To: "Luck, Tony" <tony.luck@intel.com>,
	"Yu, Fenghua" <fenghua.yu@intel.com>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
	Dave Hansen <dave.hansen@linux.intel.com>,
	"H. Peter Anvin" <hpa@zytor.com>,
	Shaopeng Tan <tan.shaopeng@fujitsu.com>,
	Jamie Iles <quic_jiles@quicinc.com>,
	James Morse <james.morse@arm.com>,
	"Babu Moger" <babu.moger@amd.com>
Cc: "x86@kernel.org" <x86@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [RFC PATCH 0/7] Add driver registration i/f to resctrl
Date: Fri, 12 May 2023 14:08:38 -0700	[thread overview]
Message-ID: <1c3545d6-3687-a380-9e63-87be9e8b1305@intel.com> (raw)
In-Reply-To: <SJ1PR11MB6083CB61BDCABA2930155C2AFC759@SJ1PR11MB6083.namprd11.prod.outlook.com>

Hi Tony,

On 5/12/2023 1:35 PM, Luck, Tony wrote:

>>> The driver provides a way to set param1, param2, param3 for each of
>>> the A, B, C, D instances.
>>
>> Seems like these could be some new RFTYPE_RES_XYZ files?
> 
> In my current implementation the driver can make some/all of the files added
> under the info/ directory writable. So this XYZ driver uses info/XYZ/param* files
> as the interface for the user to set the parameters.

It sounds as though you are concerned about making info/* files writable?
I am not sure because whether the files are made writable via the core or
a driver does not matter since it will still be writable from the user
interface perspective.

Please note that there already are a few info files that are writable:
info/L3_MON/max_threshold_occupancy
info/L3_MON/mbm_total_bytes_config
info/L3_MON/mbm_local_bytes_config

It thus seems appropriate to use the info/* files as global resource
configuration and files within the resource groups handling local
configurations.

>> On the model specific motivation topic: If the goal of the driver
>> interface is to support model specific changes to resctrl there is a
>> publicly available use case for consideration:
>> https://lore.kernel.org/lkml/20230421141723.2405942-1-peternewman@google.com/
>>
>> It is not obvious to me how that model specific problem could be solved
>> with this driver interface. Your insight here would be appreciated but it
>> seems to me that we will have to keep accommodating model specific code
>> in resctrl.
> 
> All my drivers are currently related to the control features of resctrl rather than the
> monitor features. I don't see a way for a model specific driver to step in and mitigate
> that particular problem that Peter has.
> 
> Seems quite hacky though. The trick with the "hard" RMID per core is going to miscount
> LLC eviction traffic. If a core is switching rapidly between tasks with different RMIDs
> that could be a significant difference from actual values.

The submission is upfront about this and indeed disables LLC occupancy 
when "soft RMIDs" are enabled.
Please do provide direct feedback to that submission.

> But requests for some model specific quirks to work around h/w limitations doesn't
> mean that we shouldn't create a driver layer for cases where it is possible to
> separate s/w into layers.

Some of my questions were trimmed from replies without answers
so I am still trying to understand the driver interface motivation that
something being model specific is hard to integrate.

Reinette

      reply	other threads:[~2023-05-12 21:11 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-20 22:06 Tony Luck
2023-04-20 22:06 ` [RFC PATCH 1/7] x86/resctrl: Add register/unregister functions for driver to hook into resctrl Tony Luck
2023-05-05 23:17   ` Reinette Chatre
2023-04-20 22:06 ` [RFC PATCH 2/7] x86/resctrl: Add an interface to add/remove a new info/directory Tony Luck
2023-04-20 22:06 ` [RFC PATCH 3/7] x86/resctrl: Add driver callback when directories are removed Tony Luck
2023-05-05 23:19   ` Reinette Chatre
2023-04-20 22:06 ` [RFC PATCH 4/7] x86/resctrl: Add capability to driver registration to create control files Tony Luck
2023-05-05 23:20   ` Reinette Chatre
2023-04-20 22:06 ` [RFC PATCH 5/7] x86/resctrl: Enhance driver registration to hook into schemata files Tony Luck
2023-05-05 23:20   ` Reinette Chatre
2023-04-20 22:06 ` [RFC PATCH 6/7] x86/resctrl: Allow a device to override an existing schemata entry Tony Luck
2023-05-05 23:20   ` Reinette Chatre
2023-04-20 22:06 ` [RFC PATCH 7/7] x86/resctrl: Example resctrl driver Tony Luck
2023-05-05 23:17 ` [RFC PATCH 0/7] Add driver registration i/f to resctrl Reinette Chatre
2023-05-08 18:32   ` Luck, Tony
2023-05-09 21:34     ` Reinette Chatre
2023-05-09 23:35       ` Luck, Tony
2023-05-10  0:07         ` Reinette Chatre
2023-05-10  0:52           ` Luck, Tony
2023-05-11 20:35         ` Luck, Tony
2023-05-12 16:57           ` Reinette Chatre
2023-05-12 20:35             ` Luck, Tony
2023-05-12 21:08               ` Reinette Chatre [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1c3545d6-3687-a380-9e63-87be9e8b1305@intel.com \
    --to=reinette.chatre@intel.com \
    --cc=babu.moger@amd.com \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=fenghua.yu@intel.com \
    --cc=hpa@zytor.com \
    --cc=james.morse@arm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=quic_jiles@quicinc.com \
    --cc=tan.shaopeng@fujitsu.com \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --cc=x86@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®