kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only
@ 2016-03-30 15:06 Laurent Vivier
  2016-03-30 15:07 ` Thomas Huth
  2016-03-30 16:12 ` Paolo Bonzini
  0 siblings, 2 replies; 3+ messages in thread
From: Laurent Vivier @ 2016-03-30 15:06 UTC (permalink / raw)
  To: kvm, kvm-ppc; +Cc: drjones, thuth, dgibson, pbonzini, Laurent Vivier

In the emulator test, the illegal exception is displayed
only in verbose mode, do the same thing for the alignment
exception.

Signed-off-by: Laurent Vivier <lvivier@redhat.com>
---
 powerpc/emulator.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/powerpc/emulator.c b/powerpc/emulator.c
index ef27f15..3696d83 100644
--- a/powerpc/emulator.c
+++ b/powerpc/emulator.c
@@ -35,8 +35,10 @@ static void alignment_handler(struct pt_regs *regs, void *opaque)
 {
 	int *data = opaque;
 
-	printf("Detected alignment exception 0x%016lx: %08x\n",
-	       regs->nip, *(uint32_t*)regs->nip);
+	if (verbose) {
+		printf("Detected alignment exception 0x%016lx: %08x\n",
+		       regs->nip, *(uint32_t*)regs->nip);
+	}
 
 	*data = 1;
 
-- 
2.5.5


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

* Re: [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only
  2016-03-30 15:06 [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only Laurent Vivier
@ 2016-03-30 15:07 ` Thomas Huth
  2016-03-30 16:12 ` Paolo Bonzini
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Huth @ 2016-03-30 15:07 UTC (permalink / raw)
  To: Laurent Vivier, kvm, kvm-ppc; +Cc: drjones, dgibson, pbonzini

On 30.03.2016 17:06, Laurent Vivier wrote:
> In the emulator test, the illegal exception is displayed
> only in verbose mode, do the same thing for the alignment
> exception.
> 
> Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> ---
>  powerpc/emulator.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/powerpc/emulator.c b/powerpc/emulator.c
> index ef27f15..3696d83 100644
> --- a/powerpc/emulator.c
> +++ b/powerpc/emulator.c
> @@ -35,8 +35,10 @@ static void alignment_handler(struct pt_regs *regs, void *opaque)
>  {
>  	int *data = opaque;
>  
> -	printf("Detected alignment exception 0x%016lx: %08x\n",
> -	       regs->nip, *(uint32_t*)regs->nip);
> +	if (verbose) {
> +		printf("Detected alignment exception 0x%016lx: %08x\n",
> +		       regs->nip, *(uint32_t*)regs->nip);
> +	}
>  
>  	*data = 1;
>  

Reviewed-by: Thomas Huth <thuth@redhat.com>


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

* Re: [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only
  2016-03-30 15:06 [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only Laurent Vivier
  2016-03-30 15:07 ` Thomas Huth
@ 2016-03-30 16:12 ` Paolo Bonzini
  1 sibling, 0 replies; 3+ messages in thread
From: Paolo Bonzini @ 2016-03-30 16:12 UTC (permalink / raw)
  To: Laurent Vivier, kvm, kvm-ppc; +Cc: drjones, thuth, dgibson



On 30/03/2016 17:06, Laurent Vivier wrote:
> In the emulator test, the illegal exception is displayed
> only in verbose mode, do the same thing for the alignment
> exception.
> 
> Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> ---
>  powerpc/emulator.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/powerpc/emulator.c b/powerpc/emulator.c
> index ef27f15..3696d83 100644
> --- a/powerpc/emulator.c
> +++ b/powerpc/emulator.c
> @@ -35,8 +35,10 @@ static void alignment_handler(struct pt_regs *regs, void *opaque)
>  {
>  	int *data = opaque;
>  
> -	printf("Detected alignment exception 0x%016lx: %08x\n",
> -	       regs->nip, *(uint32_t*)regs->nip);
> +	if (verbose) {
> +		printf("Detected alignment exception 0x%016lx: %08x\n",
> +		       regs->nip, *(uint32_t*)regs->nip);
> +	}
>  
>  	*data = 1;
>  
> 

Thanks, applying soon.

Paolo

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

end of thread, other threads:[~2016-03-30 16:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-30 15:06 [kvm-unit-tests PATCH]] powerpc: display alignment exception in verbose mode only Laurent Vivier
2016-03-30 15:07 ` Thomas Huth
2016-03-30 16:12 ` Paolo Bonzini

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