libvirt/libvirt-qemuProcessGuestPanicEventInfo-Fold-into-only-caller.patch
Jiri Denemark 0f2ee777b8 libvirt-11.10.0-18.el9
- qemu: Always assume support for 'QEMU_CAPS_SET_ACTION' (RHEL-242546)
- qemu: Remove unused 'qemuProcessRebootAllowed' (RHEL-242546)
- qemu: monitor: Remove support for 'watchdog-set-action' (RHEL-242546)
- qemu: Remove 'allowReboot' field (RHEL-242546)
- qemu: capabilities: Retire QEMU_CAPS_SET_ACTION (RHEL-242546)
- qemuProcessSetupLifecycleActions: Prepare to handle other actions (RHEL-242546)
- qemuDomainModifyLifecycleActionLive: Prepare to handle other actions (RHEL-242546)
- processGuestPanicEvent: Don't pass panic action via parameter (RHEL-242546)
- conf: Use proper enum types for 'onReboot', 'onPoweroff', 'onCrash', and 'onLockFailure' (RHEL-242546)
- qemuMonitorGuestPanicEventInfoFormatMsg: Directly return message (RHEL-242546)
- qemuProcessGuestPanicEventInfo: Fold into only caller (RHEL-242546)
- qemu: processGuestPanicEvent: Split individual steps under separate conditions (RHEL-242546)
- Add support for keeping VM running when panic notifier is used (RHEL-242546)
- qemu: Fix proper ordering of 'virtlockd' shutdown (RHEL-180876)
- Add guest device info to virDomainGetGuestInfo (RHEL-243300)
- qemu_agent: Introduce guest-get-devices (RHEL-243300)
- qemuagenttest: Introduce GetGuestDeviceInfo test case (RHEL-243300)
- qemu: Implement device info for virDomainGetGuestInfo() API (RHEL-243300)
- virsh: Add support for VIR_DOMAIN_GUEST_INFO_DEVICES (RHEL-243300)

Resolves: RHEL-180876, RHEL-242546, RHEL-243300
2026-08-19 15:04:03 +02:00

63 lines
2.1 KiB
Diff

From 94b9bec5bb85bc828e732e7c88c209b86573c4ab Mon Sep 17 00:00:00 2001
Message-ID: <94b9bec5bb85bc828e732e7c88c209b86573c4ab.1787144643.git.jdenemar@redhat.com>
From: Peter Krempa <pkrempa@redhat.com>
Date: Tue, 21 Jul 2026 14:55:38 +0200
Subject: [PATCH] qemuProcessGuestPanicEventInfo: Fold into only caller
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Move the code directly to the only place that calls this function.
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
(cherry picked from commit bf4ace1bca464fe8432c2eb08f5261d6f9bdaf29)
https://redhat.atlassian.net/browse/RHEL-242546
---
src/qemu/qemu_driver.c | 22 +++++++---------------
1 file changed, 7 insertions(+), 15 deletions(-)
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index ddd6e8f7ac..3fd1215006 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -3503,19 +3503,6 @@ doCoreDumpToAutoDumpPath(virQEMUDriver *driver,
}
-static void
-qemuProcessGuestPanicEventInfo(virQEMUDriver *driver,
- virDomainObj *vm,
- qemuMonitorEventPanicInfo *info)
-{
- g_autofree char *msg = qemuMonitorGuestPanicEventInfoFormatMsg(info);
- g_autofree char *timestamp = virTimeStringNow();
-
- if (msg && timestamp)
- qemuDomainLogAppendMessage(driver, vm, "%s: panic %s\n", timestamp, msg);
-}
-
-
static void
processGuestPanicEvent(virQEMUDriver *driver,
virDomainObj *vm,
@@ -3536,8 +3523,13 @@ processGuestPanicEvent(virQEMUDriver *driver,
goto endjob;
}
- if (info)
- qemuProcessGuestPanicEventInfo(driver, vm, info);
+ if (info) {
+ g_autofree char *msg = qemuMonitorGuestPanicEventInfoFormatMsg(info);
+ g_autofree char *timestamp = virTimeStringNow();
+
+ if (msg && timestamp)
+ qemuDomainLogAppendMessage(driver, vm, "%s: panic %s\n", timestamp, msg);
+ }
virDomainObjSetState(vm, VIR_DOMAIN_CRASHED, VIR_DOMAIN_CRASHED_PANICKED);
--
2.55.0