Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 23 Mar 2018 00:40:08 +0000 (UTC)
From:      Justin Hibbits <jhibbits@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r331401 - head/sys/powerpc/powerpc
Message-ID:  <201803230040.w2N0e8Fs021387@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhibbits
Date: Fri Mar 23 00:40:08 2018
New Revision: 331401
URL: https://svnweb.freebsd.org/changeset/base/331401

Log:
  Debug interrupts aren't instruction traps
  
  The EXC_DEBUG type is akin to the MPC74xx "Instruction Breakpoint" trap.
  Don't treat it as a trap instruction.

Modified:
  head/sys/powerpc/powerpc/trap.c

Modified: head/sys/powerpc/powerpc/trap.c
==============================================================================
--- head/sys/powerpc/powerpc/trap.c	Fri Mar 23 00:20:42 2018	(r331400)
+++ head/sys/powerpc/powerpc/trap.c	Fri Mar 23 00:40:08 2018	(r331401)
@@ -189,7 +189,7 @@ frame_is_trap_inst(struct trapframe *frame)
 #ifdef AIM
 	return (frame->exc == EXC_PGM && frame->srr1 & EXC_PGM_TRAP);
 #else
-	return (frame->exc == EXC_DEBUG || frame->cpu.booke.esr & ESR_PTR);
+	return ((frame->cpu.booke.esr & ESR_PTR) != 0);
 #endif
 }
 
@@ -895,6 +895,7 @@ db_trap_glue(struct trapframe *frame)
 	    && (frame->exc == EXC_TRC || frame->exc == EXC_RUNMODETRC
 	    	|| frame_is_trap_inst(frame)
 		|| frame->exc == EXC_BPT
+		|| frame->exc == EXC_DEBUG
 		|| frame->exc == EXC_DSI)) {
 		int type = frame->exc;
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201803230040.w2N0e8Fs021387>