From owner-svn-src-head@FreeBSD.ORG Mon Aug 29 14:57:00 2011 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 06004106566C; Mon, 29 Aug 2011 14:57:00 +0000 (UTC) (envelope-from hselasky@freebsd.org) Received: from swip.net (mailfe01.c2i.net [212.247.154.2]) by mx1.freebsd.org (Postfix) with ESMTP id E4E5F8FC08; Mon, 29 Aug 2011 14:56:58 +0000 (UTC) X-Cloudmark-Score: 0.000000 [] X-Cloudmark-Analysis: v=1.1 cv=wJvnH89EauZH5CtPccDXCoR3S15XcsUHhRLViNeYhtc= c=1 sm=1 a=SvYTsOw2Z4kA:10 a=Bjjt3Ia5OwMA:10 a=dBRESv0yCI8A:10 a=N659UExz7-8A:10 a=CL8lFSKtTFcA:10 a=i9M/sDlu2rpZ9XS819oYzg==:17 a=D77xU_VBKiNl670GMyQA:9 a=pILNOxqGKmIA:10 a=i9M/sDlu2rpZ9XS819oYzg==:117 Received: from [188.126.198.129] (account mc467741@c2i.net HELO laptop002.hselasky.homeunix.org) by mailfe01.swip.net (CommuniGate Pro SMTP 5.2.19) with ESMTPA id 172968065; Mon, 29 Aug 2011 16:56:56 +0200 Received-SPF: softfail receiver=mailfe01.swip.net; client-ip=188.126.198.129; envelope-from=hselasky@freebsd.org From: Hans Petter Selasky To: Andriy Gapon Date: Mon, 29 Aug 2011 16:54:22 +0200 User-Agent: KMail/1.13.5 (FreeBSD/8.2-STABLE; KDE/4.4.5; amd64; ; ) References: <201108291627.42477.hselasky@freebsd.org> <4E5BA31C.7070103@FreeBSD.org> In-Reply-To: <4E5BA31C.7070103@FreeBSD.org> X-Face: *nPdTl_}RuAI6^PVpA02T?$%Xa^>@hE0uyUIoiha$pC:9TVgl.Oq, NwSZ4V"|LR.+tj}g5 %V,x^qOs~mnU3]Gn; cQLv&.N>TrxmSFf+p6(30a/{)KUU!s}w\IhQBj}[g}bj0I3^glmC( :AuzV9:.hESm-x4h240C`9=w MIME-Version: 1.0 Content-Type: Text/Plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Message-Id: <201108291654.23054.hselasky@freebsd.org> Cc: "svn-src-head@FreeBSD.org" , "svn-src-all@FreeBSD.org" , "src-committers@FreeBSD.org" Subject: Re: svn commit: r223989 - head/sys/dev/usb/input X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 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: Mon, 29 Aug 2011 14:57:00 -0000 On Monday 29 August 2011 16:33:00 Andriy Gapon wrote: > Not sure if this answers my question, which is not about pause vs > ukbd_yield, but is about ukbd_yield vs kern_yield. > In other words, why you couldn't simply use kern_yield where you used > ukbd_yield? Is this a new function. I think I used the following as an example: void uio_yield(void) { struct thread *td; td = curthread; DROP_GIANT(); thread_lock(td); sched_prio(td, td->td_user_pri); mi_switch(SW_INVOL | SWT_RELINQUISH, NULL); thread_unlock(td); PICKUP_GIANT(); } As long as the kern_yield() lets the USB worker threads and XHCI interrupts run it should be fine. pause() is better though. --HPS