From e54de546184b1acd6e6820cf2789ab6dfa25439d Mon Sep 17 00:00:00 2001 From: Filip Navara Date: Sat, 19 Mar 2005 02:18:49 +0000 Subject: [PATCH] - Fix acpi_os_get_thread_id to return 1-based thread ids (instead of zero-based ones). - Zero the owner_id field while initializing acpi_gbl_acpi_mutex_info. svn path=/trunk/; revision=14186 --- reactos/drivers/bus/acpi/ospm/osl.c | 2 +- reactos/drivers/bus/acpi/utils/cmglobal.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/reactos/drivers/bus/acpi/ospm/osl.c b/reactos/drivers/bus/acpi/ospm/osl.c index 741f0714c91..ed11cd6d630 100644 --- a/reactos/drivers/bus/acpi/ospm/osl.c +++ b/reactos/drivers/bus/acpi/ospm/osl.c @@ -601,5 +601,5 @@ acpi_os_writable(void *ptr, u32 len) u32 acpi_os_get_thread_id (void) { - return (ULONG)PsGetCurrentThreadId(); + return (ULONG)PsGetCurrentThreadId() + 1; } diff --git a/reactos/drivers/bus/acpi/utils/cmglobal.c b/reactos/drivers/bus/acpi/utils/cmglobal.c index 121bcda9a8f..c2d1237fef5 100644 --- a/reactos/drivers/bus/acpi/utils/cmglobal.c +++ b/reactos/drivers/bus/acpi/utils/cmglobal.c @@ -389,6 +389,7 @@ acpi_cm_init_globals ( acpi_gbl_acpi_mutex_info[i].mutex = NULL; acpi_gbl_acpi_mutex_info[i].locked = FALSE; acpi_gbl_acpi_mutex_info[i].use_count = 0; + acpi_gbl_acpi_mutex_info[i].owner_id = 0; } /* Global notify handlers */