Re: [PATCH v10 00/15] x86: Enable Linear Address Space Separation support

Edgecombe, Rick P
2025-10-07T16:23:52Z

On Mon, 2025-10-06 at 23:51 -0700, Sohil Mehta wrote:
> > Userspace accesses
> > ------------------
> > Userspace attempts to access any kernel address generate a #GP when LASS
> > is enabled. Unfortunately, legacy vsyscall functions are located in the
> > address range 0xffffffffff600000 - 0xffffffffff601000. Prior to LASS,
> > default access (XONLY) to the vsyscall page would generate a page fault
> > and the access would be emulated in the kernel. To avoid breaking user
> > applications when LASS is enabled, the patches extend vsyscall emulation
> > in XONLY mode to the #GP handler.
> >
> > In contrast, the vsyscall EMULATE mode is deprecated and not expected to
> > be used by anyone. Supporting EMULATE mode with LASS would require
> > complex instruction decoding in the #GP fault handler, which is probably
> > not worth the effort. For now, LASS is disabled in the rare case when
> > someone absolutely needs to enable vsyscall=emulate via the command
> > line.

There is also an expected harmless UABI change around SIG_SEGV. For a user mode
kernel address range access, the kernel can deliver a signal that provides the
exception type and the address. Before it was #PF, now a #GP with no address.