From: "Philippe Mathieu-Daudé" <philmd@oss.qualcomm.com>
To: qemu-devel@nongnu.org
Subject: [PULL 33/56] hw/nmi: Rename nmi_monitor_handler() -> raise_nmi()
Date: Sun, 16 Aug 2026 16:45:32 +0200 [thread overview]
Message-ID: <20260816144556.69009-34-philmd@oss.qualcomm.com> (raw)
In-Reply-To: <20260816144556.69009-1-philmd@oss.qualcomm.com>
nmi_monitor_handler() is not related to the monitor,
rename it as raise_nmi().
Signed-off-by: Philippe Mathieu-Daudé <philmd@oss.qualcomm.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20260812121232.71958-6-philmd@oss.qualcomm.com>
---
include/hw/core/nmi.h | 10 ++++++----
hw/core/nmi.c | 2 +-
hw/hppa/machine.c | 2 +-
hw/i386/x86.c | 2 +-
hw/intc/m68k_irqc.c | 2 +-
hw/m68k/q800-glue.c | 2 +-
hw/misc/macio/gpio.c | 2 +-
hw/ppc/pnv.c | 2 +-
hw/ppc/spapr.c | 2 +-
hw/s390x/s390-virtio-ccw.c | 2 +-
10 files changed, 15 insertions(+), 13 deletions(-)
diff --git a/include/hw/core/nmi.h b/include/hw/core/nmi.h
index 851be28257e..a8feac3b67e 100644
--- a/include/hw/core/nmi.h
+++ b/include/hw/core/nmi.h
@@ -38,12 +38,14 @@ struct NMIClass {
InterfaceClass parent_class;
/**
- * nmi_monitor_handler: Callback to handle NMI notifications.
- *
+ * raise_nmi: Callback to handle NMI notifications.
* @ns: Class #NMIState state
* @errp: pointer to error object
+ *
+ * Called by nmi_inject() to perform the machine-specific
+ * action when a NMI is requested.
*/
- void (*nmi_monitor_handler)(NMIState *ns, Error **errp);
+ void (*raise_nmi)(NMIState *ns, Error **errp);
};
/**
@@ -58,7 +60,7 @@ struct NMIClass {
* and on s390 it triggers the RESTART interrupt on the first CPU.)
*
* The NMI is injected by looking for a QOM object which implements
- * the TYPE_NMI interface, and calling its nmi_monitor_handler method. Usually
+ * the TYPE_NMI interface, and calling its raise_nmi method. Usually
* it is the machine model class that implements this interface.
*
* Not all machines implement NMI handling; this function
diff --git a/hw/core/nmi.c b/hw/core/nmi.c
index 2d890f2995d..a6edf4fbf01 100644
--- a/hw/core/nmi.c
+++ b/hw/core/nmi.c
@@ -37,7 +37,7 @@ static int do_nmi(Object *o, void *opaque)
NMIClass *nc = NMI_GET_CLASS(n);
ns->handled = true;
- nc->nmi_monitor_handler(n, &ns->err);
+ nc->raise_nmi(n, &ns->err);
if (ns->err) {
return -1;
}
diff --git a/hw/hppa/machine.c b/hw/hppa/machine.c
index 2b44debc388..717cfde61da 100644
--- a/hw/hppa/machine.c
+++ b/hw/hppa/machine.c
@@ -851,7 +851,7 @@ static void hppa_machine_common_class_init(ObjectClass *oc, const void *data)
mc->default_ram_id = "hppa.ram";
mc->default_nic = "tulip";
- nc->nmi_monitor_handler = hppa_nmi;
+ nc->raise_nmi = hppa_nmi;
}
static void HP_B160L_machine_init_class_init(ObjectClass *oc, const void *data)
diff --git a/hw/i386/x86.c b/hw/i386/x86.c
index 0ea5453403d..d1414ff63db 100644
--- a/hw/i386/x86.c
+++ b/hw/i386/x86.c
@@ -389,7 +389,7 @@ static void x86_machine_class_init(ObjectClass *oc, const void *data)
mc->get_default_cpu_node_id = x86_get_default_cpu_node_id;
mc->possible_cpu_arch_ids = x86_possible_cpu_arch_ids;
mc->kvm_type = x86_kvm_type;
- nc->nmi_monitor_handler = x86_nmi;
+ nc->raise_nmi = x86_nmi;
object_class_property_add(oc, X86_MACHINE_SMM, "OnOffAuto",
x86_machine_get_smm, x86_machine_set_smm,
diff --git a/hw/intc/m68k_irqc.c b/hw/intc/m68k_irqc.c
index bc41b44d455..29f758dafd1 100644
--- a/hw/intc/m68k_irqc.c
+++ b/hw/intc/m68k_irqc.c
@@ -97,7 +97,7 @@ static void m68k_irqc_class_init(ObjectClass *oc, const void *data)
InterruptStatsProviderClass *ic = INTERRUPT_STATS_PROVIDER_CLASS(oc);
device_class_set_props(dc, m68k_irqc_properties);
- nc->nmi_monitor_handler = m68k_nmi;
+ nc->raise_nmi = m68k_nmi;
device_class_set_legacy_reset(dc, m68k_irqc_reset);
dc->vmsd = &vmstate_m68k_irqc;
ic->get_statistics = m68k_irqc_get_statistics;
diff --git a/hw/m68k/q800-glue.c b/hw/m68k/q800-glue.c
index b13e5ef95f1..265af90a8e6 100644
--- a/hw/m68k/q800-glue.c
+++ b/hw/m68k/q800-glue.c
@@ -237,7 +237,7 @@ static void glue_class_init(ObjectClass *klass, const void *data)
dc->vmsd = &vmstate_glue;
device_class_set_props(dc, glue_properties);
rc->phases.hold = glue_reset_hold;
- nc->nmi_monitor_handler = glue_nmi;
+ nc->raise_nmi = glue_nmi;
}
static const TypeInfo glue_info_types[] = {
diff --git a/hw/misc/macio/gpio.c b/hw/misc/macio/gpio.c
index 1bdca728f97..db0c4ecb3cf 100644
--- a/hw/misc/macio/gpio.c
+++ b/hw/misc/macio/gpio.c
@@ -201,7 +201,7 @@ static void macio_gpio_class_init(ObjectClass *oc, const void *data)
device_class_set_legacy_reset(dc, macio_gpio_reset);
dc->vmsd = &vmstate_macio_gpio;
- nc->nmi_monitor_handler = macio_gpio_nmi;
+ nc->raise_nmi = macio_gpio_nmi;
}
static const TypeInfo macio_gpio_init_info = {
diff --git a/hw/ppc/pnv.c b/hw/ppc/pnv.c
index 8676be7bbb1..a9f74245866 100644
--- a/hw/ppc/pnv.c
+++ b/hw/ppc/pnv.c
@@ -3583,7 +3583,7 @@ static void pnv_machine_class_init(ObjectClass *oc, const void *data)
mc->default_ram_size = 1 * GiB;
mc->default_ram_id = "pnv.ram";
ispc->print_info = pnv_pic_print_info;
- nc->nmi_monitor_handler = pnv_nmi;
+ nc->raise_nmi = pnv_nmi;
object_class_property_add_bool(oc, "hb-mode",
pnv_machine_get_hb, pnv_machine_set_hb);
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index c376a588720..1bc90ceed35 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -4652,7 +4652,7 @@ static void spapr_machine_class_init(ObjectClass *oc, const void *data)
mc->nvdimm_supported = true;
smc->resize_hpt_default = SPAPR_RESIZE_HPT_ENABLED;
fwc->get_dev_path = spapr_get_fw_dev_path;
- nc->nmi_monitor_handler = spapr_nmi;
+ nc->raise_nmi = spapr_nmi;
vhc->cpu_in_nested = spapr_cpu_in_nested;
vhc->deliver_hv_excp = spapr_exit_nested;
vhc->hypercall = emulate_spapr_hypercall;
diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
index ac04245d65b..21d9f51ddcc 100644
--- a/hw/s390x/s390-virtio-ccw.c
+++ b/hw/s390x/s390-virtio-ccw.c
@@ -830,7 +830,7 @@ static void ccw_machine_class_init(ObjectClass *oc, const void *data)
hc->plug = s390_machine_device_plug;
hc->unplug_request = s390_machine_device_unplug_request;
hc->unplug = s390_machine_device_unplug;
- nc->nmi_monitor_handler = s390_nmi;
+ nc->raise_nmi = s390_nmi;
mc->default_ram_id = "s390.ram";
mc->default_nic = "virtio-net-ccw";
dsi->qmp_dump_skeys = s390_qmp_dump_skeys;
--
2.53.0
next prev parent reply other threads:[~2026-08-16 14:51 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-16 14:44 [PULL 00/56] Misc HW patches for 2026-08-16 Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 01/56] hw/qdev: Remove DEFINE_PROP_DMAADDR() and 'hw/qdev-dma.h' Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 02/56] hw/mem/nvdimm: fix "size" property typename Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 03/56] qdev: Make qdev_is_realized() take a const DeviceState * Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 04/56] hw/hyperv/balloon: Use qdev_is_realized() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 05/56] hw/intc/apic: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 06/56] hw/mem/memory-device: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 07/56] hw/mem/pc-dimm: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 08/56] hw/nvram: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 09/56] hw/ppc/pnv_xscom: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 10/56] hw/vfio: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 11/56] hw/virtio/virtio-mem: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 12/56] hw/virtio/virtio-qmp: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 13/56] target/i386/cpu: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 14/56] target/s390x: " Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 15/56] hw/qdev: Parent device before setting parent bus Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 16/56] hw/i386/pc: xen: reinstate the "xenfv" machine alias Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 17/56] hw/net/rtl8139: Fix handling of VLAN tags on incoming short packets Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 18/56] hw/net/rtl8139: Send whole of vlan-tagged packet when doing loopback Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 19/56] hw/block/pflash_cfi01: Restore ROMD mode after migration Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 20/56] hw/nvme: add SPDM_SOCKET Kconfig dependency Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 21/56] hw/cpu: Correct CPU_GET_CLASS() comment Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 22/56] hw/cpu: Include missing 'qemu/accel.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 23/56] hw/cpu: Move internal declarations to new 'cpu-internal.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 24/56] hw/cpu: Rename cpu_common_realizefn() -> cpu_exec_realize() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 25/56] hw/cpu: Rename cpu_exec_realizefn() -> cpu_common_realize() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 26/56] hw/cpu: Rename cpu_exec_unrealizefn() -> cpu_common_unrealize() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 27/56] hw/cpu: Extract cpu_exec_realize() out of cpu_common_realizefn() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 28/56] hw/cpu: Move system-specific cpu_exec_realize() to cpu-system.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 29/56] hw/nmi: Use object_child_foreach_recursive() in nmi_children() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 30/56] hw/s390x/virtio-ccw: Always inject NMI to first CPU Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 31/56] hw/nmi: Remove @cpu_index argument from NMIClass::nmi_monitor_handler() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 32/56] hw/nmi: Remove @cpu_index argument from nmi_inject() Philippe Mathieu-Daudé
2026-08-16 14:45 ` Philippe Mathieu-Daudé [this message]
2026-08-16 14:45 ` [PULL 34/56] hw/nmi: Remove unused @errp argument from raise_nmi() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 35/56] hw/nmi: Raise NMI line only once Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 36/56] hexagon: Remove unnecessary 'monitor/monitor.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 37/56] net/vhost-vdpa: Include missing 'qemu/iov.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 38/56] tests/unit: Include 'qemu/main-loop.h' header in test-util-sockets.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 39/56] qapi/qmp-dispatch: Include 'qemu/aio-wait.h' and 'monitor/monitor.h' Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 40/56] qapi/qmp-registry: Remove unnecessary 'monitor/monitor.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 41/56] migration/hmp-cmds: Include 'block/block-global-state.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 42/56] monitor: Include missing 'qemu/aio-wait.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 43/56] monitor: Include missing 'qemu/lockable.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 44/56] monitor: Include missing 'qemu/coroutine-core.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 45/56] monitor: Reduce inclusion of 'qapi/qapi-emit-events.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 46/56] monitor: Remove unnecessary 'block/block.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 47/56] system: Remove unnecessary 'monitor/monitor.h' header Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 48/56] system/dirtylimit: Extract HMP code to dirtylimit-hmp-cmds.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 49/56] system: Move qmp_inject_nmi() to hw/core/machine-qmp-cmds.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 50/56] system: Extract QMP memsave/pmemsave commands to physmem-qmp-cmds.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 51/56] system: Move runstate-related code from cpus.c to runstate.c Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 52/56] monitor: Rename MonitorHMP @mon -> @hmp Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 53/56] monitor: Better express monitor_read()'s opaque arg is of Monitor type Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 54/56] monitor: Replace container_of(MonitorHMP, parent_obj) -> MONITOR_HMP() Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 55/56] hw/elf_ops: defend against weird elf headers Philippe Mathieu-Daudé
2026-08-16 14:45 ` [PULL 56/56] hw/core/machine: Move EHCI migration compat properties to 11.1 Philippe Mathieu-Daudé
2026-08-16 17:26 ` [PULL 00/56] Misc HW patches for 2026-08-16 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=20260816144556.69009-34-philmd@oss.qualcomm.com \
--to=philmd@oss.qualcomm.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.