Skip to content

Commit

Permalink
powerpc: Move arch_sd_sibling_asym_packing() to smp.c
Browse files Browse the repository at this point in the history
Simple cleanup by moving arch_sd_sibling_asym_packing from process.c to
smp.c to save an #ifdef CONFIG_SMP

No functionality change.

Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
  • Loading branch information
Michael Neuling authored and Benjamin Herrenschmidt committed Sep 2, 2010
1 parent 28b5499 commit e1f0ece
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 11 deletions.
11 changes: 0 additions & 11 deletions arch/powerpc/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -1298,14 +1298,3 @@ unsigned long randomize_et_dyn(unsigned long base)

return ret;
}

#ifdef CONFIG_SMP
int arch_sd_sibling_asym_packing(void)
{
if (cpu_has_feature(CPU_FTR_ASYM_SMT)) {
printk_once(KERN_INFO "Enabling Asymmetric SMT scheduling\n");
return SD_ASYM_PACKING;
}
return 0;
}
#endif
9 changes: 9 additions & 0 deletions arch/powerpc/kernel/smp.c
Original file line number Diff line number Diff line change
Expand Up @@ -580,6 +580,15 @@ void __init smp_cpus_done(unsigned int max_cpus)
dump_numa_cpu_topology();
}

int arch_sd_sibling_asym_packing(void)
{
if (cpu_has_feature(CPU_FTR_ASYM_SMT)) {
printk_once(KERN_INFO "Enabling Asymmetric SMT scheduling\n");
return SD_ASYM_PACKING;
}
return 0;
}

#ifdef CONFIG_HOTPLUG_CPU
int __cpu_disable(void)
{
Expand Down

0 comments on commit e1f0ece

Please sign in to comment.