Skip to content

x86 entry stuff, maybe for 4.4

Andy Lutomirski lkml 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest5 patches 8 repliesIn review
  2. v24 patches 1 replySuperseded
  3. v14 patches 13 repliesSuperseded

Changes from v1 from the cover letter

- CALL_ENTER_FROM_USER_MODE is now CALL_enter_from_user_mode (Ingo)
- STATIC_JUMP_IF_{TRUE,FALSE} now cannot be (mis-)used on non-jump-label kernels (Thomas)
- Comments are better (Borislav)

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5x86/entry/64: Fix irqflag tracing wrt context trackingarch/x86/entry/entry_64.S+18 -10 replies
2/5context_tracking: Switch to new static_branch APIinclude/linux/context_tracking_state.h kernel/context_tracking.c+4 -40 replies
3/5x86/asm: Error out if asm/jump_label.h is included inappropriatelyarch/x86/include/asm/jump_label.h+13 -01 reply
4/5x86/asm: Add asm macros for static keys/jump labelsarch/x86/include/asm/jump_label.h+44 -81 reply
5/5x86/entry/64: Bypass enter_from_user_mode on non-context-tracking bootsarch/x86/entry/calling.h arch/x86/entry/entry_64.S+17 -66 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchThomas Gleixner
1/5R-b
2/5R-b
3/5R-b
4/5R-b
5/5R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/5] x86 entry stuff, maybe for 4.4

The first patch is a bit ugly, but it fixes a bug that could affect lockdep. That bug is very minor and may not be observable at all, but I don't really want to bet on it.

The other three are intended to fix a performance regression in the entry rework that Frédéric objected to. They're much later than I'd like to have sent them for 4.4, but they're kind-of sort-of regression fixes, so maybe they're still okay. They would certainly need careful review, though.

I don't have a great benchmark for them. The biggest impact is likely to be to user page fault latency on CONFIG_CONTEXT_TRACKING=y kernels (i.e. distro kernels) that don't use context tracking (i.e. most users).

Changes from v3: Actually send entire series (patch 1 was missing)

Changes from v1:
- CALL_ENTER_FROM_USER_MODE is now CALL_enter_from_user_mode (Ingo)
- STATIC_JUMP_IF_{TRUE,FALSE} now cannot be (mis-)used on non-jump-label kernels (Thomas)
- Comments are better (Borislav)

This doesn't really address Thomas' objections to the HAVE_JUMP_LABEL stuff, but it's more robust now, and maybe that's good enough.

Andy Lutomirski (5):
x86/entry/64: Fix irqflag tracing wrt context tracking
context_tracking: Switch to new static_branch API x86/asm: Error out if asm/jump_label.h is included inappropriately x86/asm: Add asm macros for static keys/jump labels x86/entry/64: Bypass enter_from_user_mode on non-context-tracking
boots

 arch/x86/entry/calling.h               | 15 ++++++++
 arch/x86/entry/entry_64.S              | 27 +++++++++++----
 arch/x86/include/asm/jump_label.h      | 63 ++++++++++++++++++++++++++++++----
 include/linux/context_tracking_state.h |  4 +--
 kernel/context_tracking.c              |  4 +--
 5 files changed, 95 insertions(+), 18 deletions(-)
Signature · 1 line
2.5.0