diff options
Diffstat (limited to 'drivers/acpi/acpica/utinit.c')
| -rw-r--r-- | drivers/acpi/acpica/utinit.c | 37 |
1 files changed, 32 insertions, 5 deletions
diff --git a/drivers/acpi/acpica/utinit.c b/drivers/acpi/acpica/utinit.c index 8359c0c5dc98..246798e4c938 100644 --- a/drivers/acpi/acpica/utinit.c +++ b/drivers/acpi/acpica/utinit.c | |||
| @@ -53,27 +53,35 @@ ACPI_MODULE_NAME("utinit") | |||
| 53 | /* Local prototypes */ | 53 | /* Local prototypes */ |
| 54 | static void acpi_ut_terminate(void); | 54 | static void acpi_ut_terminate(void); |
| 55 | 55 | ||
| 56 | #if (!ACPI_REDUCED_HARDWARE) | ||
| 57 | |||
| 58 | static void acpi_ut_free_gpe_lists(void); | ||
| 59 | |||
| 60 | #else | ||
| 61 | |||
| 62 | #define acpi_ut_free_gpe_lists() | ||
| 63 | #endif /* !ACPI_REDUCED_HARDWARE */ | ||
| 64 | |||
| 65 | #if (!ACPI_REDUCED_HARDWARE) | ||
| 56 | /****************************************************************************** | 66 | /****************************************************************************** |
| 57 | * | 67 | * |
| 58 | * FUNCTION: acpi_ut_terminate | 68 | * FUNCTION: acpi_ut_free_gpe_lists |
| 59 | * | 69 | * |
| 60 | * PARAMETERS: none | 70 | * PARAMETERS: none |
| 61 | * | 71 | * |
| 62 | * RETURN: none | 72 | * RETURN: none |
| 63 | * | 73 | * |
| 64 | * DESCRIPTION: Free global memory | 74 | * DESCRIPTION: Free global GPE lists |
| 65 | * | 75 | * |
| 66 | ******************************************************************************/ | 76 | ******************************************************************************/ |
| 67 | 77 | ||
| 68 | static void acpi_ut_terminate(void) | 78 | static void acpi_ut_free_gpe_lists(void) |
| 69 | { | 79 | { |
| 70 | struct acpi_gpe_block_info *gpe_block; | 80 | struct acpi_gpe_block_info *gpe_block; |
| 71 | struct acpi_gpe_block_info *next_gpe_block; | 81 | struct acpi_gpe_block_info *next_gpe_block; |
| 72 | struct acpi_gpe_xrupt_info *gpe_xrupt_info; | 82 | struct acpi_gpe_xrupt_info *gpe_xrupt_info; |
| 73 | struct acpi_gpe_xrupt_info *next_gpe_xrupt_info; | 83 | struct acpi_gpe_xrupt_info *next_gpe_xrupt_info; |
| 74 | 84 | ||
| 75 | ACPI_FUNCTION_TRACE(ut_terminate); | ||
| 76 | |||
| 77 | /* Free global GPE blocks and related info structures */ | 85 | /* Free global GPE blocks and related info structures */ |
| 78 | 86 | ||
| 79 | gpe_xrupt_info = acpi_gbl_gpe_xrupt_list_head; | 87 | gpe_xrupt_info = acpi_gbl_gpe_xrupt_list_head; |
| @@ -91,7 +99,26 @@ static void acpi_ut_terminate(void) | |||
| 91 | ACPI_FREE(gpe_xrupt_info); | 99 | ACPI_FREE(gpe_xrupt_info); |
| 92 | gpe_xrupt_info = next_gpe_xrupt_info; | 100 | gpe_xrupt_info = next_gpe_xrupt_info; |
| 93 | } | 101 | } |
| 102 | } | ||
| 103 | #endif /* !ACPI_REDUCED_HARDWARE */ | ||
| 104 | |||
| 105 | /****************************************************************************** | ||
| 106 | * | ||
| 107 | * FUNCTION: acpi_ut_terminate | ||
| 108 | * | ||
| 109 | * PARAMETERS: none | ||
| 110 | * | ||
| 111 | * RETURN: none | ||
| 112 | * | ||
| 113 | * DESCRIPTION: Free global memory | ||
| 114 | * | ||
| 115 | ******************************************************************************/ | ||
| 116 | |||
| 117 | static void acpi_ut_terminate(void) | ||
| 118 | { | ||
| 119 | ACPI_FUNCTION_TRACE(ut_terminate); | ||
| 94 | 120 | ||
| 121 | acpi_ut_free_gpe_lists(); | ||
| 95 | acpi_ut_delete_address_lists(); | 122 | acpi_ut_delete_address_lists(); |
| 96 | return_VOID; | 123 | return_VOID; |
| 97 | } | 124 | } |
