From owner-cvs-all@FreeBSD.ORG Sun Aug 8 00:28:07 2004 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 77C0F16A4CE; Sun, 8 Aug 2004 00:28:07 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6EFA643D1D; Sun, 8 Aug 2004 00:28:07 +0000 (GMT) (envelope-from marcel@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i780S70t082516; Sun, 8 Aug 2004 00:28:07 GMT (envelope-from marcel@repoman.freebsd.org) Received: (from marcel@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i780S7jd082515; Sun, 8 Aug 2004 00:28:07 GMT (envelope-from marcel) Message-Id: <200408080028.i780S7jd082515@repoman.freebsd.org> From: Marcel Moolenaar Date: Sun, 8 Aug 2004 00:28:07 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/ia64/ia64 machdep.c trap.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Aug 2004 00:28:07 -0000 marcel 2004-08-08 00:28:07 UTC FreeBSD src repository Modified files: sys/ia64/ia64 machdep.c trap.c Log: Implement single stepping when we leave the kernel through the EPC syscall path. The basic problem is that we cannot set the single stepping flag directly, because we don't leave the kernel via an interrupt return. So, we need another way to set the single stepping flag. The way we do this is by enabling the lower-privilege transfer trap, which gets raised when we drop the privilege level. However, since we're still running in kernel space (sec), we're not yet done. We clear the lower- privilege transfer trap, enable the taken-branch trap and continue exiting the kernel until we branch into user space. Given the current code, there's a total of two traps this way before we can raise SIGTRAP. Revision Changes Path 1.182 +22 -2 src/sys/ia64/ia64/machdep.c 1.103 +41 -2 src/sys/ia64/ia64/trap.c