Commit 5281966437e448e432da25cfba801e4dcf0b9460
1 parent
ef998233
CRIS: Init the feedback shiftreg used for randomizing TLB sets.
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6463 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
2 changed files
with
3 additions
and
0 deletions
target-cris/mmu.h
| @@ -10,6 +10,7 @@ struct cris_mmu_result_t | @@ -10,6 +10,7 @@ struct cris_mmu_result_t | ||
| 10 | int bf_vec; | 10 | int bf_vec; |
| 11 | }; | 11 | }; |
| 12 | 12 | ||
| 13 | +void cris_mmu_init(CPUState *env); | ||
| 13 | void cris_mmu_flush_pid(CPUState *env, uint32_t pid); | 14 | void cris_mmu_flush_pid(CPUState *env, uint32_t pid); |
| 14 | int cris_mmu_translate(struct cris_mmu_result_t *res, | 15 | int cris_mmu_translate(struct cris_mmu_result_t *res, |
| 15 | CPUState *env, uint32_t vaddr, | 16 | CPUState *env, uint32_t vaddr, |
target-cris/translate.c
| @@ -36,6 +36,7 @@ | @@ -36,6 +36,7 @@ | ||
| 36 | #include "disas.h" | 36 | #include "disas.h" |
| 37 | #include "tcg-op.h" | 37 | #include "tcg-op.h" |
| 38 | #include "helper.h" | 38 | #include "helper.h" |
| 39 | +#include "mmu.h" | ||
| 39 | #include "crisv32-decode.h" | 40 | #include "crisv32-decode.h" |
| 40 | #include "qemu-common.h" | 41 | #include "qemu-common.h" |
| 41 | 42 | ||
| @@ -3471,6 +3472,7 @@ void cpu_reset (CPUCRISState *env) | @@ -3471,6 +3472,7 @@ void cpu_reset (CPUCRISState *env) | ||
| 3471 | /* start in user mode with interrupts enabled. */ | 3472 | /* start in user mode with interrupts enabled. */ |
| 3472 | env->pregs[PR_CCS] |= U_FLAG | I_FLAG; | 3473 | env->pregs[PR_CCS] |= U_FLAG | I_FLAG; |
| 3473 | #else | 3474 | #else |
| 3475 | + cris_mmu_init(env); | ||
| 3474 | env->pregs[PR_CCS] = 0; | 3476 | env->pregs[PR_CCS] = 0; |
| 3475 | #endif | 3477 | #endif |
| 3476 | } | 3478 | } |