diff options
author | Michal Simek <monstr@monstr.eu> | 2009-10-21 12:29:46 +0200 |
---|---|---|
committer | Michal Simek <monstr@monstr.eu> | 2009-12-14 08:45:05 +0100 |
commit | f6e1f1b4809b6a63e22f82358ba2e750c7e1c1a2 (patch) | |
tree | b79122a5eba48559e70914f31d0a0947c9b36667 /arch/microblaze/kernel/cpu | |
parent | d4f182700bb1279ae7e76a59b9be39efa5f23bfe (diff) | |
download | linux-f6e1f1b4809b6a63e22f82358ba2e750c7e1c1a2.tar.bz2 |
microblaze: Checking DTS against PVR for write-back cache
WB cache has special flag in PVR. There is added checking mechanism
for PVR and DTS.
Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/kernel/cpu')
-rw-r--r-- | arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c b/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c index c5acf2b56eed..f72dbd66c844 100644 --- a/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c +++ b/arch/microblaze/kernel/cpu/cpuinfo-pvr-full.c @@ -21,8 +21,14 @@ */ #define CI(c, p) { ci->c = PVR_##p(pvr); } + +#if defined(CONFIG_EARLY_PRINTK) && defined(CONFIG_SERIAL_UARTLITE_CONSOLE) #define err_printk(x) \ early_printk("ERROR: Microblaze " x "-different for PVR and DTS\n"); +#else +#define err_printk(x) \ + printk(KERN_INFO "ERROR: Microblaze " x "-different for PVR and DTS\n"); +#endif void set_cpuinfo_pvr_full(struct cpuinfo *ci, struct device_node *cpu) { @@ -83,6 +89,11 @@ void set_cpuinfo_pvr_full(struct cpuinfo *ci, struct device_node *cpu) CI(dcache_base, DCACHE_BASEADDR); CI(dcache_high, DCACHE_HIGHADDR); + temp = PVR_DCACHE_USE_WRITEBACK(pvr); + if (ci->dcache_wb != temp) + err_printk("DCACHE WB"); + ci->dcache_wb = temp; + CI(use_dopb, D_OPB); CI(use_iopb, I_OPB); CI(use_dlmb, D_LMB); |