From: Claudio Imbrenda <imbrenda@linux.ibm.com>
To: Janosch Frank <frankja@linux.ibm.com>
Cc: kvm@vger.kernel.org, linux-s390@vger.kernel.org,
david@redhat.com, thuth@redhat.com, cohuck@redhat.com
Subject: Re: [kvm-unit-tests PATCH 5/5] lib: s390x: Print if a pgm happened while in SIE
Date: Fri, 23 Jul 2021 19:25:29 +0200 [thread overview]
Message-ID: <20210723192529.3dcca78b@p-imbrenda> (raw)
In-Reply-To: <20210629133322.19193-6-frankja@linux.ibm.com>
On Tue, 29 Jun 2021 13:33:22 +0000
Janosch Frank <frankja@linux.ibm.com> wrote:
> For debugging it helps if you know if the PGM happened while being in
> SIE or not.
>
> Signed-off-by: Janosch Frank <frankja@linux.ibm.com>
Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
I agree with Conny regarding the style, unless you want to extend the
SIE printf to provide more information (maybe about the guest?)
> ---
> lib/s390x/interrupt.c | 17 ++++++++++++++---
> 1 file changed, 14 insertions(+), 3 deletions(-)
>
> diff --git a/lib/s390x/interrupt.c b/lib/s390x/interrupt.c
> index b627942..76015b1 100644
> --- a/lib/s390x/interrupt.c
> +++ b/lib/s390x/interrupt.c
> @@ -141,10 +141,21 @@ static void print_int_regs(struct
> stack_frame_int *stack) static void print_pgm_info(struct
> stack_frame_int *stack)
> {
> + bool in_sie;
> +
> + in_sie = (lc->pgm_old_psw.addr >= (uintptr_t)sie_entry &&
> + lc->pgm_old_psw.addr <= (uintptr_t)sie_exit);
> +
> printf("\n");
> - printf("Unexpected program interrupt: %d on cpu %d at %#lx,
> ilen %d\n",
> - lc->pgm_int_code, stap(), lc->pgm_old_psw.addr,
> - lc->pgm_int_id);
> + if (!in_sie)
> + printf("Unexpected program interrupt: %d on cpu %d
> at %#lx, ilen %d\n",
> + lc->pgm_int_code, stap(),
> lc->pgm_old_psw.addr,
> + lc->pgm_int_id);
> + else
> + printf("Unexpected program interrupt in SIE: %d on
> cpu %d at %#lx, ilen %d\n",
> + lc->pgm_int_code, stap(),
> lc->pgm_old_psw.addr,
> + lc->pgm_int_id);
> +
> print_int_regs(stack);
> dump_stack();
> report_summary();
prev parent reply other threads:[~2021-07-23 17:25 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-29 13:33 [kvm-unit-tests PATCH 0/5] s390x: sie and uv cleanups Janosch Frank
2021-06-29 13:33 ` [kvm-unit-tests PATCH 1/5] s390x: sie: Add missing includes Janosch Frank
2021-06-30 8:59 ` Cornelia Huck
2021-07-04 7:47 ` Thomas Huth
2021-07-23 17:10 ` Claudio Imbrenda
2021-06-29 13:33 ` [kvm-unit-tests PATCH 2/5] s390x: sie: Fix sie.h integer types Janosch Frank
2021-06-30 9:00 ` Cornelia Huck
2021-07-04 7:45 ` Thomas Huth
2021-07-23 17:10 ` Claudio Imbrenda
2021-06-29 13:33 ` [kvm-unit-tests PATCH 3/5] lib: s390x: uv: Int type cleanup Janosch Frank
2021-06-30 9:03 ` Cornelia Huck
2021-07-04 7:51 ` Thomas Huth
2021-07-05 9:33 ` Janosch Frank
2021-07-05 9:41 ` Thomas Huth
2021-07-23 17:15 ` Claudio Imbrenda
2021-06-29 13:33 ` [kvm-unit-tests PATCH 4/5] lib: s390x: uv: Add offset comments to uv_query and extend it Janosch Frank
2021-06-30 9:06 ` Cornelia Huck
2021-06-30 9:43 ` Janosch Frank
2021-07-23 17:22 ` Claudio Imbrenda
2021-06-29 13:33 ` [kvm-unit-tests PATCH 5/5] lib: s390x: Print if a pgm happened while in SIE Janosch Frank
2021-06-30 9:12 ` Cornelia Huck
2021-07-23 17:25 ` Claudio Imbrenda [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210723192529.3dcca78b@p-imbrenda \
--to=imbrenda@linux.ibm.com \
--cc=cohuck@redhat.com \
--cc=david@redhat.com \
--cc=frankja@linux.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox