Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 188083
b: refs/heads/master
c: 2e9d5e4
h: refs/heads/master
i:
  188081: bf505eb
  188079: 7b451a9
v: v3
  • Loading branch information
Alex Chiang authored and Len Brown committed Mar 15, 2010
1 parent 8cda5e3 commit 9a12bd0
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 4d5d4cd88c542ff56cf7feacd29cc907f2abbfbb
refs/heads/master: 2e9d5e4efa0beeca03ad550bda28027826e83e42
10 changes: 4 additions & 6 deletions trunk/drivers/acpi/processor_driver.c
Original file line number Diff line number Diff line change
Expand Up @@ -361,10 +361,7 @@ static inline int acpi_processor_remove_fs(struct acpi_device *device)

/* Use the acpiid in MADT to map cpus in case of SMP */

#ifndef CONFIG_SMP
static int get_cpu_id(acpi_handle handle, int type, u32 acpi_id) { return -1; }
#else

#ifdef CONFIG_SMP
static struct acpi_table_madt *madt;

static int map_lapic_id(struct acpi_subtable_header *entry,
Expand Down Expand Up @@ -496,7 +493,7 @@ static int map_mat_entry(acpi_handle handle, int type, u32 acpi_id)
return apic_id;
}

static int get_cpu_id(acpi_handle handle, int type, u32 acpi_id)
int acpi_get_cpuid(acpi_handle handle, int type, u32 acpi_id)
{
int i;
int apic_id = -1;
Expand All @@ -513,6 +510,7 @@ static int get_cpu_id(acpi_handle handle, int type, u32 acpi_id)
}
return -1;
}
EXPORT_SYMBOL_GPL(acpi_get_cpuid);
#endif

/* --------------------------------------------------------------------------
Expand Down Expand Up @@ -579,7 +577,7 @@ static int acpi_processor_get_info(struct acpi_device *device)
device_declaration = 1;
pr->acpi_id = value;
}
cpu_index = get_cpu_id(pr->handle, device_declaration, pr->acpi_id);
cpu_index = acpi_get_cpuid(pr->handle, device_declaration, pr->acpi_id);

/* Handle UP system running SMP kernel, with no LAPIC in MADT */
if (!cpu0_initialized && (cpu_index == -1) &&
Expand Down
8 changes: 8 additions & 0 deletions trunk/include/acpi/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,14 @@ static inline int acpi_processor_get_bios_limit(int cpu, unsigned int *limit)

/* in processor_core.c */
void acpi_processor_set_pdc(acpi_handle handle);
#ifdef CONFIG_SMP
int acpi_get_cpuid(acpi_handle, int type, u32 acpi_id);
#else
static inline int acpi_get_cpuid(acpi_handle handle, int type, u32 acpi_id)
{
return -1;
}
#endif

/* in processor_throttling.c */
int acpi_processor_tstate_has_changed(struct acpi_processor *pr);
Expand Down

0 comments on commit 9a12bd0

Please sign in to comment.