Module Name: src Committed By: riastradh Date: Fri Apr 14 16:51:46 UTC 2023
Modified Files: src/sys/kern: subr_pserialize.c Log Message: pserialize(9): Fix bug in recent micro-optimization. curcpu() is always a valid struct cpu_info pointer, but curlwp->l_cpu is not necessarily -- early at boot on some architectures (like x86, apparently) it may be null. Not clear that l->l_cpu is always a cost win over curcpu(): on some architectures curcpu() is basically a macro for curlwp->l_cpu, while on others it is a fixed VA. So let's use the one that always works instead of the one that's sometimes cheaper and sometimes crashier. To generate a diff of this commit: cvs rdiff -u -r1.21 -r1.22 src/sys/kern/subr_pserialize.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.