]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.19-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 24 Jun 2019 09:21:51 +0000 (17:21 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 24 Jun 2019 09:21:51 +0000 (17:21 +0800)
added patches:
x86-resctrl-don-t-stop-walking-closids-when-a-locksetup-group-is-found.patch

queue-4.19/series
queue-4.19/x86-resctrl-don-t-stop-walking-closids-when-a-locksetup-group-is-found.patch [new file with mode: 0644]

index 59cd71c7caa9119109570f312ff56f142a2ae629..a2884f7f4f33c62ea8f34487c4930c8c6548aa12 100644 (file)
@@ -87,3 +87,4 @@ nl-mac-80211-allow-4addr-ap-operation-on-crypto-controlled-devices.patch
 mac80211-handle-deauthentication-disassociation-from-tdls-peer.patch
 nl80211-fix-station_info-pertid-memory-leak.patch
 mac80211-do-not-use-stack-memory-with-scatterlist-for-gmac.patch
+x86-resctrl-don-t-stop-walking-closids-when-a-locksetup-group-is-found.patch
diff --git a/queue-4.19/x86-resctrl-don-t-stop-walking-closids-when-a-locksetup-group-is-found.patch b/queue-4.19/x86-resctrl-don-t-stop-walking-closids-when-a-locksetup-group-is-found.patch
new file mode 100644 (file)
index 0000000..71224c6
--- /dev/null
@@ -0,0 +1,51 @@
+From 87d3aa28f345bea77c396855fa5d5fec4c24461f Mon Sep 17 00:00:00 2001
+From: James Morse <james.morse@arm.com>
+Date: Mon, 3 Jun 2019 18:25:31 +0100
+Subject: x86/resctrl: Don't stop walking closids when a locksetup group is found
+
+From: James Morse <james.morse@arm.com>
+
+commit 87d3aa28f345bea77c396855fa5d5fec4c24461f upstream.
+
+When a new control group is created __init_one_rdt_domain() walks all
+the other closids to calculate the sets of used and unused bits.
+
+If it discovers a pseudo_locksetup group, it breaks out of the loop.  This
+means any later closid doesn't get its used bits added to used_b.  These
+bits will then get set in unused_b, and added to the new control group's
+configuration, even if they were marked as exclusive for a later closid.
+
+When encountering a pseudo_locksetup group, we should continue. This is
+because "a resource group enters 'pseudo-locked' mode after the schemata is
+written while the resource group is in 'pseudo-locksetup' mode." When we
+find a pseudo_locksetup group, its configuration is expected to be
+overwritten, we can skip it.
+
+Fixes: dfe9674b04ff6 ("x86/intel_rdt: Enable entering of pseudo-locksetup mode")
+Signed-off-by: James Morse <james.morse@arm.com>
+Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
+Acked-by: Reinette Chatre <reinette.chatre@intel.com>
+Cc: Fenghua Yu <fenghua.yu@intel.com>
+Cc: Borislav Petkov <bp@alien8.de>
+Cc: H Peter Avin <hpa@zytor.com>
+Cc: <stable@vger.kernel.org>
+Link: https://lkml.kernel.org/r/20190603172531.178830-1-james.morse@arm.com
+[Dropped comment due to lack of space]
+Signed-off-by: James Morse <james.morse@arm.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ arch/x86/kernel/cpu/intel_rdt_rdtgroup.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/x86/kernel/cpu/intel_rdt_rdtgroup.c
++++ b/arch/x86/kernel/cpu/intel_rdt_rdtgroup.c
+@@ -2379,7 +2379,7 @@ static int rdtgroup_init_alloc(struct rd
+                               if (closid_allocated(i) && i != closid) {
+                                       mode = rdtgroup_mode_by_closid(i);
+                                       if (mode == RDT_MODE_PSEUDO_LOCKSETUP)
+-                                              break;
++                                              continue;
+                                       used_b |= *ctrl;
+                                       if (mode == RDT_MODE_SHAREABLE)
+                                               d->new_ctrl |= *ctrl;