summaryrefslogtreecommitdiff
path: root/drivers/acpi/acpica/exmutex.c
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2009-12-15 22:27:39 -0500
committerLen Brown <len.brown@intel.com>2009-12-15 22:27:39 -0500
commit173cc11a6e10c38ff7d4949b48e8d2eb0aee3e05 (patch)
tree44ac9a6fe4e9c51b2c54918aa338df7eda96b0a5 /drivers/acpi/acpica/exmutex.c
parent8bea8672edfca7ec5f661cafb218f1205863b343 (diff)
parent88e5071525ad6814be3a8a2792ce9e81a0cca22a (diff)
Merge branch 'acpica' into release
Diffstat (limited to 'drivers/acpi/acpica/exmutex.c')
-rw-r--r--drivers/acpi/acpica/exmutex.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/acpi/acpica/exmutex.c b/drivers/acpi/acpica/exmutex.c
index 2f0114202b05..3c456bd575d0 100644
--- a/drivers/acpi/acpica/exmutex.c
+++ b/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