diff options
Diffstat (limited to 'drivers/acpi/acpica/evgpeblk.c')
-rw-r--r-- | drivers/acpi/acpica/evgpeblk.c | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/drivers/acpi/acpica/evgpeblk.c b/drivers/acpi/acpica/evgpeblk.c index 7c28f2d9fd35..341a38ce8aa6 100644 --- a/drivers/acpi/acpica/evgpeblk.c +++ b/drivers/acpi/acpica/evgpeblk.c | |||
@@ -500,6 +500,19 @@ acpi_ev_initialize_gpe_block(struct acpi_namespace_node *gpe_device, | |||
500 | 500 | ||
501 | gpe_index = (i * ACPI_GPE_REGISTER_WIDTH) + j; | 501 | gpe_index = (i * ACPI_GPE_REGISTER_WIDTH) + j; |
502 | gpe_event_info = &gpe_block->event_info[gpe_index]; | 502 | gpe_event_info = &gpe_block->event_info[gpe_index]; |
503 | gpe_number = gpe_index + gpe_block->block_base_number; | ||
504 | |||
505 | /* | ||
506 | * If the GPE has already been enabled for runtime | ||
507 | * signaling, make sure it remains enabled, but do not | ||
508 | * increment its reference counter. | ||
509 | */ | ||
510 | if (gpe_event_info->runtime_count) { | ||
511 | acpi_set_gpe(gpe_device, gpe_number, | ||
512 | ACPI_GPE_ENABLE); | ||
513 | gpe_enabled_count++; | ||
514 | continue; | ||
515 | } | ||
503 | 516 | ||
504 | if (gpe_event_info->flags & ACPI_GPE_CAN_WAKE) { | 517 | if (gpe_event_info->flags & ACPI_GPE_CAN_WAKE) { |
505 | wake_gpe_count++; | 518 | wake_gpe_count++; |
@@ -516,7 +529,6 @@ acpi_ev_initialize_gpe_block(struct acpi_namespace_node *gpe_device, | |||
516 | 529 | ||
517 | /* Enable this GPE */ | 530 | /* Enable this GPE */ |
518 | 531 | ||
519 | gpe_number = gpe_index + gpe_block->block_base_number; | ||
520 | status = acpi_enable_gpe(gpe_device, gpe_number, | 532 | status = acpi_enable_gpe(gpe_device, gpe_number, |
521 | ACPI_GPE_TYPE_RUNTIME); | 533 | ACPI_GPE_TYPE_RUNTIME); |
522 | if (ACPI_FAILURE(status)) { | 534 | if (ACPI_FAILURE(status)) { |