From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Bernhard Beschow" <shentey@gmail.com>,
"Markus Armbruster" <armbru@redhat.com>,
qemu-ppc@nongnu.org, "Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Mark Cave-Ayland" <mark.cave-ayland@ilande.co.uk>,
"Michael S. Tsirkin" <mst@redhat.com>,
"Marcel Apfelbaum" <marcel.apfelbaum@gmail.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Richard Henderson" <richard.henderson@linaro.org>,
"Eduardo Habkost" <eduardo@habkost.net>
Subject: [PATCH v3 3/5] hw/i386/pc: Inline legacy pcspk_init() in pc_basic_device_init()
Date: Fri, 20 Oct 2023 12:54:44 +0200 [thread overview]
Message-ID: <20231020105447.43482-4-philmd@linaro.org> (raw)
In-Reply-To: <20231020105447.43482-1-philmd@linaro.org>
Reviewed-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
hw/i386/pc.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/hw/i386/pc.c b/hw/i386/pc.c
index c58a15182e..3937d88355 100644
--- a/hw/i386/pc.c
+++ b/hw/i386/pc.c
@@ -1286,7 +1286,11 @@ bool pc_basic_device_init(struct PCMachineState *pcms,
/* connect PIT to output control line of the HPET */
qdev_connect_gpio_out(hpet, 0, qdev_get_gpio_in(DEVICE(pit), 0));
}
- pcspk_init(pcms->pcspk, isa_bus, pit);
+ object_property_set_link(OBJECT(pcms->pcspk), "pit",
+ OBJECT(pit), &error_fatal);
+ if (!isa_realize_and_unref(pcms->pcspk, isa_bus, errp)) {
+ return false;
+ }
}
/* Super I/O */
--
2.41.0
next prev parent reply other threads:[~2023-10-20 10:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-20 10:54 [PATCH v3 0/5] hw/audio/pcspk: Inline pcspk_init() Philippe Mathieu-Daudé
2023-10-20 10:54 ` [PATCH v3 1/5] hw/i386/pc: Pass Error** argument to pc_basic_device_init() Philippe Mathieu-Daudé
2023-10-20 10:54 ` [PATCH v3 2/5] hw/i386/pc: Propagate error if HPET device creation failed Philippe Mathieu-Daudé
2023-10-20 10:54 ` Philippe Mathieu-Daudé [this message]
2023-10-20 10:54 ` [PATCH v3 4/5] hw/isa/i82378: Inline legacy pcspk_init() Philippe Mathieu-Daudé
2023-10-20 10:54 ` [PATCH v3 5/5] hw/mips/jazz: Inline and remove " Philippe Mathieu-Daudé
2023-10-20 15:50 ` [PATCH v3 0/5] hw/audio/pcspk: Inline pcspk_init() 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=20231020105447.43482-4-philmd@linaro.org \
--to=philmd@linaro.org \
--cc=armbru@redhat.com \
--cc=eduardo@habkost.net \
--cc=marcel.apfelbaum@gmail.com \
--cc=mark.cave-ayland@ilande.co.uk \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=richard.henderson@linaro.org \
--cc=shentey@gmail.com \
/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).