From owner-freebsd-amd64@FreeBSD.ORG Mon Dec 1 19:58:21 2003 Return-Path: Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D609316A4CE for ; Mon, 1 Dec 2003 19:58:21 -0800 (PST) Received: from dragon.nuxi.com (trang.nuxi.com [66.93.134.19]) by mx1.FreeBSD.org (Postfix) with ESMTP id B9A8843F3F for ; Mon, 1 Dec 2003 19:58:20 -0800 (PST) (envelope-from obrien@dragon.nuxi.com) Received: from dragon.nuxi.com (obrien@localhost [127.0.0.1]) by dragon.nuxi.com (8.12.10/8.12.9) with ESMTP id hB23wDRm014232; Mon, 1 Dec 2003 19:58:13 -0800 (PST) (envelope-from obrien@dragon.nuxi.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.12.10/8.12.10/Submit) id hB23wCrv014231; Mon, 1 Dec 2003 19:58:12 -0800 (PST) (envelope-from obrien) Date: Mon, 1 Dec 2003 19:58:12 -0800 From: "David O'Brien" To: Adriaan de Groot Message-ID: <20031202035812.GA14209@dragon.nuxi.com> References: <20031201045433.GA42765@dragon.nuxi.com> <20031201102129.GA2093@dragon.nuxi.com> <200312011928.20170.adridg@cs.kun.nl> <200312012353.37979.adridg@cs.kun.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200312012353.37979.adridg@cs.kun.nl> User-Agent: Mutt/1.4.1i X-Operating-System: FreeBSD 5.2-BETA Organization: The NUXI BSD Group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 cc: freebsd-amd64@freebsd.org Subject: Re: 5.2-beta panics after copyright X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: obrien@freebsd.org List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Dec 2003 03:58:21 -0000 On Mon, Dec 01, 2003 at 11:53:37PM +0100, Adriaan de Groot wrote: > On Yaum al-Ithnain 06 Shawwal 1424 19:28, Adriaan de Groot wrote: > > Let's see what an even newer cvsup yields (dec 1 18:30 UTC) .. > > OK, with sources from this evening I have: > > 1) with "option SMP" it panics right after the copyright message. I compiled > with the kernel debugger and all the debugging stuff this time, it tells me: > mtx_lock of spin mux (null) at uma_core.c:1388 > (paraphrased as usual, the numbers are exact). Verified on my Solo9. This patch fixes it: Index: amd64/amd64/mp_machdep.c =================================================================== RCS file: /home/ncvs/src/sys/amd64/amd64/mp_machdep.c,v retrieving revision 1.229 diff -u -r1.229 mp_machdep.c --- amd64/amd64/mp_machdep.c 30 Nov 2003 22:20:40 -0000 1.229 +++ amd64/amd64/mp_machdep.c 2 Dec 2003 01:53:08 -0000 @@ -199,7 +199,7 @@ KASSERT(mp_maxid == 0, ("%s: mp_ncpus is zero, but mp_maxid is not", __func__)); else if (mp_ncpus == 1) - mp_maxid = 0; + mp_maxid = 1; else KASSERT(mp_maxid >= mp_ncpus - 1, ("%s: counters out of sync: max %d, count %d", __func__, @@ -232,7 +232,7 @@ * One CPU was found, so this must be a UP system with * an I/O APIC. */ - mp_maxid = 0; + mp_maxid = 1; return (0); }