Revision 4a057712 target-ppc/translate.c

b/target-ppc/translate.c
3025 3025
            gen_op_store_T0_gpr(rD(ctx->opcode));
3026 3026
        } else {
3027 3027
            /* Privilege exception */
3028
            if (loglevel) {
3028
            if (loglevel != 0) {
3029 3029
                fprintf(logfile, "Trying to read priviledged spr %d %03x\n",
3030 3030
                        sprn, sprn);
3031 3031
            }
......
3034 3034
        }
3035 3035
    } else {
3036 3036
        /* Not defined */
3037
        if (loglevel) {
3037
        if (loglevel != 0) {
3038 3038
            fprintf(logfile, "Trying to read invalid spr %d %03x\n",
3039 3039
                    sprn, sprn);
3040 3040
        }
......
3131 3131
            (*write_cb)(ctx, sprn);
3132 3132
        } else {
3133 3133
            /* Privilege exception */
3134
            if (loglevel) {
3134
            if (loglevel != 0) {
3135 3135
                fprintf(logfile, "Trying to write priviledged spr %d %03x\n",
3136 3136
                        sprn, sprn);
3137 3137
            }
......
3140 3140
        }
3141 3141
    } else {
3142 3142
        /* Not defined */
3143
        if (loglevel) {
3143
        if (loglevel != 0) {
3144 3144
            fprintf(logfile, "Trying to write invalid spr %d %03x\n",
3145 3145
                    sprn, sprn);
3146 3146
        }
......
3378 3378
    RET_PRIVOPC(ctx);
3379 3379
#else
3380 3380
    if (unlikely(!ctx->supervisor)) {
3381
        if (loglevel)
3381
        if (loglevel != 0)
3382 3382
            fprintf(logfile, "%s: ! supervisor\n", __func__);
3383 3383
        RET_PRIVOPC(ctx);
3384 3384
        return;
......
3434 3434
    RET_PRIVOPC(ctx);
3435 3435
#else
3436 3436
    if (unlikely(!ctx->supervisor)) {
3437
        if (loglevel)
3437
        if (loglevel != 0)
3438 3438
            fprintf(logfile, "%s: ! supervisor\n", __func__);
3439 3439
        RET_PRIVOPC(ctx);
3440 3440
        return;
......
5803 5803
        }
5804 5804
        /* Is opcode *REALLY* valid ? */
5805 5805
        if (unlikely(handler->handler == &gen_invalid)) {
5806
            if (loglevel > 0) {
5806
            if (loglevel != 0) {
5807 5807
                fprintf(logfile, "invalid/unsupported opcode: "
5808 5808
                        "%02x - %02x - %02x (%08x) 0x" ADDRX " %d\n",
5809 5809
                        opc1(ctx.opcode), opc2(ctx.opcode),
......
5816 5816
            }
5817 5817
        } else {
5818 5818
            if (unlikely((ctx.opcode & handler->inval) != 0)) {
5819
                if (loglevel > 0) {
5819
                if (loglevel != 0) {
5820 5820
                    fprintf(logfile, "invalid bits: %08x for opcode: "
5821 5821
                            "%02x -%02x - %02x (%08x) 0x" ADDRX "\n",
5822 5822
                            ctx.opcode & handler->inval, opc1(ctx.opcode),

Also available in: Unified diff