From owner-svn-src-head@freebsd.org Thu Nov 10 21:34:57 2016 Return-Path: Delivered-To: svn-src-head@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 9E38AC3AFD7; Thu, 10 Nov 2016 21:34:57 +0000 (UTC) (envelope-from rb743@hermes.cam.ac.uk) Received: from ppsw-30.csi.cam.ac.uk (ppsw-30.csi.cam.ac.uk [131.111.8.130]) by mx1.freebsd.org (Postfix) with ESMTP id 5BF499F4; Thu, 10 Nov 2016 21:34:56 +0000 (UTC) (envelope-from rb743@hermes.cam.ac.uk) X-Cam-AntiVirus: no malware found X-Cam-ScannerInfo: http://www.cam.ac.uk/cs/email/scanner/ Received: from sc1.bsdpad.com ([163.172.212.18]:37801) by ppsw-30.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.156]:587) with esmtpsa (LOGIN:rb743) (TLSv1:ECDHE-RSA-AES256-SHA:256) id 1c4wzo-000bhA-d4 (Exim 4.86_36-e07b163) (return-path ); Thu, 10 Nov 2016 21:34:56 +0000 Date: Thu, 10 Nov 2016 21:34:12 +0000 From: Ruslan Bukin To: Adrian Chadd Cc: "freebsd-mips@freebsd.org" , Bryan Drewery , Ruslan Bukin , "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Subject: Re: svn commit: r308130 - in head: . gnu/lib/libgcc gnu/usr.bin/binutils gnu/usr.bin/binutils/ld gnu/usr.bin/binutils/libbfd gnu/usr.bin/cc gnu/usr.bin/gdb gnu/usr.bin/gdb/libgdb lib/libc lib/libc/mips... Message-ID: <20161110213412.GA21672@bsdpad.com> References: <201610311533.u9VFXw2x053156@repo.freebsd.org> <128f2edc-eced-dc8b-72b4-267e1d26bd48@FreeBSD.org> <20161103201059.GA2104@bsdpad.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.1 (2016-04-27) Sender: "R. Bukin" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 10 Nov 2016 21:34:57 -0000 Hi, Adrian, thanks, but I have lack of ideas yet. I just tested this on Ingenic X1000 (mips.mipsel) and it works fine, as well as mips.mipselhf (this hardware has FPU). I have no hardware without FPU. What exactly COP_1 bits you have commented to get rid of COP1_UNUSABLE? Ruslan On Thu, Nov 10, 2016 at 01:09:20PM -0800, Adrian Chadd wrote: > ok, so there are two problems with mips now. > > * COP1_UNUSABLE - which is now being logged, and we were likely > triggering it before. The problem: we always turned it on. If I > comment out flipping on the COP1 bits in the .S files, those > exceptions go away. > > * Page faults, but that may be me with an older userland: > > BAD_PAGE_FAULT: pid 1 tid 100001 (init), uid 0: pc 0x404237c0 got a > read fault (type 0x2) at 0x8 > Trapframe Register Dump: > zero: 0 at: 0xffffffffffffffe0 v0: 0x404471b8 v1: > 0xffffffffffffffff > a0: 0x404471b8 a1: 0x7ffeea50 a2: 0x16c a3: 0 > t0: 0 t1: 0 t2: 0 t3: 0x70000011 > t4: 0x11 t5: 0x70000013 t6: 0x3 t7: 0 > t8: 0 t9: 0x4041c940 s0: 0 s1: 0x40417000 > s2: 0x7fffeee0 s3: 0xffffffffffffffff s4: 0xc s5: 0x40427000 > s6: 0x7fffeecc s7: 0x7ffeea50 k0: 0 k1: 0 > gp: 0x4044e630 sp: 0x7ffee838 s8: 0x2 ra: 0x404224d4 > sr: 0xfc13 mullo: 0 mulhi: 0 badvaddr: 0x8 > cause: 0x8 pc: 0x404237c0 > Page table info for pc address 0x404237c0: pde = 0x809aa000, pte = 0xa001ba9a > Dumping 4 words starting at pc address 0x404237c0: > 8e100008 1600fff1 8f828070 100000a3 > > > > -adrian > > > On 10 November 2016 at 12:49, Adrian Chadd wrote: > > hi, > > > > This fails to boot on actual mips24k hardware, no hardfloat: > > > > COP1_UNUSABLE: pid 1 tid 100001 (init), uid 0: pc 0x404237c0 ra 0x404224d4 > > Trapframe Register Dump: > > zero: 0 at: 0xffffffffffffffe0 v0: 0x404471b8 v1: > > 0xffffffffffffffff > > > > .. lots of that the moment we boot userland. > > > > > > > > -adrian > > > > > > On 3 November 2016 at 13:10, Ruslan Bukin wrote: > >> On Thu, Nov 03, 2016 at 12:39:48PM -0700, Bryan Drewery wrote: > >>> On 10/31/16 8:33 AM, Ruslan Bukin wrote: > >>> > Modified: head/share/mk/bsd.cpu.mk > >>> > ============================================================================== > >>> > --- head/share/mk/bsd.cpu.mk Mon Oct 31 15:11:55 2016 (r308129) > >>> > +++ head/share/mk/bsd.cpu.mk Mon Oct 31 15:33:58 2016 (r308130) > >>> > @@ -303,6 +303,9 @@ MACHINE_CPU = v9 ultrasparc ultrasparc3 > >>> > > >>> > .if ${MACHINE_CPUARCH} == "mips" > >>> > CFLAGS += -G0 > >>> > +.if ${TARGET_ARCH:Mmips*hf} > >>> > >>> TARGET_ARCH is not valid here. This broke building ports. Fixed in > >>> r308262. > >>> > >> > >> Thank you! > >> > >> Ruslan > >>