From owner-freebsd-ppc@freebsd.org Sat May 20 05:34:16 2017 Return-Path: Delivered-To: freebsd-ppc@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id BB357D75107 for ; Sat, 20 May 2017 05:34:16 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: from asp.reflexion.net (outbound-mail-210-11.reflexion.net [208.70.210.11]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6E7551285 for ; Sat, 20 May 2017 05:34:15 +0000 (UTC) (envelope-from markmi@dsl-only.net) Received: (qmail 21715 invoked from network); 20 May 2017 05:34:14 -0000 Received: from unknown (HELO mail-cs-01.app.dca.reflexion.local) (10.81.19.1) by 0 (rfx-qmail) with SMTP; 20 May 2017 05:34:14 -0000 Received: by mail-cs-01.app.dca.reflexion.local (Reflexion email security v8.40.0) with SMTP; Sat, 20 May 2017 01:34:14 -0400 (EDT) Received: (qmail 17158 invoked from network); 20 May 2017 05:34:14 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (AES256-SHA encrypted) SMTP; 20 May 2017 05:34:14 -0000 Received: from [192.168.1.106] (c-76-115-7-162.hsd1.or.comcast.net [76.115.7.162]) by iron2.pdx.net (Postfix) with ESMTPSA id E29B5EC8FD9; Fri, 19 May 2017 22:34:13 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: FYI: powerpc EXC_LAST==0x2f00 vs. EXC_DEBUG ==0x2f10 and such? From: Mark Millard In-Reply-To: <44ACFC7B-445A-4648-B387-E31021A8D363@dsl-only.net> Date: Fri, 19 May 2017 22:34:13 -0700 Cc: FreeBSD PowerPC ML Content-Transfer-Encoding: quoted-printable Message-Id: <9A2218D5-4795-4A83-A257-61CA3EDBC776@dsl-only.net> References: <0BC58DBC-AC9B-46F8-8F3A-1AEB90622BC4@dsl-only.net> <44ACFC7B-445A-4648-B387-E31021A8D363@dsl-only.net> To: Justin Hibbits X-Mailer: Apple Mail (2.3273) X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 May 2017 05:34:16 -0000 On 2017-May-19, at 10:30 PM, Mark Millard wrote: > On 2017-May-19, at 10:24 PM, Justin Hibbits = wrote: >=20 > On Tuesday, May 16, 2017, Mark Millard wrote: >> . . .=46rom /usr/src/sys/powerpc/include/trap.h : >>=20 >> #define EXC_DEBUG 0x2f10 /* Debug trap */ >> #define EXC_VECAST_E 0x2f20 /* Altivec Assist (Book-E) */ >>=20 >> #define EXC_LAST 0x2f00 /* Last possible exception = vector */ >>=20 >> #define EXC_AST 0x3000 /* Fake AST vector */ >>=20 >> /* Trap was in user mode */ >> #define EXC_USER 0x10000 >>=20 >> And also: >>=20 >> /usr/src/sys/powerpc/ofw/ofw_machdep.c:char = save_trap_init[0x2f00]; /* EXC_LAST */ >> /usr/src/sys/powerpc/ofw/ofw_machdep.c:char = save_trap_of[0x2f00]; /* EXC_LAST */ >>=20 >> /usr/src/sys/powerpc/include/profile.h:#define __PROFILE_VECTOR_TOP = (EXC_LAST + 0x100) >>=20 >> These makes it look like EXC_LAST and some literal >> 0x2f00's might be insufficient for some contexts. >>=20 >> Nope EXC_LAST is correct as-is. It's the last possible exception = vector for AIM, as that uses physical pages at those addresses for the = exception vectors. Anything above EXC_LAST is an artificial exception. = Now, it does look odd, so I should move the EXC_DEBUG and EXC_VECAST_E = down below the EXC_LAST for sorting purposes. >=20 > Thanks for checking. >=20 > One other point: >=20 > save_trap_init[0x2f00] does not include 0x2500 > save_trap_of[0x2f00] does not include 0x2500 I meant "does not include 0x2f00" in both places. [It is a day for taking things slowly. . .] > But. . . >=20 >> #define EXC_LAST 0x2f00 /* Last possible exception = vector */ >=20 > indicates that 0x2500 is included. Is it actually > the count/bound and not the last possible? Same here: 0x2f00, not 0x2500. =3D=3D=3D Mark Millard markmi at dsl-only.net