diff options
author | Alex Chiang <achiang@hp.com> | 2009-12-20 14:19:34 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-12-22 03:24:14 -0500 |
commit | 47817254b8637b56730aec26eed2c337d3938bb5 (patch) | |
tree | 288ded69b4e5505520e9e347e7580a4df368838e /drivers | |
parent | 6c5807d7bc7d051fce00863ffb98d36325501eb2 (diff) |
ACPI: processor: unify arch_acpi_processor_cleanup_pdc
The x86 and ia64 implementations of the function in $subject are
exactly the same.
Also, since the arch-specific implementations of setting _PDC have
been completely hollowed out, remove the empty shells.
Cc: Tony Luck <tony.luck@intel.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Alex Chiang <achiang@hp.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/acpi/processor_pdc.c | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/drivers/acpi/processor_pdc.c b/drivers/acpi/processor_pdc.c index 48df08ebcec4..e786e2ce1882 100644 --- a/drivers/acpi/processor_pdc.c +++ b/drivers/acpi/processor_pdc.c | |||
@@ -1,3 +1,12 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2005 Intel Corporation | ||
3 | * Copyright (C) 2009 Hewlett-Packard Development Company, L.P. | ||
4 | * | ||
5 | * Alex Chiang <achiang@hp.com> | ||
6 | * - Unified x86/ia64 implementations | ||
7 | * Venkatesh Pallipadi <venkatesh.pallipadi@intel.com> | ||
8 | * - Added _PDC for platforms with Intel CPUs | ||
9 | */ | ||
1 | #include <linux/dmi.h> | 10 | #include <linux/dmi.h> |
2 | 11 | ||
3 | #include <acpi/acpi_drivers.h> | 12 | #include <acpi/acpi_drivers.h> |
@@ -121,6 +130,16 @@ static int acpi_processor_eval_pdc(struct acpi_processor *pr) | |||
121 | return status; | 130 | return status; |
122 | } | 131 | } |
123 | 132 | ||
133 | static void acpi_processor_cleanup_pdc(struct acpi_processor *pr) | ||
134 | { | ||
135 | if (pr->pdc) { | ||
136 | kfree(pr->pdc->pointer->buffer.pointer); | ||
137 | kfree(pr->pdc->pointer); | ||
138 | kfree(pr->pdc); | ||
139 | pr->pdc = NULL; | ||
140 | } | ||
141 | } | ||
142 | |||
124 | void acpi_processor_set_pdc(struct acpi_processor *pr) | 143 | void acpi_processor_set_pdc(struct acpi_processor *pr) |
125 | { | 144 | { |
126 | if (arch_has_acpi_pdc() == false) | 145 | if (arch_has_acpi_pdc() == false) |
@@ -128,7 +147,7 @@ void acpi_processor_set_pdc(struct acpi_processor *pr) | |||
128 | 147 | ||
129 | acpi_processor_init_pdc(pr); | 148 | acpi_processor_init_pdc(pr); |
130 | acpi_processor_eval_pdc(pr); | 149 | acpi_processor_eval_pdc(pr); |
131 | arch_acpi_processor_cleanup_pdc(pr); | 150 | acpi_processor_cleanup_pdc(pr); |
132 | } | 151 | } |
133 | EXPORT_SYMBOL_GPL(acpi_processor_set_pdc); | 152 | EXPORT_SYMBOL_GPL(acpi_processor_set_pdc); |
134 | 153 | ||