aboutsummaryrefslogtreecommitdiff
path: root/hw/s390x
diff options
context:
space:
mode:
authorJason J. Herne <jjherne@linux.vnet.ibm.com>2015-06-26 14:07:21 -0400
committerCornelia Huck <cornelia.huck@de.ibm.com>2015-09-03 12:17:54 +0200
commita4538a5cc57dd493ed1545be98fa0ead0d391b8a (patch)
tree34fa8c60ec4961c8e415b262d6f0b3a0d60b1cae /hw/s390x
parent7ee0c3e33a0f8664c529ce621ea83326817fc14a (diff)
s390x: Dump-skeys hmp support
Add dump-skeys command to the human monitor. Reviewed-by: Thomas Huth <thuth@linux.vnet.ibm.com> Reviewed-by: David Hildenbrand <dahi@linux.vnet.ibm.com> Signed-off-by: Jason J. Herne <jjherne@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'hw/s390x')
-rw-r--r--hw/s390x/s390-skeys.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/hw/s390x/s390-skeys.c b/hw/s390x/s390-skeys.c
index a1d10a9897..98a6938523 100644
--- a/hw/s390x/s390-skeys.c
+++ b/hw/s390x/s390-skeys.c
@@ -66,6 +66,18 @@ static void write_keys(QEMUFile *f, uint8_t *keys, uint64_t startgfn,
}
}
+void hmp_dump_skeys(Monitor *mon, const QDict *qdict)
+{
+ const char *filename = qdict_get_str(qdict, "filename");
+ Error *err = NULL;
+
+ qmp_dump_skeys(filename, &err);
+ if (err) {
+ monitor_printf(mon, "%s\n", error_get_pretty(err));
+ error_free(err);
+ }
+}
+
void qmp_dump_skeys(const char *filename, Error **errp)
{
S390SKeysState *ss = s390_get_skeys_device();