summaryrefslogtreecommitdiffstats
path: root/Documentation/scheduler/sched-rt-group.txt
diff options
context:
space:
mode:
authorAndy Lutomirski <luto@kernel.org>2017-09-17 18:03:49 +0200
committerIngo Molnar <mingo@kernel.org>2017-09-17 18:59:08 +0200
commit52a2af400c1075219b3f0ce5c96fc961da44018a (patch)
tree0d51c712a3dbb9a18dd2adee5b786704fca48718 /Documentation/scheduler/sched-rt-group.txt
parentx86/mm: Factor out CR3-building code (diff)
downloadlinux-52a2af400c1075219b3f0ce5c96fc961da44018a.tar.xz
linux-52a2af400c1075219b3f0ce5c96fc961da44018a.zip
x86/mm/64: Stop using CR3.PCID == 0 in ASID-aware code
Putting the logical ASID into CR3's PCID bits directly means that we have two cases to consider separately: ASID == 0 and ASID != 0. This means that bugs that only hit in one of these cases trigger nondeterministically. There were some bugs like this in the past, and I think there's still one in current kernels. In particular, we have a number of ASID-unware code paths that save CR3, write some special value, and then restore CR3. This includes suspend/resume, hibernate, kexec, EFI, and maybe other things I've missed. This is currently dangerous: if ASID != 0, then this code sequence will leave garbage in the TLB tagged for ASID 0. We could potentially see corruption when switching back to ASID 0. In principle, an initialize_tlbstate_and_flush() call after these sequences would solve the problem, but EFI, at least, does not call this. (And it probably shouldn't -- initialize_tlbstate_and_flush() is rather expensive.) Signed-off-by: Andy Lutomirski <luto@kernel.org> Cc: Borislav Petkov <bpetkov@suse.de> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Link: http://lkml.kernel.org/r/cdc14bbe5d3c3ef2a562be09a6368ffe9bd947a6.1505663533.git.luto@kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'Documentation/scheduler/sched-rt-group.txt')
0 files changed, 0 insertions, 0 deletions