qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Richard Henderson <richard.henderson@linaro.org>
To: Luc Michel <lmichel@kalray.eu>, qemu-devel@nongnu.org
Cc: qemu-trivial@nongnu.org,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Stefano Garzarella" <sgarzare@redhat.com>,
	"Philippe Mathieu-Daudé" <f4bug@amsat.org>,
	"Paolo Bonzini" <pbonzini@redhat.com>
Subject: Re: [PATCH v2] hw/elf_ops.h: switch to ssize_t for elf loader return type
Date: Mon, 18 Oct 2021 13:56:13 -0700	[thread overview]
Message-ID: <ca79c888-71dd-b9d9-d5d0-49dc235c99ec@linaro.org> (raw)
In-Reply-To: <20211014194325.19917-1-lmichel@kalray.eu>

On 10/14/21 12:43 PM, Luc Michel wrote:
> Until now, int was used as the return type for all the ELF
> loader related functions. The returned value is the sum of all loaded
> program headers "MemSize" fields.
> 
> Because of the overflow check in elf_ops.h, trying to load an ELF bigger
> than INT_MAX will fail. Switch to ssize_t to remove this limitation.
> 
> Reviewed-by: Philippe Mathieu-Daudé<f4bug@amsat.org>
> Signed-off-by: Luc Michel<lmichel@kalray.eu>
> ---
> v2:
>    - Turn load_elf ret local variable to ssize_t [Stefano]
>    - Add Phil's R-B
> ---
>   include/hw/elf_ops.h | 27 ++++++++++----------
>   include/hw/loader.h  | 60 ++++++++++++++++++++++----------------------
>   hw/core/loader.c     | 60 +++++++++++++++++++++++---------------------
>   3 files changed, 75 insertions(+), 72 deletions(-)

I'm going to queue this to target-arm.next, as there doesn't seem to be another more 
obvious tree.


r~


      parent reply	other threads:[~2021-10-18 20:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-14 19:43 [PATCH v2] hw/elf_ops.h: switch to ssize_t for elf loader return type Luc Michel
2021-10-15  0:56 ` Richard Henderson
2021-10-15  7:23 ` Stefano Garzarella
2021-10-18 20:56 ` Richard Henderson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ca79c888-71dd-b9d9-d5d0-49dc235c99ec@linaro.org \
    --to=richard.henderson@linaro.org \
    --cc=f4bug@amsat.org \
    --cc=lmichel@kalray.eu \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    --cc=sgarzare@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).