diff options
Diffstat (limited to 'drivers/acpi/events')
-rw-r--r-- | drivers/acpi/events/evgpe.c | 5 | ||||
-rw-r--r-- | drivers/acpi/events/evgpeblk.c | 27 | ||||
-rw-r--r-- | drivers/acpi/events/evmisc.c | 4 | ||||
-rw-r--r-- | drivers/acpi/events/evxface.c | 10 |
4 files changed, 26 insertions, 20 deletions
diff --git a/drivers/acpi/events/evgpe.c b/drivers/acpi/events/evgpe.c index 081120b109b..ede834df4f6 100644 --- a/drivers/acpi/events/evgpe.c +++ b/drivers/acpi/events/evgpe.c @@ -396,6 +396,7 @@ acpi_ev_gpe_detect ( struct acpi_gpe_register_info *gpe_register_info; u32 status_reg; u32 enable_reg; + u32 flags; acpi_status status; struct acpi_gpe_block_info *gpe_block; acpi_native_uint i; @@ -412,7 +413,7 @@ acpi_ev_gpe_detect ( /* Examine all GPE blocks attached to this interrupt level */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); gpe_block = gpe_xrupt_list->gpe_block_list_head; while (gpe_block) { /* @@ -476,7 +477,7 @@ acpi_ev_gpe_detect ( unlock_and_exit: - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); return (int_status); } diff --git a/drivers/acpi/events/evgpeblk.c b/drivers/acpi/events/evgpeblk.c index ee5419b8f1b..dfc54692b12 100644 --- a/drivers/acpi/events/evgpeblk.c +++ b/drivers/acpi/events/evgpeblk.c @@ -138,7 +138,6 @@ acpi_ev_valid_gpe_event ( * FUNCTION: acpi_ev_walk_gpe_list * * PARAMETERS: gpe_walk_callback - Routine called for each GPE block - * Flags - ACPI_NOT_ISR or ACPI_ISR * * RETURN: Status * @@ -148,18 +147,18 @@ acpi_ev_valid_gpe_event ( acpi_status acpi_ev_walk_gpe_list ( - ACPI_GPE_CALLBACK gpe_walk_callback, - u32 flags) + ACPI_GPE_CALLBACK gpe_walk_callback) { struct acpi_gpe_block_info *gpe_block; struct acpi_gpe_xrupt_info *gpe_xrupt_info; acpi_status status = AE_OK; + u32 flags; ACPI_FUNCTION_TRACE ("ev_walk_gpe_list"); - acpi_os_acquire_lock (acpi_gbl_gpe_lock, flags); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); /* Walk the interrupt level descriptor list */ @@ -500,6 +499,7 @@ acpi_ev_get_gpe_xrupt_block ( struct acpi_gpe_xrupt_info *next_gpe_xrupt; struct acpi_gpe_xrupt_info *gpe_xrupt; acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("ev_get_gpe_xrupt_block"); @@ -527,7 +527,7 @@ acpi_ev_get_gpe_xrupt_block ( /* Install new interrupt descriptor with spin lock */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); if (acpi_gbl_gpe_xrupt_list_head) { next_gpe_xrupt = acpi_gbl_gpe_xrupt_list_head; while (next_gpe_xrupt->next) { @@ -540,7 +540,7 @@ acpi_ev_get_gpe_xrupt_block ( else { acpi_gbl_gpe_xrupt_list_head = gpe_xrupt; } - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); /* Install new interrupt handler if not SCI_INT */ @@ -577,6 +577,7 @@ acpi_ev_delete_gpe_xrupt ( struct acpi_gpe_xrupt_info *gpe_xrupt) { acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("ev_delete_gpe_xrupt"); @@ -599,7 +600,7 @@ acpi_ev_delete_gpe_xrupt ( /* Unlink the interrupt block with lock */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); if (gpe_xrupt->previous) { gpe_xrupt->previous->next = gpe_xrupt->next; } @@ -607,7 +608,7 @@ acpi_ev_delete_gpe_xrupt ( if (gpe_xrupt->next) { gpe_xrupt->next->previous = gpe_xrupt->previous; } - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); /* Free the block */ @@ -637,6 +638,7 @@ acpi_ev_install_gpe_block ( struct acpi_gpe_block_info *next_gpe_block; struct acpi_gpe_xrupt_info *gpe_xrupt_block; acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("ev_install_gpe_block"); @@ -655,7 +657,7 @@ acpi_ev_install_gpe_block ( /* Install the new block at the end of the list with lock */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); if (gpe_xrupt_block->gpe_block_list_head) { next_gpe_block = gpe_xrupt_block->gpe_block_list_head; while (next_gpe_block->next) { @@ -670,7 +672,7 @@ acpi_ev_install_gpe_block ( } gpe_block->xrupt_block = gpe_xrupt_block; - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); unlock_and_exit: status = acpi_ut_release_mutex (ACPI_MTX_EVENTS); @@ -695,6 +697,7 @@ acpi_ev_delete_gpe_block ( struct acpi_gpe_block_info *gpe_block) { acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("ev_install_gpe_block"); @@ -720,7 +723,7 @@ acpi_ev_delete_gpe_block ( else { /* Remove the block on this interrupt with lock */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); if (gpe_block->previous) { gpe_block->previous->next = gpe_block->next; } @@ -731,7 +734,7 @@ acpi_ev_delete_gpe_block ( if (gpe_block->next) { gpe_block->next->previous = gpe_block->previous; } - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); } /* Free the gpe_block */ diff --git a/drivers/acpi/events/evmisc.c b/drivers/acpi/events/evmisc.c index 659e9095611..38d7ab8aef3 100644 --- a/drivers/acpi/events/evmisc.c +++ b/drivers/acpi/events/evmisc.c @@ -589,7 +589,7 @@ acpi_ev_terminate ( /* Disable all GPEs in all GPE blocks */ - status = acpi_ev_walk_gpe_list (acpi_hw_disable_gpe_block, ACPI_NOT_ISR); + status = acpi_ev_walk_gpe_list (acpi_hw_disable_gpe_block); /* Remove SCI handler */ @@ -602,7 +602,7 @@ acpi_ev_terminate ( /* Deallocate all handler objects installed within GPE info structs */ - status = acpi_ev_walk_gpe_list (acpi_ev_delete_gpe_handlers, ACPI_NOT_ISR); + status = acpi_ev_walk_gpe_list (acpi_ev_delete_gpe_handlers); /* Return to original mode if necessary */ diff --git a/drivers/acpi/events/evxface.c b/drivers/acpi/events/evxface.c index 4092d47f675..4c1c25e316a 100644 --- a/drivers/acpi/events/evxface.c +++ b/drivers/acpi/events/evxface.c @@ -591,6 +591,7 @@ acpi_install_gpe_handler ( struct acpi_gpe_event_info *gpe_event_info; struct acpi_handler_info *handler; acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("acpi_install_gpe_handler"); @@ -643,7 +644,7 @@ acpi_install_gpe_handler ( /* Install the handler */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); gpe_event_info->dispatch.handler = handler; /* Setup up dispatch flags to indicate handler (vs. method) */ @@ -651,7 +652,7 @@ acpi_install_gpe_handler ( gpe_event_info->flags &= ~(ACPI_GPE_XRUPT_TYPE_MASK | ACPI_GPE_DISPATCH_MASK); /* Clear bits */ gpe_event_info->flags |= (u8) (type | ACPI_GPE_DISPATCH_HANDLER); - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); unlock_and_exit: @@ -685,6 +686,7 @@ acpi_remove_gpe_handler ( struct acpi_gpe_event_info *gpe_event_info; struct acpi_handler_info *handler; acpi_status status; + u32 flags; ACPI_FUNCTION_TRACE ("acpi_remove_gpe_handler"); @@ -741,7 +743,7 @@ acpi_remove_gpe_handler ( /* Remove the handler */ - acpi_os_acquire_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + flags = acpi_os_acquire_lock (acpi_gbl_gpe_lock); handler = gpe_event_info->dispatch.handler; /* Restore Method node (if any), set dispatch flags */ @@ -751,7 +753,7 @@ acpi_remove_gpe_handler ( if (handler->method_node) { gpe_event_info->flags |= ACPI_GPE_DISPATCH_METHOD; } - acpi_os_release_lock (acpi_gbl_gpe_lock, ACPI_NOT_ISR); + acpi_os_release_lock (acpi_gbl_gpe_lock, flags); /* Now we can free the handler object */ |