ACPICA: Tables: Fix "UNLOAD" code path lock issues
ACPICA commit 39227380f5b99c51b897a3ffedd88508aa26789b The previous lock fixes didn't cover "Unload" opcode and table unload APIs, this patch fixes lock issues in the "Unload" code path. BZ 1325, Lv Zheng. Link: https://github.com/acpica/acpica/commit/39227380 Link: https://bugs.acpica.org/show_bug.cgi?id=1325 Signed-off-by: Lv Zheng <lv.zheng@intel.com> Signed-off-by: Bob Moore <robert.moore@intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Šī revīzija ir iekļauta:

revīziju iesūtīja
Rafael J. Wysocki

vecāks
86ec64bc38
revīzija
9febcdc071
@@ -378,9 +378,9 @@ acpi_status acpi_unload_parent_table(acpi_handle object)
|
||||
return_ACPI_STATUS(AE_TYPE);
|
||||
}
|
||||
|
||||
/* Must acquire the interpreter lock during this operation */
|
||||
/* Must acquire the table lock during this operation */
|
||||
|
||||
status = acpi_ut_acquire_mutex(ACPI_MTX_INTERPRETER);
|
||||
status = acpi_ut_acquire_mutex(ACPI_MTX_TABLES);
|
||||
if (ACPI_FAILURE(status)) {
|
||||
return_ACPI_STATUS(status);
|
||||
}
|
||||
@@ -407,8 +407,10 @@ acpi_status acpi_unload_parent_table(acpi_handle object)
|
||||
|
||||
/* Ensure the table is actually loaded */
|
||||
|
||||
(void)acpi_ut_release_mutex(ACPI_MTX_TABLES);
|
||||
if (!acpi_tb_is_table_loaded(i)) {
|
||||
status = AE_NOT_EXIST;
|
||||
(void)acpi_ut_acquire_mutex(ACPI_MTX_TABLES);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -434,10 +436,11 @@ acpi_status acpi_unload_parent_table(acpi_handle object)
|
||||
|
||||
status = acpi_tb_release_owner_id(i);
|
||||
acpi_tb_set_table_loaded_flag(i, FALSE);
|
||||
(void)acpi_ut_acquire_mutex(ACPI_MTX_TABLES);
|
||||
break;
|
||||
}
|
||||
|
||||
(void)acpi_ut_release_mutex(ACPI_MTX_INTERPRETER);
|
||||
(void)acpi_ut_release_mutex(ACPI_MTX_TABLES);
|
||||
return_ACPI_STATUS(status);
|
||||
}
|
||||
|
||||
|
Atsaukties uz šo jaunā problēmā
Block a user