From 28bb8c6ff7b82b8216dfa6bfb052f1d169959062 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?George=20Bi=C8=99oc?= Date: Sat, 14 Dec 2024 21:52:24 +0100 Subject: [PATCH] [COMPBATT] Assign a memory allocation tag for the I/O remove lock IoInitializeRemoveLock expects an allocation tag to be provided when it allocates debug data in the kernel. Passing 0 leads to a bunch of ASSERTs in the kernel as such data is allocated by ExAllocatePoolWithTag of which a tag has to be supplied, it's not optional. --- drivers/bus/acpi/compbatt/comppnp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bus/acpi/compbatt/comppnp.c b/drivers/bus/acpi/compbatt/comppnp.c index 7e8523537ae..31b05030b4f 100644 --- a/drivers/bus/acpi/compbatt/comppnp.c +++ b/drivers/bus/acpi/compbatt/comppnp.c @@ -177,7 +177,7 @@ CompBattAddNewBattery( ExReleaseFastMutex(&DeviceExtension->Lock); /* Initialize the work item and delete lock */ - IoInitializeRemoveLock(&BatteryData->RemoveLock, 0, 0, 0); + IoInitializeRemoveLock(&BatteryData->RemoveLock, COMPBATT_TAG, 0, 0); ExInitializeWorkItem(&BatteryData->WorkItem, (PVOID)CompBattMonitorIrpCompleteWorker, BatteryData);