kernel - hold MP lock in idlezero for now
authorMatthew Dillon <dillon@apollo.backplane.com>
Sat, 3 Jul 2010 02:07:14 +0000 (19:07 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 3 Jul 2010 02:07:14 +0000 (19:07 -0700)
* 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

index 7c05876..3d46c31 100644 (file)
@@ -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;