<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/x86/kernel/cpu/intel_rdt.c, branch linux-4.14.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.14.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.14.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2020-04-24T06:00:59Z</updated>
<entry>
<title>x86/resctrl: Preserve CDP enable over CPU hotplug</title>
<updated>2020-04-24T06:00:59Z</updated>
<author>
<name>James Morse</name>
</author>
<published>2020-02-21T16:21:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5246c08f70b4d721a48b9a98417cb178fa0531cf'/>
<id>urn:sha1:5246c08f70b4d721a48b9a98417cb178fa0531cf</id>
<content type='text'>
commit 9fe0450785abbc04b0ed5d3cf61fcdb8ab656b4b upstream.

Resctrl assumes that all CPUs are online when the filesystem is mounted,
and that CPUs remember their CDP-enabled state over CPU hotplug.

This goes wrong when resctrl's CDP-enabled state changes while all the
CPUs in a domain are offline.

When a domain comes online, enable (or disable!) CDP to match resctrl's
current setting.

Fixes: 5ff193fbde20 ("x86/intel_rdt: Add basic resctrl filesystem support")
Suggested-by: Reinette Chatre &lt;reinette.chatre@intel.com&gt;
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Signed-off-by: Borislav Petkov &lt;bp@suse.de&gt;
Cc: &lt;stable@vger.kernel.org&gt;
Link: https://lkml.kernel.org/r/20200221162105.154163-1-james.morse@arm.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/intel_rdt: Add two new resources for L2 Code and Data Prioritization (CDP)</title>
<updated>2020-04-24T06:00:59Z</updated>
<author>
<name>Fenghua Yu</name>
</author>
<published>2017-12-20T22:57:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=73e3d7823560741d3473a62c7b1c150c4641f8a4'/>
<id>urn:sha1:73e3d7823560741d3473a62c7b1c150c4641f8a4</id>
<content type='text'>
commit def10853930a82456ab862a3a8292a3a16c386e7 upstream.

L2 data and L2 code are added as new resources in rdt_resources_all[]
and data in the resources are configured.

When L2 CDP is enabled, the schemata will have the two resources in
this format:
L2DATA:l2id0=xxxx;l2id1=xxxx;....
L2CODE:l2id0=xxxx;l2id1=xxxx;....

xxxx represent CBM (Cache Bit Mask) values in the schemata, similar to all
others (L2 CAT/L3 CAT/L3 CDP).

Signed-off-by: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: "Ravi V Shankar" &lt;ravi.v.shankar@intel.com&gt;
Cc: "Tony Luck" &lt;tony.luck@intel.com&gt;
Cc: Vikas" &lt;vikas.shivappa@intel.com&gt;
Cc: Sai Praneeth" &lt;sai.praneeth.prakhya@intel.com&gt;
Cc: Reinette" &lt;reinette.chatre@intel.com&gt;
Link: https://lkml.kernel.org/r/1513810644-78015-5-git-send-email-fenghua.yu@intel.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/resctrl: Fix an imbalance in domain_remove_cpu()</title>
<updated>2020-01-23T07:20:32Z</updated>
<author>
<name>Qian Cai</name>
</author>
<published>2019-12-11T03:30:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bf76318ed06c298d8464923dce81edf6ef349931'/>
<id>urn:sha1:bf76318ed06c298d8464923dce81edf6ef349931</id>
<content type='text'>
commit e278af89f1ba0a9ef20947db6afc2c9afa37e85b upstream.

A system that supports resource monitoring may have multiple resources
while not all of these resources are capable of monitoring. Monitoring
related state is initialized only for resources that are capable of
monitoring and correspondingly this state should subsequently only be
removed from these resources that are capable of monitoring.

domain_add_cpu() calls domain_setup_mon_state() only when r-&gt;mon_capable
is true where it will initialize d-&gt;mbm_over. However,
domain_remove_cpu() calls cancel_delayed_work(&amp;d-&gt;mbm_over) without
checking r-&gt;mon_capable resulting in an attempt to cancel d-&gt;mbm_over on
all resources, even those that never initialized d-&gt;mbm_over because
they are not capable of monitoring. Hence, it triggers a debugobjects
warning when offlining CPUs because those timer debugobjects are never
initialized:

  ODEBUG: assert_init not available (active state 0) object type:
  timer_list hint: 0x0
  WARNING: CPU: 143 PID: 789 at lib/debugobjects.c:484
  debug_print_object
  Hardware name: HP Synergy 680 Gen9/Synergy 680 Gen9 Compute Module, BIOS I40 05/23/2018
  RIP: 0010:debug_print_object
  Call Trace:
  debug_object_assert_init
  del_timer
  try_to_grab_pending
  cancel_delayed_work
  resctrl_offline_cpu
  cpuhp_invoke_callback
  cpuhp_thread_fun
  smpboot_thread_fn
  kthread
  ret_from_fork

