diff options
author | jchandra <jchandra@FreeBSD.org> | 2013-04-12 17:22:12 +0000 |
---|---|---|
committer | jchandra <jchandra@FreeBSD.org> | 2013-04-12 17:22:12 +0000 |
commit | ad2a2fb3b728bda0b7356d5a90195f233f10bed6 (patch) | |
tree | 37c3f4e28bb68c551dda7a2d5f646c902be55448 /contrib/llvm/utils/TableGen/DFAPacketizerEmitter.cpp | |
parent | 81ffe59cb0b5beecd508d32f8de11987a8090661 (diff) | |
download | FreeBSD-src-ad2a2fb3b728bda0b7356d5a90195f233f10bed6.zip FreeBSD-src-ad2a2fb3b728bda0b7356d5a90195f233f10bed6.tar.gz |
Move MIPS_MAX_TLB_ENTRIES definition from cpuregs.h to tlb.c
Having MIPS_MAX_TLB_ENTRIES defined to 128 is misleading, since it used
to be 64 in older releases of MIPS architecture (where it could be read
from Config1) and can be much more than 128 for the newer processors.
For now, move the definition to the only file using it (mips/mips/tlb.c)
and define MIPS_MAX_TLB_ENTRIES depending on the MIPS cpu defined. Also
add few checks so that we do not write beyond the end of the tlb_state
array.
This fixes a kernel data corruption seen in Netlogic XLP, which was casued
by tlb_save() writing beyond the end of tlb_state array when breaking into
debugger.
Diffstat (limited to 'contrib/llvm/utils/TableGen/DFAPacketizerEmitter.cpp')
0 files changed, 0 insertions, 0 deletions