Skip to contentSkip to conversation

cpu: implement CPEJ method for unpluging cpu

RFC PATCH New Chen Fan 1 participant 1 message Aug 29, 2013

lore
Share & tools
lore

Chen Fan

author
#0 lore raw

RFC PATCH 1/1 cpu: implement CPEJ method for unpluging cpu

After OS ejecting a vcpu successful, it will call CPEJ method, there communicate the masked vcpu bitmap to QEMU.

---
 src/acpi-dsdt-cpu-hotplug.dsl | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
src/acpi-dsdt-cpu-hotplug.dsl +5 -1
index 0f3e83b..b25963c 100644
@@ -34,7 +34,11 @@ Scope(\_SB) {
     }
     Method(CPEJ, 2, NotSerialized) {
         // _EJ0 method - eject callback
-        Sleep(200)
+        Store(Zero, Index(CPON, ToInteger(Arg0)))
+        Store(One, Local0)
+        ShiftLeft(Local0, Arg0, Local0)
+        Not(Local0, Local0)
+        And(PRS, Local0, PRS)
     }
 
     /* CPU hotplug notify method */
Signature · 1 line
1.8.1.4