From: Nikolay Borisov <nik.borisov@suse.com>
To: corbet@lwn.net
Cc: tglx@linutronix.de, bp@alien8.de, x86@kernel.org,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
Nikolay Borisov <nik.borisov@suse.com>
Subject: [PATCH] docs: Remove reference to syscall trampoline in PTI
Date: Thu, 2 Nov 2023 15:02:04 +0200 [thread overview]
Message-ID: <20231102130204.41043-1-nik.borisov@suse.com> (raw)
Commit bf904d2762ee ("x86/pti/64: Remove the SYSCALL64 entry trampoline")
removed the syscall trampoline and instead opted to enable using the
default syscall64 entry point by mapping the percpu TSS. Unfortunately
the PTI documentation wasn't updated when the respective changes were
made, so let's bring the doc up to speed.
Signed-off-by: Nikolay Borisov <nik.borisov@suse.com>
---
Documentation/arch/x86/pti.rst | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/Documentation/arch/x86/pti.rst b/Documentation/arch/x86/pti.rst
index 4b858a9bad8d..e08d35177bc0 100644
--- a/Documentation/arch/x86/pti.rst
+++ b/Documentation/arch/x86/pti.rst
@@ -81,11 +81,9 @@ Protection against side-channel attacks is important. But,
and exit (it can be skipped when the kernel is interrupted,
though.) Moves to CR3 are on the order of a hundred
cycles, and are required at every entry and exit.
- b. A "trampoline" must be used for SYSCALL entry. This
- trampoline depends on a smaller set of resources than the
- non-PTI SYSCALL entry code, so requires mapping fewer
- things into the userspace page tables. The downside is
- that stacks must be switched at entry time.
+ b. Percpu TSS is mapped into the user page tables to allow SYSCALL64 path
+ to work under PTI. This doesn't have a direct runtime cost but it can
+ be argued it opens certain timing attack scenarios.
c. Global pages are disabled for all kernel structures not
mapped into both kernel and userspace page tables. This
feature of the MMU allows different processes to share TLB
@@ -167,7 +165,7 @@ that are worth noting here.
* Failures of the selftests/x86 code. Usually a bug in one of the
more obscure corners of entry_64.S
* Crashes in early boot, especially around CPU bringup. Bugs
- in the trampoline code or mappings cause these.
+ in the mappings cause these.
* Crashes at the first interrupt. Caused by bugs in entry_64.S,
like screwing up a page table switch. Also caused by
incorrectly mapping the IRQ handler entry code.
--
2.34.1
next reply other threads:[~2023-11-02 13:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-02 13:02 Nikolay Borisov [this message]
2023-12-09 11:57 ` Nikolay Borisov
2023-12-12 14:05 ` [tip: x86/cleanups] x86/docs: " tip-bot2 for Nikolay Borisov
2024-01-18 16:03 ` [PATCH] docs: " Nikolay Borisov
2024-01-18 16:11 ` Jonathan Corbet
2024-01-18 16:41 ` Borislav Petkov
2024-01-18 16:52 ` Nikolay Borisov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231102130204.41043-1-nik.borisov@suse.com \
--to=nik.borisov@suse.com \
--cc=bp@alien8.de \
--cc=corbet@lwn.net \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®