diff options
Diffstat (limited to 'drivers/acpi/processor_core.c')
-rw-r--r-- | drivers/acpi/processor_core.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/acpi/processor_core.c b/drivers/acpi/processor_core.c index b1ec78b8a645..33a38d604630 100644 --- a/drivers/acpi/processor_core.c +++ b/drivers/acpi/processor_core.c | |||
@@ -184,7 +184,7 @@ phys_cpuid_t acpi_get_phys_id(acpi_handle handle, int type, u32 acpi_id) | |||
184 | phys_cpuid_t phys_id; | 184 | phys_cpuid_t phys_id; |
185 | 185 | ||
186 | phys_id = map_mat_entry(handle, type, acpi_id); | 186 | phys_id = map_mat_entry(handle, type, acpi_id); |
187 | if (phys_id == PHYS_CPUID_INVALID) | 187 | if (invalid_phys_cpuid(phys_id)) |
188 | phys_id = map_madt_entry(type, acpi_id); | 188 | phys_id = map_madt_entry(type, acpi_id); |
189 | 189 | ||
190 | return phys_id; | 190 | return phys_id; |
@@ -196,7 +196,7 @@ int acpi_map_cpuid(phys_cpuid_t phys_id, u32 acpi_id) | |||
196 | int i; | 196 | int i; |
197 | #endif | 197 | #endif |
198 | 198 | ||
199 | if (phys_id == PHYS_CPUID_INVALID) { | 199 | if (invalid_phys_cpuid(phys_id)) { |
200 | /* | 200 | /* |
201 | * On UP processor, there is no _MAT or MADT table. | 201 | * On UP processor, there is no _MAT or MADT table. |
202 | * So above phys_id is always set to PHYS_CPUID_INVALID. | 202 | * So above phys_id is always set to PHYS_CPUID_INVALID. |
@@ -215,12 +215,12 @@ int acpi_map_cpuid(phys_cpuid_t phys_id, u32 acpi_id) | |||
215 | * Ignores phys_id and always returns 0 for the processor | 215 | * Ignores phys_id and always returns 0 for the processor |
216 | * handle with acpi id 0 if nr_cpu_ids is 1. | 216 | * handle with acpi id 0 if nr_cpu_ids is 1. |
217 | * This should be the case if SMP tables are not found. | 217 | * This should be the case if SMP tables are not found. |
218 | * Return -1 for other CPU's handle. | 218 | * Return -EINVAL for other CPU's handle. |
219 | */ | 219 | */ |
220 | if (nr_cpu_ids <= 1 && acpi_id == 0) | 220 | if (nr_cpu_ids <= 1 && acpi_id == 0) |
221 | return acpi_id; | 221 | return acpi_id; |
222 | else | 222 | else |
223 | return -1; | 223 | return -EINVAL; |
224 | } | 224 | } |
225 | 225 | ||
226 | #ifdef CONFIG_SMP | 226 | #ifdef CONFIG_SMP |
@@ -233,7 +233,7 @@ int acpi_map_cpuid(phys_cpuid_t phys_id, u32 acpi_id) | |||
233 | if (phys_id == 0) | 233 | if (phys_id == 0) |
234 | return phys_id; | 234 | return phys_id; |
235 | #endif | 235 | #endif |
236 | return -1; | 236 | return -ENODEV; |
237 | } | 237 | } |
238 | 238 | ||
239 | int acpi_get_cpuid(acpi_handle handle, int type, u32 acpi_id) | 239 | int acpi_get_cpuid(acpi_handle handle, int type, u32 acpi_id) |