qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 1/2] qapi/machine-s390x: add QAPI event SCLP_CPI_INFO_AVAILABLE
@ 2025-10-16 12:17 Shalini Chellathurai Saroja
  2025-10-16 12:17 ` [PATCH v3 2/2] tests/functional: add tests for SCLP event CPI Shalini Chellathurai Saroja
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Shalini Chellathurai Saroja @ 2025-10-16 12:17 UTC (permalink / raw)
  To: qemu-s390x mailing list, Thomas Huth
  Cc: Sebastian Mitterle, qemu-devel mailing list,
	Nina Schoetterl-Glausch, Hendrik Brueckner,
	Shalini Chellathurai Saroja, Michael Mueller

Add QAPI event SCLP_CPI_INFO_AVAILABLE to notify the availability
of Control-Program Identification data in QOM.

Signed-off-by: Shalini Chellathurai Saroja <shalini@linux.ibm.com>
Suggested-by: Thomas Huth <thuth@redhat.com>
---
 hw/s390x/sclpcpi.c      |  4 ++++
 qapi/machine-s390x.json | 21 +++++++++++++++++++++
 2 files changed, 25 insertions(+)

diff --git a/hw/s390x/sclpcpi.c b/hw/s390x/sclpcpi.c
index 7aa039d510..68fc1b809b 100644
--- a/hw/s390x/sclpcpi.c
+++ b/hw/s390x/sclpcpi.c
@@ -54,6 +54,7 @@
 #include "hw/s390x/event-facility.h"
 #include "hw/s390x/ebcdic.h"
 #include "qapi/qapi-visit-machine.h"
+#include "qapi/qapi-events-machine-s390x.h"
 #include "migration/vmstate.h"
 
 typedef struct Data {
@@ -106,6 +107,9 @@ static int write_event_data(SCLPEvent *event, EventBufferHeader *evt_buf_hdr)
     e->timestamp = qemu_clock_get_ns(QEMU_CLOCK_HOST);
 
     cpim->ebh.flags = SCLP_EVENT_BUFFER_ACCEPTED;
+
+    qapi_event_send_sclp_cpi_info_available();
+
     return SCLP_RC_NORMAL_COMPLETION;
 }
 
diff --git a/qapi/machine-s390x.json b/qapi/machine-s390x.json
index 966dbd61d2..8412668b67 100644
--- a/qapi/machine-s390x.json
+++ b/qapi/machine-s390x.json
@@ -119,3 +119,24 @@
 { 'command': 'query-s390x-cpu-polarization', 'returns': 'CpuPolarizationInfo',
   'features': [ 'unstable' ]
 }
+
+##
+# @SCLP_CPI_INFO_AVAILABLE:
+#
+# Emitted when the Control-Program Identification data is available
+# in the QOM tree.
+#
+# Features:
+#
+# @unstable: This event is experimental.
+#
+# Since: 10.2
+#
+# .. qmp-example::
+#
+#     <- { "event": "SCLP_CPI_INFO_AVAILABLE",
+#          "timestamp": { "seconds": 1401385907, "microseconds": 422329 } }
+##
+{ 'event': 'SCLP_CPI_INFO_AVAILABLE',
+  'features': [ 'unstable' ]
+}
-- 
2.49.0



^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2025-10-21 12:52 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-16 12:17 [PATCH v3 1/2] qapi/machine-s390x: add QAPI event SCLP_CPI_INFO_AVAILABLE Shalini Chellathurai Saroja
2025-10-16 12:17 ` [PATCH v3 2/2] tests/functional: add tests for SCLP event CPI Shalini Chellathurai Saroja
2025-10-20 16:36   ` Thomas Huth
2025-10-21 12:52   ` Hendrik Brueckner
2025-10-20 16:34 ` [PATCH v3 1/2] qapi/machine-s390x: add QAPI event SCLP_CPI_INFO_AVAILABLE Thomas Huth
2025-10-21 12:51 ` Hendrik Brueckner

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).