[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 16/49] clock: treat outputs and inputs the same in NamedClockList
From: |
Paolo Bonzini |
Subject: |
[PULL 16/49] clock: treat outputs and inputs the same in NamedClockList |
Date: |
Wed, 11 Dec 2024 17:26:46 +0100 |
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
hw/core/qdev-clock.c | 10 +---------
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/hw/core/qdev-clock.c b/hw/core/qdev-clock.c
index ca65685c04e..2f9d6cb7579 100644
--- a/hw/core/qdev-clock.c
+++ b/hw/core/qdev-clock.c
@@ -48,14 +48,6 @@ static NamedClockList *qdev_init_clocklist(DeviceState *dev,
const char *name,
if (clk == NULL) {
clk = CLOCK(object_new(TYPE_CLOCK));
object_property_add_child(OBJECT(dev), name, OBJECT(clk));
- if (output) {
- /*
- * Remove object_new()'s initial reference.
- * Note that for inputs, the reference created by object_new()
- * will be deleted in qdev_finalize_clocklist().
- */
- object_unref(OBJECT(clk));
- }
} else {
object_property_add_link(OBJECT(dev), name,
object_get_typename(OBJECT(clk)),
@@ -84,7 +76,7 @@ void qdev_finalize_clocklist(DeviceState *dev)
QLIST_FOREACH_SAFE(ncl, &dev->clocks, node, ncl_next) {
QLIST_REMOVE(ncl, node);
- if (!ncl->output && !ncl->alias) {
+ if (!ncl->alias) {
/*
* We kept a reference on the input clock to ensure it lives up to
* this point; it is used by the monitor to show the frequency.
--
2.47.1
- [PULL 07/49] rust: cargo: store desired warning levels in workspace Cargo.toml, (continued)
- [PULL 07/49] rust: cargo: store desired warning levels in workspace Cargo.toml, Paolo Bonzini, 2024/12/11
- [PULL 09/49] rust: fix a couple style issues from clippy, Paolo Bonzini, 2024/12/11
- [PULL 10/49] rust: build: establish a baseline of lints across all crates, Paolo Bonzini, 2024/12/11
- [PULL 11/49] rust: build: add "make clippy", "make rustfmt", "make rustdoc", Paolo Bonzini, 2024/12/11
- [PULL 13/49] rust: fix doc test syntax, Paolo Bonzini, 2024/12/11
- [PULL 08/49] rust: build: move strict lints handling to rustc_args.py, Paolo Bonzini, 2024/12/11
- [PULL 14/49] rust/qemu-api: Fix fragment-specifiers in define_property macro, Paolo Bonzini, 2024/12/11
- [PULL 12/49] rust: ci: add job that runs Rust tools, Paolo Bonzini, 2024/12/11
- [PULL 15/49] clock: clear callback on unparent, Paolo Bonzini, 2024/12/11
- [PULL 18/49] kvm: remove unnecessary #ifdef, Paolo Bonzini, 2024/12/11
- [PULL 16/49] clock: treat outputs and inputs the same in NamedClockList,
Paolo Bonzini <=
- [PULL 17/49] clock: inline most of qdev_init_clocklist, Paolo Bonzini, 2024/12/11
- [PULL 20/49] hw/block: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 19/49] arm: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 21/49] hw/net: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 22/49] ppc: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 24/49] hw/scsi: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 23/49] hw/rtc: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 26/49] hw/usb: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11
- [PULL 25/49] hw/sensor: Replace type_register() with type_register_static(), Paolo Bonzini, 2024/12/11