From owner-svn-src-head@FreeBSD.ORG Thu Jun 27 18:54:19 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 1AECFFF6; Thu, 27 Jun 2013 18:54:19 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id 0CBF81941; Thu, 27 Jun 2013 18:54:19 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r5RIsIrv041719; Thu, 27 Jun 2013 18:54:18 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r5RIsI0H041716; Thu, 27 Jun 2013 18:54:18 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201306271854.r5RIsI0H041716@svn.freebsd.org> From: Andrew Turner Date: Thu, 27 Jun 2013 18:54:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r252311 - in head/sys/arm: arm include X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Jun 2013 18:54:19 -0000 Author: andrew Date: Thu Jun 27 18:54:18 2013 New Revision: 252311 URL: http://svnweb.freebsd.org/changeset/base/252311 Log: Add UNWINDSVCFRAME to provide the unwind pseudo ops to allow us to unwind past a trapframe. Use this macro in exception_exit as it is the function the unwinder enters as the functions that store the frame setting lr to point to it. Modified: head/sys/arm/arm/exception.S head/sys/arm/include/asmacros.h Modified: head/sys/arm/arm/exception.S ============================================================================== --- head/sys/arm/arm/exception.S Thu Jun 27 18:28:45 2013 (r252310) +++ head/sys/arm/arm/exception.S Thu Jun 27 18:54:18 2013 (r252311) @@ -206,7 +206,7 @@ END(address_exception_entry) */ ASENTRY_NP(exception_exit) - STOP_UNWINDING + UNWINDSVCFRAME DO_AST PULLFRAMEFROMSVCANDEXIT END(exception_exit) Modified: head/sys/arm/include/asmacros.h ============================================================================== --- head/sys/arm/include/asmacros.h Thu Jun 27 18:28:45 2013 (r252310) +++ head/sys/arm/include/asmacros.h Thu Jun 27 18:54:18 2013 (r252311) @@ -206,7 +206,16 @@ mov r0, r0; /* NOP for previous instruction */ \ add sp, sp, #(4*15); /* Adjust the stack pointer */ \ ldmia sp, {sp, lr, pc}^ /* Restore lr and exit */ -#endif +#endif +#if defined(__ARM_EABI__) +#define UNWINDSVCFRAME \ + .save {r13-r15}; /* Restore sp, lr, pc */ \ + .pad #(2*4); /* Skip user sp and lr */ \ + .save {r0-r12}; /* Restore r0-r12 */ \ + .pad #(4) /* Skip spsr */ +#else +#define UNWINDSVCFRAME +#endif #define DATA(name) \ .data ; \