From 00205144d870d387e2de045e4a6ca76a2a1ce77d Mon Sep 17 00:00:00 2001 From: Dan Carpenter Date: Fri, 11 Dec 2009 15:31:40 +0800 Subject: [PATCH] --- yaml --- r: 177487 b: refs/heads/master c: fbc3be2af3e8beb581a20c2a0cfda5692f5a1c08 h: refs/heads/master i: 177485: 784f8ce6629914e75b60401e68c403a3fe8d4a31 177483: 1a7c07c2ae743772bce2088b118ba1852596e5c8 177479: 6c692815e088cf087045902320fe5079a85ed528 177471: 92b73fdb3d8cf1583c65362d7863a996e3b1742f v: v3 --- [refs] | 2 +- trunk/drivers/acpi/acpica/exmutex.c | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/[refs] b/[refs] index 94ed4132d3d7..3d4dcd00aac5 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d4085a3ffee8828f7f1bae7fa3cf5e58f59ba627 +refs/heads/master: fbc3be2af3e8beb581a20c2a0cfda5692f5a1c08 diff --git a/trunk/drivers/acpi/acpica/exmutex.c b/trunk/drivers/acpi/acpica/exmutex.c index 2f0114202b05..3c456bd575d0 100644 --- a/trunk/drivers/acpi/acpica/exmutex.c +++ b/trunk/drivers/acpi/acpica/exmutex.c @@ -375,6 +375,15 @@ acpi_ex_release_mutex(union acpi_operand_object *obj_desc, return_ACPI_STATUS(AE_AML_MUTEX_NOT_ACQUIRED); } + /* Must have a valid thread ID */ + + if (!walk_state->thread) { + ACPI_ERROR((AE_INFO, + "Cannot release Mutex [%4.4s], null thread info", + acpi_ut_get_node_name(obj_desc->mutex.node))); + return_ACPI_STATUS(AE_AML_INTERNAL); + } + /* * The Mutex is owned, but this thread must be the owner. * Special case for Global Lock, any thread can release @@ -392,15 +401,6 @@ acpi_ex_release_mutex(union acpi_operand_object *obj_desc, return_ACPI_STATUS(AE_AML_NOT_OWNER); } - /* Must have a valid thread ID */ - - if (!walk_state->thread) { - ACPI_ERROR((AE_INFO, - "Cannot release Mutex [%4.4s], null thread info", - acpi_ut_get_node_name(obj_desc->mutex.node))); - return_ACPI_STATUS(AE_AML_INTERNAL); - } - /* * The sync level of the mutex must be equal to the current sync level. In * other words, the current level means that at least one mutex at that