Fixes: e33026831bdb ("x86/intel_rdt/mbm: Handle counter overflow")
Signed-off-by: Qian Cai &lt;cai@lca.pw&gt;
Signed-off-by: Borislav Petkov &lt;bp@suse.de&gt;
Acked-by: Reinette Chatre &lt;reinette.chatre@intel.com&gt;
Cc: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Cc: "H. Peter Anvin" &lt;hpa@zytor.com&gt;
Cc: Ingo Molnar &lt;mingo@redhat.com&gt;
Cc: john.stultz@linaro.org
Cc: sboyd@kernel.org
Cc: &lt;stable@vger.kernel.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: tj@kernel.org
Cc: Tony Luck &lt;tony.luck@intel.com&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Cc: x86-ml &lt;x86@kernel.org&gt;
Link: https://lkml.kernel.org/r/20191211033042.2188-1-cai@lca.pw
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/intel_rdt: Enable CMT and MBM on new Skylake stepping</title>
<updated>2018-06-26T00:06:32Z</updated>
<author>
<name>Tony Luck</name>
</author>
<published>2018-06-08T16:07:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2d58a9ac892a2c08480a113f1fb0f55dbf85e2bb'/>
<id>urn:sha1:2d58a9ac892a2c08480a113f1fb0f55dbf85e2bb</id>
<content type='text'>
commit 1d9f3e20a56d33e55748552aeec597f58542f92d upstream.

New stepping of Skylake has fixes for cache occupancy and memory
bandwidth monitoring.

Update the code to enable these by default on newer steppings.

Signed-off-by: Tony Luck &lt;tony.luck@intel.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Cc: stable@vger.kernel.org # v4.14
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Link: https://lkml.kernel.org/r/20180608160732.9842-1-tony.luck@intel.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/cpu: Rename cpu_data.x86_mask to cpu_data.x86_stepping</title>
<updated>2018-02-22T14:42:24Z</updated>
<author>
<name>Jia Zhang</name>
</author>
<published>2018-01-01T01:52:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=325cbb04dc61692ba01445c34fd551ad91df9e6d'/>
<id>urn:sha1:325cbb04dc61692ba01445c34fd551ad91df9e6d</id>
<content type='text'>
commit b399151cb48db30ad1e0e93dd40d68c6d007b637 upstream.

x86_mask is a confusing name which is hard to associate with the
processor's stepping.

Additionally, correct an indent issue in lib/cpu.c.

Signed-off-by: Jia Zhang &lt;qianyue.zj@alibaba-inc.com&gt;
[ Updated it to more recent kernels. ]
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: bp@alien8.de
Cc: tony.luck@intel.com
Link: http://lkml.kernel.org/r/1514771530-70829-1-git-send-email-qianyue.zj@alibaba-inc.com
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/intel_rdt/cqm: Prevent use after free</title>
<updated>2018-01-23T18:58:14Z</updated>
<author>
<name>Thomas Gleixner</name>
</author>
<published>2018-01-16T18:59:59Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=929e4b35023634b421605211c4e1c59b245edd3a'/>
<id>urn:sha1:929e4b35023634b421605211c4e1c59b245edd3a</id>
<content type='text'>
commit d47924417319e3b6a728c0b690f183e75bc2a702 upstream.

intel_rdt_iffline_cpu() -&gt; domain_remove_cpu() frees memory first and then
proceeds accessing it.

 BUG: KASAN: use-after-free in find_first_bit+0x1f/0x80
 Read of size 8 at addr ffff883ff7c1e780 by task cpuhp/31/195
 find_first_bit+0x1f/0x80
 has_busy_rmid+0x47/0x70
 intel_rdt_offline_cpu+0x4b4/0x510

 Freed by task 195:
 kfree+0x94/0x1a0
 intel_rdt_offline_cpu+0x17d/0x510

Do the teardown first and then free memory.

Fixes: 24247aeeabe9 ("x86/intel_rdt/cqm: Improve limbo list processing")
Reported-by: Joseph Salisbury &lt;joseph.salisbury@canonical.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Ravi Shankar &lt;ravi.v.shankar@intel.com&gt;
Cc: Peter Zilstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Cc: Andi Kleen &lt;ak@linux.intel.com&gt;
Cc: "Roderick W. Smith" &lt;rod.smith@canonical.com&gt;
Cc: 1733662@bugs.launchpad.net
Cc: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Cc: Tony Luck &lt;tony.luck@intel.com&gt;
Link: https://lkml.kernel.org/r/alpine.DEB.2.20.1801161957510.2366@nanos
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>x86/intel_rdt: Initialize bitmask of shareable resource if CDP enabled</title>
<updated>2017-12-10T12:40:40Z</updated>
<author>
<name>Reinette Chatre</name>
</author>
<published>2017-10-20T09:16:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=24567dc3cc8a9fb6f7ac7e9a5040e839efe3716c'/>
<id>urn:sha1:24567dc3cc8a9fb6f7ac7e9a5040e839efe3716c</id>
<content type='text'>
[ Upstream commit 95953034fb24c16ad0047a98b16427e5935830c4 ]

The platform informs via CPUID.(EAX=0x10, ECX=res#):EBX[31:0] (valid res#
are only 1 for L3 and 2 for L2) which unit of the allocation may be used by
other entities in the platform. This information is valid whether CDP (Code
and Data Prioritization) is enabled or not.

