qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] physmem: improve ram size error messages


From: Paolo Bonzini
Subject: Re: [PATCH] physmem: improve ram size error messages
Date: Mon, 9 Nov 2020 15:24:02 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0

On 22/10/20 13:13, Pankaj Gupta wrote:
  Ram size mismatch condition logs below message.

    "Length mismatch: pc.ram: 0x80000000 in != 0x180000000: Invalid argument"

  This patch improves the readability of error messages.
  Removed the superflous "in" and changed "Length" to "Size".

Signed-off-by: Pankaj Gupta <pankaj.gupta.linux@gmail.com>
Reported-by: Li Zhang <li.zhang@cloud.ionos.com>
---
  softmmu/physmem.c | 6 +++---
  1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/softmmu/physmem.c b/softmmu/physmem.c
index e319fb2a1e..8da184f4a6 100644
--- a/softmmu/physmem.c
+++ b/softmmu/physmem.c
@@ -1756,15 +1756,15 @@ int qemu_ram_resize(RAMBlock *block, ram_addr_t 
newsize, Error **errp)
if (!(block->flags & RAM_RESIZEABLE)) {
          error_setg_errno(errp, EINVAL,
-                         "Length mismatch: %s: 0x" RAM_ADDR_FMT
-                         " in != 0x" RAM_ADDR_FMT, block->idstr,
+                         "Size mismatch: %s: 0x" RAM_ADDR_FMT
+                         " != 0x" RAM_ADDR_FMT, block->idstr,
                           newsize, block->used_length);
          return -EINVAL;
      }
if (block->max_length < newsize) {
          error_setg_errno(errp, EINVAL,
-                         "Length too large: %s: 0x" RAM_ADDR_FMT
+                         "Size too large: %s: 0x" RAM_ADDR_FMT
                           " > 0x" RAM_ADDR_FMT, block->idstr,
                           newsize, block->max_length);
          return -EINVAL;


Queued, thanks.

Paolo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]