]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.9-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 14 Jul 2022 18:33:37 +0000 (20:33 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 14 Jul 2022 18:33:37 +0000 (20:33 +0200)
added patches:
arm64-entry-restore-tramp_map_kernel-isb.patch

queue-4.9/arm64-entry-restore-tramp_map_kernel-isb.patch [new file with mode: 0644]
queue-4.9/series

diff --git a/queue-4.9/arm64-entry-restore-tramp_map_kernel-isb.patch b/queue-4.9/arm64-entry-restore-tramp_map_kernel-isb.patch
new file mode 100644 (file)
index 0000000..9c1883f
--- /dev/null
@@ -0,0 +1,43 @@
+From james.morse@arm.com  Thu Jul 14 20:32:47 2022
+From: James Morse <james.morse@arm.com>
+Date: Thu, 14 Jul 2022 17:22:25 +0100
+Subject: arm64: entry: Restore tramp_map_kernel ISB
+To: stable@vger.kernel.org, linux-arm-kernel@lists.infradead.org
+Cc: Catalin Marinas <catalin.marinas@arm.com>, James Morse <james.morse@arm.com>, Sumit Gupta <sumitg@nvidia.com>
+Message-ID: <20220714162225.280073-1-james.morse@arm.com>
+
+From: James Morse <james.morse@arm.com>
+
+Summit reports that the BHB backports for v4.9 prevent vulnerable
+platforms from booting when CONFIG_RANDOMIZE_BASE is enabled.
+
+This is because the trampoline code takes a translation fault when
+accessing the data page, because the TTBR write hasn't been completed
+by an ISB before the access is made.
+
+Upstream has a complex erratum workaround for QCOM_FALKOR_E1003 in
+this area, which removes the ISB when the workaround has been applied.
+v4.9 lacks this workaround, but should still have the ISB.
+
+Restore the barrier.
+
+Fixes: aee10c2dd013 ("arm64: entry: Add macro for reading symbol addresses from the trampoline")
+Reported-by: Sumit Gupta <sumitg@nvidia.com>
+Tested-by: Sumit Gupta <sumitg@nvidia.com>
+Cc: <stable@vger.kernel.org>
+Signed-off-by: James Morse <james.morse@arm.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ arch/arm64/kernel/entry.S |    1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/arch/arm64/kernel/entry.S
++++ b/arch/arm64/kernel/entry.S
+@@ -964,6 +964,7 @@ __ni_sys_trace:
+       b       .
+ 2:
+       tramp_map_kernel        x30
++      isb
+       tramp_data_read_var     x30, vectors
+       prfm    plil1strm, [x30, #(1b - \vector_start)]
+       msr     vbar_el1, x30
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..5a1d522c86fc556233405e9d7264868339ee2d1a 100644 (file)
@@ -0,0 +1 @@
+arm64-entry-restore-tramp_map_kernel-isb.patch