From: "Alex Bennée" <1918302@bugs.launchpad.net>
To: qemu-devel@nongnu.org
Subject: [Bug 1918302] Re: qemu-system-arm segfaults while servicing SYS_HEAPINFO
Date: Mon, 15 Mar 2021 12:45:44 -0000 [thread overview]
Message-ID: <161581234442.3544.11083081800830363320.malone@chaenomeles.canonical.com> (raw)
In-Reply-To: 161530383644.26074.10419563158373925479.malonedeb@gac.canonical.com
I think this was fixed earlier by:
commit 095f8c029319b79cce487e3b566cd826b93da3e6
Author: Keith Packard <keithp@keithp.com>
Date: Fri Jan 8 22:42:51 2021 +0000
semihosting: Support SYS_HEAPINFO when env->boot_info is not set
env->boot_info is only set in some ARM startup paths, so we cannot
rely on it to support the SYS_HEAPINFO semihosting function. When not
available, fallback to finding a RAM memory region containing the
current stack and use the base of that.
Signed-off-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20210107170717.2098982-5-keithp@keithp.com>
Message-Id: <20210108224256.2321-16-alex.bennee@linaro.org>
Not withstanding the other fix to the ARG usage.
** Changed in: qemu
Status: New => In Progress
** Changed in: qemu
Assignee: (unassigned) => Alex Bennée (ajbennee)
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1918302
Title:
qemu-system-arm segfaults while servicing SYS_HEAPINFO
Status in QEMU:
In Progress
Bug description:
I compiled QEMU version 5.2.0 from source on Ubuntu 18.04, and tried
to use it to run the attached bare-metal Arm hello-world image, using
the command line
qemu-system-arm -M microbit -semihosting -nographic -device
loader,file=hello.hex
The result was that qemu-system-arm itself died of a segfault.
Compiling it for debugging, the location of the segfault was in
target/arm/arm-semi.c, in the case handler for the semihosting call
TARGET_SYS_HEAPINFO, on line 1020 which assigns to 'rambase':
const struct arm_boot_info *info = env->boot_info;
target_ulong rambase = info->loader_start;
and the problem seems to be that 'info', aka env->boot_info, is NULL
in this context.
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1918302/+subscriptions
next prev parent reply other threads:[~2021-03-15 12:57 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-09 15:30 [Bug 1918302] [NEW] qemu-system-arm segfaults while servicing SYS_HEAPINFO Simon Tatham
2021-03-11 18:44 ` [Bug 1918302] " Peter Maydell
2021-03-12 15:00 ` Peter Maydell
2021-03-12 15:04 ` Peter Maydell
2021-03-15 10:53 ` Alex Bennée
2021-03-15 12:42 ` Alex Bennée
2021-03-15 12:43 ` Alex Bennée
2021-03-15 12:45 ` Alex Bennée [this message]
2021-03-15 13:28 ` Peter Maydell
2021-03-25 11:49 ` Alex Bennée
2021-03-25 13:16 ` Peter Maydell
2021-03-25 14:48 ` Simon Tatham
2021-03-25 14:49 ` Simon Tatham
2021-03-25 15:31 ` Peter Maydell
2021-03-25 15:49 ` Simon Tatham
2021-04-30 9:16 ` Thomas Huth
2021-04-30 10:13 ` Peter Maydell
2021-05-01 5:42 ` Thomas Huth
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=161581234442.3544.11083081800830363320.malone@chaenomeles.canonical.com \
--to=1918302@bugs.launchpad.net \
--cc=qemu-devel@nongnu.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.