36 #if defined(ALLOC_PRAGMA) 37 #pragma alloc_text(INIT, HotplugCallbackInitialization) 38 #pragma alloc_text(PAGE, HotplugCallbackTermination) 39 #pragma alloc_text(PAGE, HotplugCallbackpCallbackRoutine) 58 auto callback_handle = KeRegisterProcessorChangeCallback(
60 if (!callback_handle) {
61 return STATUS_UNSUCCESSFUL;
65 return STATUS_SUCCESS;
78 PVOID callback_context, PKE_PROCESSOR_CHANGE_NOTIFY_CONTEXT change_context,
79 PNTSTATUS operation_status) {
81 UNREFERENCED_PARAMETER(callback_context);
82 UNREFERENCED_PARAMETER(operation_status);
84 if (change_context->State != KeProcessorAddCompleteNotify) {
89 change_context->ProcNumber.Group,
90 change_context->ProcNumber.Number);
94 if (!NT_SUCCESS(status)) {
static PVOID g_hpp_callback_handle
#define HYPERPLATFORM_LOG_DEBUG(format,...)
Logs a message as respective severity.
#define HYPERPLATFORM_COMMON_DBG_BREAK()
Sets a break point that works only when a debugger is present.
NTSTATUS HotplugCallbackInitialization()
void HotplugCallbackTermination()
Declares interfaces to hot-plug functions.
NTSTATUS VmHotplugCallback(const PROCESSOR_NUMBER &proc_num)
Virtualizes the specified processor.
Declares and implements common things across the project.
Declares interfaces to VMM initialization functions.
#define HYPERPLATFORM_LOG_ERROR(format,...)
Declares interfaces to logging functions.
static PROCESSOR_CALLBACK_FUNCTION HotplugCallbackpCallbackRoutine