From owner-freebsd-current@FreeBSD.ORG Fri Oct 21 21:35:42 2005 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D3ADB16A41F; Fri, 21 Oct 2005 21:35:42 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from mv.twc.weather.com (mv.twc.weather.com [65.212.71.225]) by mx1.FreeBSD.org (Postfix) with ESMTP id 614DD43D46; Fri, 21 Oct 2005 21:35:42 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from [10.50.41.234] (Not Verified[10.50.41.234]) by mv.twc.weather.com with NetIQ MailMarshal (v6, 0, 3, 8) id ; Fri, 21 Oct 2005 17:52:15 -0400 From: John Baldwin To: freebsd-current@freebsd.org Date: Fri, 21 Oct 2005 17:37:00 -0400 User-Agent: KMail/1.8.2 References: <20051021210017.98D6716A420@hub.freebsd.org> In-Reply-To: <20051021210017.98D6716A420@hub.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200510211737.01988.jhb@freebsd.org> Cc: Maxim Maximov , Bill Paul Subject: Re: boot panic (NDIS, SCHED_ULE?) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Oct 2005 21:35:42 -0000 On Friday 21 October 2005 05:00 pm, Bill Paul wrote: > > Maxim Maximov wrote: > > > Maxim Maximov wrote: > > >> Hi. > > >> > > >> Got boot time panic on fresh CURRENT. > > >> NDIS hardware: > > >> > > >> ndis0: mem 0xfeaf8000-0xfeaf9fff irq 17 > > >> at device 2.0 on pci2 > > >> ndis0: NDIS API version: 5.0 > > >> ndis0: Ethernet address: 00:0e:a6:c2:00:e4 > > Oh for crap's sake. > > Some days I really, _REALLY_ hate FreeBSD. > > I need to insure that DPC thread 0 runs on CPU 0, and DPC thread 1 > runs on CPU 1, and so on. There are supposed to be separate DPC > threads for each CPU. Unfortunately, you can't specify a CPU > affinity when you launch the thread, and obviously you can't > do it during the device probe phase during bootstrap since only > CPU 0 is running. > > I really don't have the right solution for this right now. What > you _SHOULD_ do is stop loading your NDIS driver during boot. Instead, > take it out of /boot/loader.conf and load it with a boot script > after the system has gone multiuser. If you do it then, both CPUs > will be running. > > I'm not sure of the correct solution for this problem. I have to > think about it. In the meantime, just wait to load ndis.ko, if_ndis.ko > and your_driver.ko after bootstrap. Perhaps have the kthreads for cpus other than 0 sleep in their main before calling sched_bind() and have a SI_SUB_SMP, SI_ORDER_MIDDLE SYSINIT in the module to wake them up so they can do their sched_bind()s. Someday I'd like to have all the CPUs up and running for the device probe. :( -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org