summaryrefslogtreecommitdiffstats
path: root/hw/qdev.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2009-05-27 22:54:29 +0200
committerPaul Brook <paul@codesourcery.com>2009-06-04 11:24:42 +0100
commitaca312affb616a907ae95eb7d9034e85512d6e7c (patch)
treef005174edba1b76afccc4e2659f5832a06b7d351 /hw/qdev.c
parent1e9fa730163c2a445014ff8324b169cd82a50df1 (diff)
downloadhqemu-aca312affb616a907ae95eb7d9034e85512d6e7c.zip
hqemu-aca312affb616a907ae95eb7d9034e85512d6e7c.tar.gz
qdev: kill DeviceState->name
is redundant with DeviceState->type->name Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/qdev.c')
-rw-r--r--hw/qdev.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/qdev.c b/hw/qdev.c
index d945ff9..cedb772 100644
--- a/hw/qdev.c
+++ b/hw/qdev.c
@@ -84,7 +84,6 @@ DeviceState *qdev_create(BusState *bus, const char *name)
}
dev = qemu_mallocz(t->size);
- dev->name = name;
dev->type = t;
if (!bus) {
@@ -162,7 +161,7 @@ CharDriverState *qdev_init_chardev(DeviceState *dev)
static int next_serial;
static int next_virtconsole;
/* FIXME: This is a nasty hack that needs to go away. */
- if (strncmp(dev->name, "virtio", 6) == 0) {
+ if (strncmp(dev->type->name, "virtio", 6) == 0) {
return virtcon_hds[next_virtconsole++];
} else {
return serial_hds[next_serial++];
OpenPOWER on IntegriCloud