diff options
author | Michal Simek <monstr@monstr.eu> | 2009-04-21 14:06:08 +0200 |
---|---|---|
committer | Michal Simek <monstr@monstr.eu> | 2009-04-23 16:27:28 +0200 |
commit | fbeda67782689bf80109512b16ac47264a282d01 (patch) | |
tree | 0e2e375116144d1e65b26bad3c94b5a956e115e2 /arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c | |
parent | microblaze: Fix USR1/2 pvr printing message (diff) | |
download | linux-fbeda67782689bf80109512b16ac47264a282d01.tar.xz linux-fbeda67782689bf80109512b16ac47264a282d01.zip |
microblaze: Do not use PVR configuration for broken MB version
Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c')
-rw-r--r-- | arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c b/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c index cf7424a6bb87..153f57c57b6d 100644 --- a/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c +++ b/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c @@ -30,6 +30,13 @@ void set_cpuinfo_pvr_full(struct cpuinfo *ci, struct device_node *cpu) int temp; /* for saving temp value */ get_pvr(&pvr); + CI(ver_code, VERSION); + if (!ci->ver_code) { + printk(KERN_ERR "ERROR: MB has broken PVR regs " + "-> use DTS setting\n"); + return; + } + temp = PVR_USE_BARREL(pvr) | PVR_USE_MSR_INSTR(pvr) |\ PVR_USE_PCMP_INSTR(pvr) | PVR_USE_DIV(pvr); if (ci->use_instr != temp) @@ -60,8 +67,6 @@ void set_cpuinfo_pvr_full(struct cpuinfo *ci, struct device_node *cpu) CI(mmu, USE_MMU); - CI(ver_code, VERSION); - CI(use_icache, USE_ICACHE); CI(icache_tagbits, ICACHE_ADDR_TAG_BITS); CI(icache_write, ICACHE_ALLOW_WR); |