aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/cputable.c
diff options
context:
space:
mode:
authorKumar Gala <galak@kernel.crashing.org>2009-01-08 09:31:20 -0500
committerKumar Gala <galak@kernel.crashing.org>2009-01-28 19:16:50 -0500
commit105c31df6fc5a424b480321763b5598cf3817821 (patch)
treeda2bee2ae3db6b0af900947f60cb0c7bf1b9bd1f /arch/powerpc/kernel/cputable.c
parent0585a155a7318e69d43ef20636c2f072ad17d03f (diff)
powerpc/fsl-booke: Cleanup init/exception setup to be runtime
We currently have a few variants of fsl-booke processors (e500v1, e500v2, e500mc, and e200). They all have minor differences that we had previously been handling via ifdefs. To move towards having this support the following changes have been made: * PID1, PID2 only exist on e500v1 & e500v2 and should not be accessed on e500mc or e200. We use MMUCFG[NPIDS] to determine which case we are since we only touch PID1/2 in extremely early init code. * Not all IVORs exist on all the processors so introduce cpu_setup functions for each variant to setup the proper IVORs that are either unique or exist but have some variations between the processors Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/cputable.c')
-rw-r--r--arch/powerpc/kernel/cputable.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/cputable.c b/arch/powerpc/kernel/cputable.c
index 923f87aff20..9fdf1b8027b 100644
--- a/arch/powerpc/kernel/cputable.c
+++ b/arch/powerpc/kernel/cputable.c
@@ -35,6 +35,10 @@ const char *powerpc_base_platform;
35 * and ppc64 35 * and ppc64
36 */ 36 */
37#ifdef CONFIG_PPC32 37#ifdef CONFIG_PPC32
38extern void __setup_cpu_e200(unsigned long offset, struct cpu_spec* spec);
39extern void __setup_cpu_e500v1(unsigned long offset, struct cpu_spec* spec);
40extern void __setup_cpu_e500v2(unsigned long offset, struct cpu_spec* spec);
41extern void __setup_cpu_e500mc(unsigned long offset, struct cpu_spec* spec);
38extern void __setup_cpu_440ep(unsigned long offset, struct cpu_spec* spec); 42extern void __setup_cpu_440ep(unsigned long offset, struct cpu_spec* spec);
39extern void __setup_cpu_440epx(unsigned long offset, struct cpu_spec* spec); 43extern void __setup_cpu_440epx(unsigned long offset, struct cpu_spec* spec);
40extern void __setup_cpu_440gx(unsigned long offset, struct cpu_spec* spec); 44extern void __setup_cpu_440gx(unsigned long offset, struct cpu_spec* spec);
@@ -1687,6 +1691,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
1687 PPC_FEATURE_UNIFIED_CACHE, 1691 PPC_FEATURE_UNIFIED_CACHE,
1688 .mmu_features = MMU_FTR_TYPE_FSL_E, 1692 .mmu_features = MMU_FTR_TYPE_FSL_E,
1689 .dcache_bsize = 32, 1693 .dcache_bsize = 32,
1694 .cpu_setup = __setup_cpu_e200,
1690 .machine_check = machine_check_e200, 1695 .machine_check = machine_check_e200,
1691 .platform = "ppc5554", 1696 .platform = "ppc5554",
1692 } 1697 }
@@ -1706,6 +1711,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
1706 .num_pmcs = 4, 1711 .num_pmcs = 4,
1707 .oprofile_cpu_type = "ppc/e500", 1712 .oprofile_cpu_type = "ppc/e500",
1708 .oprofile_type = PPC_OPROFILE_FSL_EMB, 1713 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1714 .cpu_setup = __setup_cpu_e500v1,
1709 .machine_check = machine_check_e500, 1715 .machine_check = machine_check_e500,
1710 .platform = "ppc8540", 1716 .platform = "ppc8540",
1711 }, 1717 },
@@ -1724,6 +1730,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
1724 .num_pmcs = 4, 1730 .num_pmcs = 4,
1725 .oprofile_cpu_type = "ppc/e500", 1731 .oprofile_cpu_type = "ppc/e500",
1726 .oprofile_type = PPC_OPROFILE_FSL_EMB, 1732 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1733 .cpu_setup = __setup_cpu_e500v2,
1727 .machine_check = machine_check_e500, 1734 .machine_check = machine_check_e500,
1728 .platform = "ppc8548", 1735 .platform = "ppc8548",
1729 }, 1736 },
@@ -1739,6 +1746,7 @@ static struct cpu_spec __initdata cpu_specs[] = {
1739 .num_pmcs = 4, 1746 .num_pmcs = 4,
1740 .oprofile_cpu_type = "ppc/e500", /* xxx - galak, e500mc? */ 1747 .oprofile_cpu_type = "ppc/e500", /* xxx - galak, e500mc? */
1741 .oprofile_type = PPC_OPROFILE_FSL_EMB, 1748 .oprofile_type = PPC_OPROFILE_FSL_EMB,
1749 .cpu_setup = __setup_cpu_e500mc,
1742 .machine_check = machine_check_e500, 1750 .machine_check = machine_check_e500,
1743 .platform = "ppce500mc", 1751 .platform = "ppce500mc",
1744 }, 1752 },