diff options
author | Jason J. Herne | 2015-06-26 20:07:21 +0200 |
---|---|---|
committer | Cornelia Huck | 2015-09-03 12:17:54 +0200 |
commit | a4538a5cc57dd493ed1545be98fa0ead0d391b8a (patch) | |
tree | 34fa8c60ec4961c8e415b262d6f0b3a0d60b1cae /hw/s390x/s390-skeys.c | |
parent | s390x: Dump storage keys qmp command (diff) | |
download | qemu-a4538a5cc57dd493ed1545be98fa0ead0d391b8a.tar.gz qemu-a4538a5cc57dd493ed1545be98fa0ead0d391b8a.tar.xz qemu-a4538a5cc57dd493ed1545be98fa0ead0d391b8a.zip |
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/s390-skeys.c')
-rw-r--r-- | hw/s390x/s390-skeys.c | 12 |
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(); |