[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [qemu-s390x] [PATCH v6] s390x/cpu: expose the guest crash informatio
From: |
Christian Borntraeger |
Subject: |
Re: [qemu-s390x] [PATCH v6] s390x/cpu: expose the guest crash information |
Date: |
Wed, 7 Feb 2018 19:44:31 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 |
On 02/07/2018 01:38 PM, Christian Borntraeger wrote:
> --- a/vl.c
> +++ b/vl.c
> @@ -1738,7 +1738,7 @@ void qemu_system_reset(ShutdownCause reason)
>
> void qemu_system_guest_panicked(GuestPanicInformation *info)
> {
> - qemu_log_mask(LOG_GUEST_ERROR, "Guest crashed\n");
> + qemu_log_mask(LOG_GUEST_ERROR, "Guest crashed");
>
> if (current_cpu) {
> current_cpu->crash_occurred = true;
> @@ -1754,13 +1754,21 @@ void qemu_system_guest_panicked(GuestPanicInformation
> *info)
>
> if (info) {
> if (info->type == GUEST_PANIC_INFORMATION_TYPE_HYPER_V) {
> - qemu_log_mask(LOG_GUEST_ERROR, "HV crash parameters: (%#"PRIx64
> + qemu_log_mask(LOG_GUEST_ERROR, "\nHV crash parameters: (%#"PRIx64
> " %#"PRIx64" %#"PRIx64" %#"PRIx64" %#"PRIx64")\n",
> info->u.hyper_v.arg1,
> info->u.hyper_v.arg2,
> info->u.hyper_v.arg3,
> info->u.hyper_v.arg4,
> info->u.hyper_v.arg5);
> + } else if (info->type == GUEST_PANIC_INFORMATION_TYPE_S390) {
> + qemu_log_mask(LOG_GUEST_ERROR, " on cpu %d: %s\n"
> + "PSW: 0x%016" PRIx64 " 0x%016" PRIx64"\n",
> + info->u.s390.core,
> + qapi_enum_lookup(&S390CrashReason_lookup,
> + info->u.s390.reason),
Question for the qapi people. Would you prefer S390CrashReason_str instead?
> + info->u.s390.psw_mask,
> + info->u.s390.psw_addr);
> }
> qapi_free_GuestPanicInformation(info);
> }
>