From owner-freebsd-current Fri Nov 22 10:47:50 2002 Delivered-To: freebsd-current@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 931) id 648F937B401; Fri, 22 Nov 2002 10:47:49 -0800 (PST) Date: Fri, 22 Nov 2002 10:47:49 -0800 From: Juli Mallett To: Maxime Henrion Cc: John Baldwin , freebsd-current@FreeBSD.org, Juli Mallett , Robert Watson Subject: Re: VM locking problem... And doscmd(8) Message-ID: <20021122104749.A34027@FreeBSD.org> References: <20021121185414.A83098@FreeBSD.org> <20021122171100.GE4067@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20021122171100.GE4067@elvis.mu.org>; from mux@freebsd.org on Fri, Nov 22, 2002 at 09:11:00AM -0800 Organisation: The FreeBSD Project X-Alternate-Addresses: , , , , X-Towel: Yes X-LiveJournal: flata, jmallett X-Negacore: Yes Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG * De: Maxime Henrion [ Data: 2002-11-22 ] [ Subjecte: Re: VM locking problem... And doscmd(8) ] > John Baldwin wrote: > > > > On 22-Nov-2002 Juli Mallett wrote: > > > * De: Robert Watson [ Data: 2002-11-21 ] > > > [ Subjecte: Re: VM locking problem... And doscmd(8) ] > > >> For those of us that don't frequently (ever) use doscmd -- can you provide > > >> a tarball of the necessary configuration files, executable, etc, > > >> somewhere? > > > > > > I don't (ever) either, and am doing this without a config file (as far as > > > I'm aware anyway), and using the following executable: > > > > > > http://people.freebsd.org/~jmallett/boom.exe > > > > There is some discussion on IRC, and Maxime is working on a fix. The > > problem is that if you use a TSS (for /dev/io or some such) then the > > TSS gets kmem_free()'d in cpu_thread_exit(). However, cpu_thread_exit() > > is a particularly bad time to be calling kmem_free() as you are holding > > sched_lock in a critical section w/o any sleep mutexes when it is called. > > :) The solution I've discussed with Maxime is to create a > > cpu_thread_dtor() callout called from thread_dtor() (which is called when > > a thread is free()'d) and to move the kmem_free() of the TSS into > > that function instead. > > The attached patch fixes it for me. It free()'s the TSS in the new > cpu_thread_dtor() function as John suggested. Works great, thanks! juli. -- Juli Mallett OpenDarwin, Mono, FreeBSD Developer. ircd-hybrid Developer, EFnet addict. FreeBSD on MIPS-Anything on FreeBSD. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message