From owner-freebsd-smp Tue Apr 22 14:39:25 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id OAA07705 for smp-outgoing; Tue, 22 Apr 1997 14:39:25 -0700 (PDT) Received: from phaeton.artisoft.com (phaeton.Artisoft.COM [198.17.250.50]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id OAA07700 for ; Tue, 22 Apr 1997 14:39:22 -0700 (PDT) Received: (from terry@localhost) by phaeton.artisoft.com (8.6.11/8.6.9) id OAA27462; Tue, 22 Apr 1997 14:36:14 -0700 From: Terry Lambert Message-Id: <199704222136.OAA27462@phaeton.artisoft.com> Subject: Re: Possible typo in sys sources ? To: smp@csn.net (Steve Passe) Date: Tue, 22 Apr 1997 14:36:14 -0700 (MST) Cc: phk@dk.tfs.com, ady@earthling.net, smp@freebsd.org In-Reply-To: <199704221818.MAA16673@Ilsa.StevesCafe.com> from "Steve Passe" at Apr 22, 97 12:18:30 pm X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-smp@freebsd.org X-Loop: FreeBSD.org Precedence: bulk > > > - edited ../../kern/init_main.c and in line 180 changed from "*sipp = > > >*xitp" to "*sipp = *xipp" (it's in a bubble sort) > > > > We have qsort() in the kernel, replace it wholesale... > > for the record, this has nothing to do with the SMP source tree, the bubble > sort is in the main 3.0-current tree also. Also for the record: 1) It's not a typo 2) You can replace it with qsort if you want to provide the compare function, but it's boot code, and is only ever executed once, so it's kind of a waste of time. 3) I'm not wure if a qsort would like to be unindexed; if not, it may not like the dirty way the original linkerset data is being rearranged in memory without benefit of a real array of pointers. Regards, Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.