HomeFreeBSD

amd64: Clear the local TSS when creating a new thread

Description

amd64: Clear the local TSS when creating a new thread

Otherwise it is copied from the creating thread. Then, if either thread
exits, the other is left with a dangling pointer, typically resulting in
a page fault upon the next context switch.

Reported by: syzkaller
Reviewed by: kib
Sponsored by: The FreeBSD Foundation

(cherry picked from commit 8cd05b883330049d536a40e2f4c9ff92d0e6944e)

Details

Provenance
markjAuthored on Jun 1 2021, 11:38 PM
Parents
rG949fb4f9627b: i386: Make setidt_disp a size_t instead of uintptr_t
Branches
Unknown
Tags
Unknown