Commit 3f5dcc340c1e4fa8a49066e30cf980bafdb3ecf4

Authored by bellard
1 parent f09936ac

PowerPC merge (Jocelyn Mayer)


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@565 c046a42c-6fe2-441c-8c8c-71466251a162
exec-all.h
... ... @@ -541,7 +541,13 @@ static inline target_ulong get_phys_addr_code(CPUState *env, target_ulong addr)
541 541 int is_user, index;
542 542  
543 543 index = (addr >> TARGET_PAGE_BITS) & (CPU_TLB_SIZE - 1);
  544 +#if defined(TARGET_I386)
544 545 is_user = ((env->hflags & HF_CPL_MASK) == 3);
  546 +#elif defined (TARGET_PPC)
  547 + is_user = msr_pr;
  548 +#else
  549 +#error "Unimplemented !"
  550 +#endif
545 551 if (__builtin_expect(env->tlb_read[is_user][index].address !=
546 552 (addr & TARGET_PAGE_MASK), 0)) {
547 553 ldub_code((void *)addr);
... ...
translate-all.c
... ... @@ -119,7 +119,7 @@ int cpu_gen_code(CPUState *env, TranslationBlock *tb,
119 119 gen_opc_buf, gen_opparam_buf);
120 120 *gen_code_size_ptr = gen_code_size;
121 121 #ifdef DEBUG_DISAS
122   - if (loglevel) {
  122 + if (loglevel && 0) {
123 123 fprintf(logfile, "OUT: [size=%d]\n", *gen_code_size_ptr);
124 124 disas(logfile, gen_code_buf, *gen_code_size_ptr, 1, 0);
125 125 fprintf(logfile, "\n");
... ... @@ -203,7 +203,6 @@ int cpu_restore_state(TranslationBlock *tb,
203 203 case INDEX_op_ ## op ## _raw
204 204 #else
205 205 #define CASE3(op)\
206   - case INDEX_op_ ## op ## _raw:\
207 206 case INDEX_op_ ## op ## _user:\
208 207 case INDEX_op_ ## op ## _kernel
209 208 #endif
... ...
... ... @@ -85,7 +85,7 @@
85 85 #define KERNEL_LOAD_ADDR 0x00100000
86 86 #elif defined (TARGET_PPC)
87 87 //#define USE_OPEN_FIRMWARE
88   -#if defined (USE_OPEN_FIRMWARE)
  88 +#if !defined (USE_OPEN_FIRMWARE)
89 89 #define KERNEL_LOAD_ADDR 0x01000000
90 90 #define KERNEL_STACK_ADDR 0x01200000
91 91 #else
... ...