From d27837759a4f890c613f0cb4902ed3ac37f1c604 Mon Sep 17 00:00:00 2001 From: Matthew Dillon Date: Fri, 2 Jul 2010 19:07:14 -0700 Subject: [PATCH] kernel - hold MP lock in idlezero for now * The MP lock must be held in the idlezero code for now until tokenization is finished on the rest of the code base. * Fixes random memory corruption which could occur when idlezero was turned on. --- sys/vm/vm_zeroidle.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/vm/vm_zeroidle.c b/sys/vm/vm_zeroidle.c index 7c0587641c..3d46c3190f 100644 --- a/sys/vm/vm_zeroidle.c +++ b/sys/vm/vm_zeroidle.c @@ -159,8 +159,11 @@ vm_pagezero(void __unused *arg) * priority. * * Also put us on the last cpu for now. + * + * For now leave the MP lock held, the VM routines cannot be called + * with it released until tokenization is finished. */ - rel_mplock(); + /* rel_mplock(); */ lwkt_setpri_self(TDPRI_IDLE_WORK); lwkt_setcpu_self(globaldata_find(ncpus - 1)); sleep_time = DEFAULT_SLEEP_TIME; -- 2.41.0