From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Eduardo Habkost" <ehabkost@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Philippe Mathieu-Daudé" <philmd@redhat.com>,
"Richard Henderson" <rth@twiddle.net>
Subject: [PATCH 2/4] hw/i386/pc: Use TYPE_PORT92 instead of hardcoded string
Date: Fri, 13 Dec 2019 11:50:58 +0100 [thread overview]
Message-ID: <20191213105100.8173-3-philmd@redhat.com> (raw)
In-Reply-To: <20191213105100.8173-1-philmd@redhat.com>
By using the TYPE_* definitions for devices, we can:
- quickly find where devices are used with 'git-grep'
- easily rename a device (one-line change).
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
hw/i386/pc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index 66a30cfdf5..2c2ae27447 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -1353,7 +1353,7 @@ static void pc_superio_init(ISABus *isa_bus, bool create_fdctrl, bool no_vmport)
qdev_prop_set_ptr(dev, "ps2_mouse", i8042);
qdev_init_nofail(dev);
}
- port92 = isa_create_simple(isa_bus, "port92");
+ port92 = isa_create_simple(isa_bus, TYPE_PORT92);
a20_line = qemu_allocate_irqs(handle_a20_line_change, first_cpu, 2);
i8042_setup_a20_line(i8042, a20_line[0]);
--
2.21.0
next prev parent reply other threads:[~2019-12-13 10:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-13 10:50 [PATCH 0/4] hw/i386/pc: Extract the port92 device Philippe Mathieu-Daudé
2019-12-13 10:50 ` [PATCH 1/4] hw/i386/pc: Convert DPRINTF() to trace events Philippe Mathieu-Daudé
2019-12-13 10:50 ` Philippe Mathieu-Daudé [this message]
2019-12-13 10:50 ` [PATCH 3/4] hw/i386/pc: Inline port92_init() Philippe Mathieu-Daudé
2019-12-13 10:51 ` [PATCH 4/4] hw/i386/pc: Extract the port92 device Philippe Mathieu-Daudé
2019-12-13 12:05 ` Paolo Bonzini
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=20191213105100.8173-3-philmd@redhat.com \
--to=philmd@redhat.com \
--cc=ehabkost@redhat.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
/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).