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-next>] [day] [month] [year] [list]
Message-ID: <20241003191228.67541-1-tony.luck@intel.com>
Date: Thu,  3 Oct 2024 12:12:24 -0700
From: Tony Luck <tony.luck@...el.com>
To: Fenghua Yu <fenghua.yu@...el.com>,
	Reinette Chatre <reinette.chatre@...el.com>,
	Peter Newman <peternewman@...gle.com>,
	Jonathan Corbet <corbet@....net>,
	Shuah Khan <skhan@...uxfoundation.org>,
	x86@...nel.org
Cc: Shaopeng Tan <tan.shaopeng@...itsu.com>,
	James Morse <james.morse@....com>,
	Jamie Iles <quic_jiles@...cinc.com>,
	Babu Moger <babu.moger@....com>,
	Randy Dunlap <rdunlap@...radead.org>,
	linux-kernel@...r.kernel.org,
	linux-doc@...r.kernel.org,
	patches@...ts.linux.dev,
	Tony Luck <tony.luck@...el.com>
Subject: [PATCH v7 0/4] x86/resctrl: mba_MBps enhancements

[
	Bringing this old patch series out of hibernation since last December
]

Two changes relating to the MBA Software Controller(mba_sc):

1) Add a new mount option so the user can choose which memory
bandwidth monitoring event to use as the input to the feedback
loop.

2) Update the "mba_MBps" mount option to make use of total memory
bandwidth event on systems that do not support local bandwidth
event.

Signed-off-by: Tony Luck <tony.luck@...el.com>

---
Changes since v6: https://lore.kernel.org/all/20231207195613.153980-1-tony.luck@intel.com/

Peter Newman:
	s/"mbm_Local_bytes"/"mbm_local_bytes"/
	Added WARN_ON() to check non-null return from get_mbm_state()
	Don't allow both local and total mount options at same time

Reinette Chatre:
	Use flag (enable_mba_mbps) and value (mba_mbps_event) in
	struct rdt_fs_context. Then pass the value to r->membw.mba_mbps_event
	Ditto Peter's comment to block multiple uses of mount options.
	Use invalfc() for better error reporting to user
	Note in kerneldoc that mba_mbps_event only valid when @mba_sc is true
	Declare mba_sc_event_opt_name() as "const char *"
	Rework resctrl.rst patch based on comments

Babu Moger:
	Clean up calling sequence for set_mba_sc() to avoid dummy 2nd argument

Other changes:
	I split first patch into two parts:
	1) the periodic updates to use r->membw.mba_mbps_event to choose
	   the event
	2) The new mount option

	Also noticed code duplication in mbm_update() as the local
	and total clauses are now identical. Split that code into
	a helper function mbm_update_one_event()


Tony Luck (4):
  x86/resctrl: Make input event for MBA Software Controller configurable
  x86/resctrl: Add mount option to pick input event for mba_MBps mode
  x86/resctrl: Use total bandwidth for mba_MBps option when local isn't
    present
  x86/resctrl: Add new "mba_MBps_event" mount option to documentation

 Documentation/arch/x86/resctrl.rst     | 27 +++++++--
 include/linux/resctrl.h                |  2 +
 arch/x86/kernel/cpu/resctrl/internal.h |  1 +
 arch/x86/kernel/cpu/resctrl/monitor.c  | 80 ++++++++++++--------------
 arch/x86/kernel/cpu/resctrl/rdtgroup.c | 51 +++++++++++++---
 5 files changed, 102 insertions(+), 59 deletions(-)

-- 
2.46.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