CVSROOT:        /cvs
Module name:    src
Changes by:     chel...@cvs.openbsd.org 2023/09/08 21:03:45

Modified files:
        sys/kern       : kern_clockintr.c 

Log message:
clockintr_dispatch: copy cl_func to cq_shadow.cl_func before calling it

When we add support for disestablishing clockintrs in the near future,
the current call to cl->cl_func will be in a race with free(9) on
another CPU.  Copying cl_func to cq_shadow.cl_func before leaving the
mutex and then calling the copy eliminates the race.

Correcting the race has a negligible performance impact and simplifies
the forthcoming clockintr_disestablish() patch.

Requested by dlg@ back in March.

Reply via email to