Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 80407
b: refs/heads/master
c: 3eaf5ef
h: refs/heads/master
i:
  80405: cc7440e
  80403: 80dfe8c
  80399: ca04fc3
v: v3
  • Loading branch information
Sam Ravnborg authored and Ingo Molnar committed Jan 30, 2008
1 parent 9db4666 commit 5349f00
Show file tree
Hide file tree
Showing 2 changed files with 10 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: 1e296f578a8ef70b314315a2bfc7b036f947803f
refs/heads/master: 3eaf5efae72b33bc6132e9590e5d4bf11532f8c4
15 changes: 9 additions & 6 deletions trunk/arch/x86/kernel/topology.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@

static DEFINE_PER_CPU(struct x86_cpu, cpu_devices);

int __cpuinit arch_register_cpu(int num)
#ifdef CONFIG_HOTPLUG_CPU
int arch_register_cpu(int num)
{
/*
* CPU0 cannot be offlined due to several
Expand All @@ -44,21 +45,23 @@ int __cpuinit arch_register_cpu(int num)
* Also certain PCI quirks require not to enable hotplug control
* for all CPU's.
*/
#ifdef CONFIG_HOTPLUG_CPU
if (num)
per_cpu(cpu_devices, num).cpu.hotpluggable = 1;
#endif

return register_cpu(&per_cpu(cpu_devices, num).cpu, num);
}
EXPORT_SYMBOL(arch_register_cpu);

#ifdef CONFIG_HOTPLUG_CPU
void arch_unregister_cpu(int num)
{
return unregister_cpu(&per_cpu(cpu_devices, num).cpu);
}
EXPORT_SYMBOL(arch_register_cpu);
EXPORT_SYMBOL(arch_unregister_cpu);
#else
int arch_register_cpu(int num)
{
return register_cpu(&per_cpu(cpu_devices, num).cpu, num);
}
EXPORT_SYMBOL(arch_register_cpu);
#endif /*CONFIG_HOTPLUG_CPU*/

static int __init topology_init(void)
Expand Down

0 comments on commit 5349f00

Please sign in to comment.