linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] PTI for x86-32 Fixes and Updates
@ 2018-07-20 16:22 Joerg Roedel
  2018-07-20 16:22 ` [PATCH 1/3] perf/core: Make sure the ring-buffer is mapped in all page-tables Joerg Roedel
                   ` (4 more replies)
  0 siblings, 5 replies; 34+ messages in thread
From: Joerg Roedel @ 2018-07-20 16:22 UTC (permalink / raw)
  To: Thomas Gleixner, Ingo Molnar, H . Peter Anvin
  Cc: x86, linux-kernel, linux-mm, Linus Torvalds, Andy Lutomirski,
	Dave Hansen, Josh Poimboeuf, Juergen Gross, Peter Zijlstra,
	Borislav Petkov, Jiri Kosina, Boris Ostrovsky, Brian Gerst,
	David Laight, Denys Vlasenko, Eduardo Valentin, Greg KH,
	Will Deacon, aliguori, daniel.gruss, hughd, keescook,
	Andrea Arcangeli, Waiman Long, Pavel Machek,
	David H . Gutteridge, jroedel, Arnaldo Carvalho de Melo,
	Alexander Shishkin, Jiri Olsa, Namhyung Kim, joro

Hi,

here are 3 patches which update the PTI-x86-32 patches recently merged
into the tip-tree. The patches are ordered by importance:

	Patch 1: Very important, it fixes a vmalloc-fault in NMI context
		 when PTI is enabled. This is pretty unlikely to hit
		 when starting perf on an idle machine, which is why I
		 didn't find it earlier in my testing. I always started
		 'perf top' first :/ But when I start 'perf top' last
		 when the kernel-compile already runs, it hits almost
		 immediatly.

	Patch 2: Fix the 'from-kernel-check' in SWITCH_TO_KERNEL_STACK
	         to also take VM86 into account. This is not strictly
		 necessary because the slow-path also works for VM86
		 mode but it is not how the code was intended to work.
		 And it breaks when Patch 3 is applied on-top.

	Patch 3: Implement the reduced copying in the paranoid
		 entry/exit path as suggested by Andy Lutomirski while
		 reviewing version 7 of the original patches.

I have the x86/tip branch with these patches on-top running my test for
6h now, with no issues so far. So for now it looks like there are no
scheduling points or irq-enabled sections reached from the paranoid
entry/exit paths and we always return to the entry-stack we came from.

I keep the test running over the weekend at least.

Please review.

[ If Patch 1 looks good to the maintainers I suggest applying it soon,
  before too many linux-next testers run into this issue. It is actually
  the reason why I send out the patches _now_ and didn't wait until next
  week when the other two patches got more testing from my side. ]

Thanks,

	Joerg

Joerg Roedel (3):
  perf/core: Make sure the ring-buffer is mapped in all page-tables
  x86/entry/32: Check for VM86 mode in slow-path check
  x86/entry/32: Copy only ptregs on paranoid entry/exit path

 arch/x86/entry/entry_32.S   | 82 ++++++++++++++++++++++++++-------------------
 kernel/events/ring_buffer.c | 10 ++++++
 2 files changed, 58 insertions(+), 34 deletions(-)

-- 
2.7.4


^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2018-07-26  3:47 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-20 16:22 [PATCH 0/3] PTI for x86-32 Fixes and Updates Joerg Roedel
2018-07-20 16:22 ` [PATCH 1/3] perf/core: Make sure the ring-buffer is mapped in all page-tables Joerg Roedel
2018-07-20 17:06   ` Andy Lutomirski
2018-07-20 17:48     ` Joerg Roedel
2018-07-20 19:32       ` Andy Lutomirski
2018-07-20 21:37         ` Joerg Roedel
2018-07-20 22:20           ` Andy Lutomirski
2018-07-21 21:06             ` Linus Torvalds
2018-07-20 19:27     ` Thomas Gleixner
2018-07-20 19:33       ` Andy Lutomirski
2018-07-20 19:43         ` Thomas Gleixner
2018-07-20 19:53           ` Thomas Gleixner
2018-07-20 19:37   ` [tip:x86/pti] " tip-bot for Joerg Roedel
2018-07-20 20:36   ` tip-bot for Joerg Roedel
2018-07-20 16:22 ` [PATCH 2/3] x86/entry/32: Check for VM86 mode in slow-path check Joerg Roedel
2018-07-20 19:37   ` [tip:x86/pti] " tip-bot for Joerg Roedel
2018-07-20 20:37   ` tip-bot for Joerg Roedel
2018-07-21 16:06   ` [PATCH 2/3] " Pavel Machek
2018-07-20 16:22 ` [PATCH 3/3] x86/entry/32: Copy only ptregs on paranoid entry/exit path Joerg Roedel
2018-07-20 17:09   ` Andy Lutomirski
2018-07-20 21:42     ` Joerg Roedel
2018-07-23  3:49 ` [PATCH 0/3] PTI for x86-32 Fixes and Updates David H. Gutteridge
2018-07-23  7:29   ` Joerg Roedel
2018-07-26  3:47     ` David H. Gutteridge
2018-07-23 14:09 ` Pavel Machek
2018-07-23 19:00   ` Linus Torvalds
2018-07-23 21:38     ` Pavel Machek
2018-07-23 21:50       ` Andy Lutomirski
2018-07-23 21:55         ` Pavel Machek
2018-07-24 21:18         ` Pavel Machek
2018-07-23 21:59       ` Josh Poimboeuf
2018-07-23 22:07         ` Dave Hansen
2018-07-24 13:39     ` Pavel Machek
2018-07-24 14:39       ` Andy Lutomirski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).