Skip to content

fix sysenter for 32-on-64 processes

Jeremy Fitzhardinge lkml 1 version Applied

Status from this message: applied to tip/x86/urgent, thanks Jeremy.

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 4 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/2x86: call early_cpu_init at the same pointarch/x86/kernel/setup.c+0 -03 replies
2/2xen: don't use sysret for sysexit32arch/x86/xen/xen-asm_64.S+0 -01 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] fix sysenter for 32-on-64 processes

Hi Ingo,

Here's a little two-part patch series which fixes 32-on-64 syscalls using sysenter.

The first is a difference in ordering in arch_setup(); the 64-bit code was calling early_init_cpu() way too late. Moving it earlier, to the same place as the 32-bit code, works for me, but I wonder if it might cause problems with other configurations. Certainly it makes logical sense that both architectures do the same cpu setup at the same place.

The other fix is an outright Xen-specific bug, which resulted in usermode registers being trashed as a result of an over-enthusiastic use of sysret.

Both patches are .27 material, but I expect the arch_setup() change needs to cooking before being comfortable with it.

Thanks,
J