Skip to content
Snippets Groups Projects
Commit 4f9226b4 authored by Paul Burton's avatar Paul Burton Committed by Daniel Schwierzeck
Browse files

MIPS: Preserve Config implementation-defined bits


The coprocessor 0 Config register includes 9 implementation defined
bits, which in some processors do things like enable write combining or
other functionality. We ought not to wipe them to 0 during boot. Rather
than doing so, preserve their value & only clear the bits standardised
by the MIPS architecture.

Signed-off-by: default avatarPaul Burton <paul.burton@imgtec.com>
parent 33b5c9b2
No related branches found
No related tags found
No related merge requests found
...@@ -123,8 +123,9 @@ reset: ...@@ -123,8 +123,9 @@ reset:
mtc0 zero, CP0_COMPARE mtc0 zero, CP0_COMPARE
#ifndef CONFIG_SKIP_LOWLEVEL_INIT #ifndef CONFIG_SKIP_LOWLEVEL_INIT
/* CONFIG0 register */ mfc0 t0, CP0_CONFIG
li t0, CONF_CM_UNCACHED and t0, t0, MIPS_CONF_IMPL
or t0, t0, CONF_CM_UNCACHED
mtc0 t0, CP0_CONFIG mtc0 t0, CP0_CONFIG
#endif #endif
......
...@@ -450,6 +450,7 @@ ...@@ -450,6 +450,7 @@
#define MIPS_CONF_MT_FTLB (_ULCAST_(4) << 7) #define MIPS_CONF_MT_FTLB (_ULCAST_(4) << 7)
#define MIPS_CONF_AR (_ULCAST_(7) << 10) #define MIPS_CONF_AR (_ULCAST_(7) << 10)
#define MIPS_CONF_AT (_ULCAST_(3) << 13) #define MIPS_CONF_AT (_ULCAST_(3) << 13)
#define MIPS_CONF_IMPL (_ULCAST_(0x1ff) << 16)
#define MIPS_CONF_M (_ULCAST_(1) << 31) #define MIPS_CONF_M (_ULCAST_(1) << 31)
/* /*
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment