From: Blue Swirl <blauwirbel@gmail.com>
To: qemu-devel <qemu-devel@nongnu.org>
Subject: [Qemu-devel] Strange qdev related crash (m48t59 ISA qdev conversion)
Date: Sun, 13 Sep 2009 11:30:47 +0300 [thread overview]
Message-ID: <f43fc5580909130130n326558xf09698e8bb7c237@mail.gmail.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1569 bytes --]
Hi,
I get a strange crash when trying to add an ISA bus version of m48t59:
gdb --args ./obj-amd64/sparc-softmmu/qemu-system-sparc -L pc-bios
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu"...
(gdb) r
[Thread debugging using libthread_db enabled]
[New Thread 0x7fbc7a7b9700 (LWP 10616)]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fbc7a7b9700 (LWP 10616)]
0x000000000047c1ac in qdev_create (bus=0xf3b770, name=0x578e80 "m48t59")
at /src/qemu/hw/qdev.c:102
102 qdev_prop_set_defaults(dev, dev->parent_bus->info->props);
(gdb) p dev->parent_bus
$1 = (BusState *) 0xffffffff00000000
(gdb) p bus
$2 = (BusState *) 0x26da770
(gdb) l
97
98 dev = qemu_mallocz(info->size);
99 dev->info = info;
100 dev->parent_bus = bus;
101 qdev_prop_set_defaults(dev, dev->info->props);
102 qdev_prop_set_defaults(dev, dev->parent_bus->info->props);
103 qdev_prop_set_compat(dev);
104 QLIST_INSERT_HEAD(&bus->children, dev, sibling);
105 return dev;
106 }
Line 100 should make sure that dev->parent_bus is OK. Note that the
patch should not affect the SysBus version used by Sparc32 very much.
Recompiling qdev.c with CFLAGS=-g does not change anything.
[-- Attachment #2: 0001-Add-an-ISA-bus-version-of-m48t59.patch --]
[-- Type: application/mbox, Size: 5855 bytes --]
next reply other threads:[~2009-09-13 8:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-13 8:30 Blue Swirl [this message]
2009-09-14 9:44 ` [Qemu-devel] Strange qdev related crash (m48t59 ISA qdev conversion) Gerd Hoffmann
2009-09-14 16:24 ` Blue Swirl
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=f43fc5580909130130n326558xf09698e8bb7c237@mail.gmail.com \
--to=blauwirbel@gmail.com \
--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 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).