On 5/15/25 1:45 AM, Daniel P. Berrangé wrote:
diff --git a/stubs/monitor-i386-rtc.c b/stubs/monitor-i386-rtc.c
new file mode 100644
index 00000000000..e78757b24f2
--- /dev/null
+++ b/stubs/monitor-i386-rtc.c
@@ -0,0 +1,14 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#include "qemu/osdep.h"
+#include "qapi/error.h"
+#include "qapi/qapi-commands-misc-i386.h"
+
+void qmp_rtc_reset_reinjection(Error **errp)
+{
+ /*
+ * Use of this command is only applicable for x86 machines with an RTC,
+ * and on other machines will silently return without performing any
+ * action.
+ */
+}
Based on Markus' feedback, I think we need to report an error here
rather than silently ignore the code.
Sorry, I missed that part.
I changed the patch and updated the commit message:
+void qmp_rtc_reset_reinjection(Error **errp)
+{
+ error_setg(errp,
+ "rtc-reset-injection is only available for x86 machines
with RTC");
+}
Thanks,
Pierrick