Commit 13829020 authored by Paolo Bonzini's avatar Paolo Bonzini
Browse files

user: introduce "-d page"

parent c30f0d18
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -938,7 +938,7 @@ int main(int argc, char **argv)
            unsigned long tmp;
            if (fscanf(fp, "%lu", &tmp) == 1) {
                mmap_min_addr = tmp;
                qemu_log("host mmap_min_addr=0x%lx\n", mmap_min_addr);
                qemu_log_mask(CPU_LOG_PAGE, "host mmap_min_addr=0x%lx\n", mmap_min_addr);
            }
            fclose(fp);
        }
@@ -955,7 +955,7 @@ int main(int argc, char **argv)

    free(target_environ);

    if (qemu_log_enabled()) {
    if (qemu_loglevel_mask(CPU_LOG_PAGE)) {
        qemu_log("guest_base  0x%lx\n", guest_base);
        log_page_dump();

+1 −0
Original line number Diff line number Diff line
@@ -48,6 +48,7 @@ static inline bool qemu_log_separate(void)
#define LOG_GUEST_ERROR    (1 << 11)
#define CPU_LOG_MMU        (1 << 12)
#define CPU_LOG_TB_NOCHAIN (1 << 13)
#define CPU_LOG_PAGE       (1 << 14)

/* Returns true if a bit is set in the current loglevel mask
 */
+4 −4
Original line number Diff line number Diff line
@@ -1743,7 +1743,7 @@ unsigned long init_guest_space(unsigned long host_start,
        }
    }

    qemu_log("Reserved 0x%lx bytes of guest address space\n", host_size);
    qemu_log_mask(CPU_LOG_PAGE, "Reserved 0x%lx bytes of guest address space\n", host_size);

    return real_start;
}
@@ -1784,7 +1784,7 @@ static void probe_guest_base(const char *image_name,
        }
        guest_base = real_start - loaddr;

        qemu_log("Relocating guest address space from 0x"
        qemu_log_mask(CPU_LOG_PAGE, "Relocating guest address space from 0x"
                      TARGET_ABI_FMT_lx " to 0x%lx\n",
                      loaddr, real_start);
    }
+2 −2
Original line number Diff line number Diff line
@@ -4241,7 +4241,7 @@ int main(int argc, char **argv, char **envp)
            unsigned long tmp;
            if (fscanf(fp, "%lu", &tmp) == 1) {
                mmap_min_addr = tmp;
                qemu_log("host mmap_min_addr=0x%lx\n", mmap_min_addr);
                qemu_log_mask(CPU_LOG_PAGE, "host mmap_min_addr=0x%lx\n", mmap_min_addr);
            }
            fclose(fp);
        }
@@ -4300,7 +4300,7 @@ int main(int argc, char **argv, char **envp)

    free(target_environ);

    if (qemu_log_enabled()) {
    if (qemu_loglevel_mask(CPU_LOG_PAGE)) {
        qemu_log("guest_base  0x%lx\n", guest_base);
        log_page_dump();

+2 −0
Original line number Diff line number Diff line
@@ -117,6 +117,8 @@ const QEMULogItem qemu_log_items[] = {
    { LOG_GUEST_ERROR, "guest_errors",
      "log when the guest OS does something invalid (eg accessing a\n"
      "non-existent register)" },
    { CPU_LOG_PAGE, "page",
      "dump pages at beginning of user mode emulation" },
    { CPU_LOG_TB_NOCHAIN, "nochain",
      "do not chain compiled TBs so that \"exec\" and \"cpu\" show\n"
      "complete traces" },