Skip to content

Commit

Permalink
monitor/hmp-cmds-target: Append a space in error message in gpa2hva()
Browse files Browse the repository at this point in the history
In qemu monitor mode, when we use gpa2hva command to print the host
virtual address corresponding to a guest physical address, if the gpa is
not in RAM, the error message is below:

  (qemu) gpa2hva 0x750000000
  Memory at address 0x750000000is not RAM

A space is missed between '0x750000000' and 'is'.

Signed-off-by: Yao Xingtao <yaoxt.fnst@fujitsu.com>
Fixes: e962844 ("hmp: gpa2hva and gpa2hpa hostaddr command")
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Dr. David Alan Gilbert <dave@treblig.org>
Message-ID: <20240319021610.2423844-1-ruansy.fnst@fujitsu.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
(cherry picked from commit a158c63)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
(Mjt: in 7.2. it is in monitor/misc.c, not in monitor/hmp-cmds-target.c)
  • Loading branch information
sailer1205 authored and Michael Tokarev committed Apr 9, 2024
1 parent 2e1645a commit 70b0e14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion monitor/misc.c
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ void *gpa2hva(MemoryRegion **p_mr, hwaddr addr, uint64_t size, Error **errp)
}

if (!memory_region_is_ram(mrs.mr) && !memory_region_is_romd(mrs.mr)) {
error_setg(errp, "Memory at address 0x%" HWADDR_PRIx "is not RAM", addr);
error_setg(errp, "Memory at address 0x%" HWADDR_PRIx " is not RAM", addr);
memory_region_unref(mrs.mr);
return NULL;
}
Expand Down

0 comments on commit 70b0e14

Please sign in to comment.