http://defect.opensolaris.org/bz/show_bug.cgi?id=4817


Bill Holler <bill.holler at sun.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |CAUSEKNOWN




--- Comment #1 from Bill Holler <bill.holler at sun.com>  2008-11-11 14:00:33 
---
Here is a possible fix:

diff -r c6a3cd4afc8e usr/src/uts/i86pc/io/hpet_acpi.c
--- a/usr/src/uts/i86pc/io/hpet_acpi.c  Mon Nov 10 17:58:15 2008 -0800
+++ b/usr/src/uts/i86pc/io/hpet_acpi.c  Tue Nov 11 14:01:52 2008 -0800
@@ -1041,9 +1041,17 @@
                 * in case the non-deep-c disp_enq_thread function will not
                 * work with CPUs in deep C-State.
                 */
-               mutex_enter(&hpet_proxy_lock);
+               cli();
+               while (!mutex_tryenter(&hpet_proxy_lock)) {
+                       /*
+                        * spin
+                        */
+                       sti();
+                       cli();
+               }
                hpet_expire_all();
                mutex_exit(&hpet_proxy_lock);
+               sti();

                /*
                 * Disable timer interrupt generation.
@@ -1171,9 +1179,17 @@
                 * Wakeup all CPUs currently using the HPET as an LAPIC proxy
                 * before disabling the interrupt.
                 */
-               mutex_enter(&hpet_proxy_lock);
+               cli();
+               while (!mutex_tryenter(&hpet_proxy_lock)) {
+                       /*
+                        * spin
+                        */
+                       sti();
+                       cli();
+               }
                hpet_expire_all();
                mutex_exit(&hpet_proxy_lock);
+               sti();

                hpet_disable_timer(&hpet_info, hpet_info.cstate_timer.timer);
                hpet_info.disable_cpu_deep_idle++;

-- 
Configure bugmail: http://defect.opensolaris.org/bz/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Reply via email to