--- a/sys/vfs/procfs/procfs_vnops.c 2026-09-06 02:38:07.817579579 +0000 +++ b/sys/vfs/procfs/procfs_vnops.c 2026-09-06 02:38:07.817579579 +0000 @@ -796,7 +796,8 @@ } pid = atopid(pname, cnp->cn_namelen); - if (pid == NO_PID) + /* pid 0 is the kernel-internal swapper: never addressable */ + if (pid == NO_PID || pid == 0) break; p = pfs_pfind(pid); @@ -1064,6 +1065,8 @@ break; default: + if (p->p_pid == 0) /* skip kernel-internal proc0 */ + return(0); if (!PRISON_CHECK(info->cred, p->p_ucred)) return(0); if (ps_showallprocs == 0 &&