HomeFreeBSD

Use the known valid segment when accessing memory in #UD handler.

Description

Use the known valid segment when accessing memory in #UD handler.
Make sure that %eflags.D flag is cleared for hook.
Improve comments.

When #UD dtrace code checks for a registered hook before checking that
the exception was raised from kernel mode, we might run with the user
%ds, trapping on access. Exception entry from userspace automatically
load valid %ss, which we can use there instead.

Noted and reviewed by: bde
Sponsored by: The FreeBSD Foundation
MFC after: 3 days

Details

Provenance
kibAuthored on
Parents
rS322705: Use better hard-coded defaults for the cursor shape, and remove nearby
Branches
Unknown
Tags
Unknown