From: Nathan Egge <negge@xiph.org>
To: qemu-devel@nongnu.org
Cc: richard.henderson@linaro.org, akihiko.odaki@daynix.com, deller@gmx.de
Subject: [PATCH v9 07/24] linux-user: Do not call get_errno() in do_brk()
Date: Fri, 4 Aug 2023 19:40:50 -0400 [thread overview]
Message-ID: <d83d4d31-dabd-5f05-e173-cbe255e26aed@xiph.org> (raw)
On 2023-08-04 18:00, Richard Henderson wrote:
> From: Akihiko Odaki <akihiko.odaki@daynix.com>
>
> Later the returned value is compared with -1, and negated errno is not
> expected.
>
> Fixes: 00faf08c95 ("linux-user: Don't use MAP_FIXED in do_brk()")
> Reviewed-by: Helge Deller <deller@gmx.de>
> Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
> Message-Id: <20230802071754.14876-4-akihiko.odaki@daynix.com>
> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
> ---
> linux-user/syscall.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/linux-user/syscall.c b/linux-user/syscall.c
> index 95727a816a..b9d2ec02f9 100644
> --- a/linux-user/syscall.c
> +++ b/linux-user/syscall.c
> @@ -862,9 +862,9 @@ abi_long do_brk(abi_ulong brk_val)
> */
> if (new_host_brk_page > brk_page) {
> new_alloc_size = new_host_brk_page - brk_page;
> - mapped_addr = get_errno(target_mmap(brk_page, new_alloc_size,
> - PROT_READ|PROT_WRITE,
> - MAP_ANON|MAP_PRIVATE, 0, 0));
> + mapped_addr = target_mmap(brk_page, new_alloc_size,
> + PROT_READ|PROT_WRITE,
> + MAP_ANON|MAP_PRIVATE, 0, 0);
> } else {
> new_alloc_size = 0;
> mapped_addr = brk_page;
> --
> 2.34.1
This patch is triggering a gitlab pipeline failure in Richard's tcg-next
branch:
https://gitlab.com/rth7680/qemu/-/pipelines/956532662
It can be reproduced locally by adding a git remote for rth7680 and then
running:
$ git checkout rth7680/tcg-next
$ .gitlab-ci.d/check-patch.py
Checking all commits since c26d005e62f4fd177dae0cd70c24cb96761edebc...
f7cca41b17c809958a7f04b7d7f64af40d64e645:31: ERROR: spaces required
around that '|' (ctx:VxV)
f7cca41b17c809958a7f04b7d7f64af40d64e645:32: ERROR: spaces required
around that '|' (ctx:VxV)
total: 2 errors, 0 warnings, 12 lines checked
❌ FAIL one or more commits failed scripts/checkpatch.pl
The linux-user/syscall.c has many such places where this style check is
failing. Should these be fixed in a separate patch?
Sincerely,
Nathan
next reply other threads:[~2023-08-04 23:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-04 23:40 Nathan Egge [this message]
2023-08-05 4:26 ` [PATCH v9 07/24] linux-user: Do not call get_errno() in do_brk() Richard Henderson
-- strict thread matches above, loose matches on Subject: below --
2023-08-04 22:00 [PATCH v9 for-8.1 00/24] linux-user + tcg patch queue Richard Henderson
2023-08-04 22:00 ` [PATCH v9 07/24] linux-user: Do not call get_errno() in do_brk() Richard Henderson
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=d83d4d31-dabd-5f05-e173-cbe255e26aed@xiph.org \
--to=negge@xiph.org \
--cc=akihiko.odaki@daynix.com \
--cc=deller@gmx.de \
--cc=qemu-devel@nongnu.org \
--cc=richard.henderson@linaro.org \
/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).