Ensure that the bitmask of shareable resource is initialized when CDP is
enabled.

Fixes: 0dd2d7494cd8 ("x86/intel_rdt: Show bitmask of shareable resource with other executing units"
Signed-off-by: Reinette Chatre &lt;reinette.chatre@intel.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Acked-by: Fenghua Yu &lt;fenghua.yu@intel.com&gt;
Acked-by: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Acked-by: Tony Luck &lt;tony.luck@intel.com&gt;
Link: https://lkml.kernel.org/r/815747bddc820ca221a8924edaf4d1a7324547e4.1508490116.git.reinette.chatre@intel.com
Signed-off-by: Sasha Levin &lt;alexander.levin@verizon.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>x86/intel_rdt: Turn off most RDT features on Skylake</title>
<updated>2017-08-25T20:00:45Z</updated>
<author>
<name>Tony Luck</name>
</author>
<published>2017-08-24T16:26:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d56593eb5eda8f593db92927059697bbf89bc4b3'/>
<id>urn:sha1:d56593eb5eda8f593db92927059697bbf89bc4b3</id>
<content type='text'>
Errata list is included in this document:
https://www.intel.com/content/dam/www/public/us/en/documents/specification-updates/6th-gen-x-series-spec-update.pdf
with more details in:
https://www.intel.com/content/www/us/en/processors/xeon/scalable/xeon-scalable-spec-update.html

But the tl;dr summary (using tags from first of the documents) is:
SKZ4  MBM does not accurately track write bandwidth
SKZ17 CMT counters may not count accurately
SKZ18 CAT may not restrict cacheline allocation under certain conditions
SKZ19 MBM counters may undercount

Disable all these features on Skylake models. Users who understand the
errata may re-enable using boot command line options.

Signed-off-by: Tony Luck &lt;tony.luck@intel.com&gt;
Cc: Fenghua" &lt;fenghua.yu@intel.com&gt;
Cc: Ravi V" &lt;ravi.v.shankar@intel.com&gt;
Cc: "Peter Zijlstra" &lt;peterz@infradead.org&gt;
Cc: "Stephane Eranian" &lt;eranian@google.com&gt;
Cc: "Andi Kleen" &lt;ak@linux.intel.com&gt;
Cc: "David Carrillo-Cisneros" &lt;davidcc@google.com&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Link: http://lkml.kernel.org/r/3aea0a3bae219062c812668bd9b7b8f1a25003ba.1503512900.git.tony.luck@intel.com
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;

</content>
</entry>
<entry>
<title>x86/intel_rdt: Add command line options for resource director technology</title>
<updated>2017-08-25T20:00:45Z</updated>
<author>
<name>Tony Luck</name>
</author>
<published>2017-08-24T16:26:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1d9807fc64c131a83a96917f2b2da1c9b00cf127'/>
<id>urn:sha1:1d9807fc64c131a83a96917f2b2da1c9b00cf127</id>
<content type='text'>
Command line options allow us to ignore features that we don't want.
Also we can re-enable options that have been disabled on a platform
(so long as the underlying h/w actually supports the option).

[ tglx: Marked the option array __initdata and the helper function __init ]

Signed-off-by: Tony Luck &lt;tony.luck@intel.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Fenghua" &lt;fenghua.yu@intel.com&gt;
Cc: Ravi V" &lt;ravi.v.shankar@intel.com&gt;
Cc: "Peter Zijlstra" &lt;peterz@infradead.org&gt;
Cc: "Stephane Eranian" &lt;eranian@google.com&gt;
Cc: "Andi Kleen" &lt;ak@linux.intel.com&gt;
Cc: "David Carrillo-Cisneros" &lt;davidcc@google.com&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Link: http://lkml.kernel.org/r/0c37b0d4dbc30977a3c1cee08b66420f83662694.1503512900.git.tony.luck@intel.com

</content>
</entry>
<entry>
<title>x86/intel_rdt: Move special case code for Haswell to a quirk function</title>
<updated>2017-08-25T20:00:44Z</updated>
<author>
<name>Tony Luck</name>
</author>
<published>2017-08-24T16:26:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0576113a387e0c8a5d9e24b4cd62605d1c9c0db8'/>
<id>urn:sha1:0576113a387e0c8a5d9e24b4cd62605d1c9c0db8</id>
<content type='text'>
No functional change, but lay the ground work for other per-model
quirks.

Signed-off-by: Tony Luck &lt;tony.luck@intel.com&gt;
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Fenghua" &lt;fenghua.yu@intel.com&gt;
Cc: Ravi V" &lt;ravi.v.shankar@intel.com&gt;
Cc: "Peter Zijlstra" &lt;peterz@infradead.org&gt;
Cc: "Stephane Eranian" &lt;eranian@google.com&gt;
Cc: "Andi Kleen" &lt;ak@linux.intel.com&gt;
Cc: "David Carrillo-Cisneros" &lt;davidcc@google.com&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@linux.intel.com&gt;
Link: http://lkml.kernel.org/r/f195a83751b5f8b1d8a78bd3c1914300c8fa3142.1503512900.git.tony.luck@intel.com

</content>
</entry>
</feed>
