Page MenuHomeFreeBSD

Set TDP_KTHREAD before calling cpu_fork() and cpu_copy_thread().
ClosedPublic

Authored by jhb on Mar 10 2021, 10:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Oct 17 2024, 10:34 PM
Unknown Object (File)
Sep 30 2024, 8:08 PM
Unknown Object (File)
Sep 30 2024, 8:08 PM
Unknown Object (File)
Sep 30 2024, 8:08 PM
Unknown Object (File)
Sep 30 2024, 8:08 PM
Unknown Object (File)
Sep 22 2024, 2:42 AM
Unknown Object (File)
Sep 18 2024, 9:55 AM
Unknown Object (File)
Sep 17 2024, 10:53 PM
Subscribers

Details

Summary

This permits these routines to use special logic for initializing MD
kthread state.

For the kproc case, this required moving the logic to set these flags
from kproc_create() into do_fork().

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

sys/kern/kern_fork.c
509

Note that code for DROPSIG_CAUGHT above is accurate to lock p2 ps_mtx around p_sigacts manipulations (even if only for asserts). I think it is better to be consistent both by style and formal requirements and lock ps_mtx if (FR2_DROPSIG_CAUGHT | FR2_KPROC).

jhb marked an inline comment as done.Mar 11 2021, 10:36 PM
This revision is now accepted and ready to land.Mar 12 2021, 12:46 PM