From owner-freebsd-usb@FreeBSD.ORG Sat Apr 2 09:02:12 2005 Return-Path: Delivered-To: freebsd-usb@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1D00416A4CE for ; Sat, 2 Apr 2005 09:02:12 +0000 (GMT) Received: from md1.swissinfo.org (md1.swissinfo.org [146.159.4.92]) by mx1.FreeBSD.org (Postfix) with ESMTP id 656FD43D48 for ; Sat, 2 Apr 2005 09:02:11 +0000 (GMT) (envelope-from sebastien.b@swissinfo.org) Received: from mail.swissinfo.org ([194.6.181.33]) by md1.swissinfo.org (phad1.swissinfo.org [146.159.6.9]) (MDaemon.PRO.v7.2.1.R) with ESMTP id 42-md50000378823.msg for ; Sat, 02 Apr 2005 10:58:55 +0200 Received: from AAmiens-152-1-7-241.w83-192.abo.wanadoo.fr (83.192.68.241) by mail.swissinfo.org (7.0.020) (authenticated as sebastien.b) id 4153942002E02EC0; Sat, 2 Apr 2005 11:02:00 +0200 From: Sebastien B To: freebsd-usb@freebsd.org, hselasky@c2i.net Date: Sat, 2 Apr 2005 11:01:10 +0200 User-Agent: KMail/1.8 References: <6.2.1.2.0.20050329222822.04f7c500@64.7.153.2> <200504012144.11468.sebastien.b@swissinfo.org> <200504012317.54966.hselasky@c2i.net> In-Reply-To: <200504012317.54966.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200504021101.11602.sebastien.b@swissinfo.org> X-Spam-Processed: phad1.swissinfo.org, Sat, 02 Apr 2005 10:58:55 +0200 (not processed: message from valid local sender) X-MDRemoteIP: 194.6.181.33 X-Return-Path: sebastien.b@swissinfo.org X-MDaemon-Deliver-To: freebsd-usb@freebsd.org X-MDAV-Processed: phad1.swissinfo.org, Sat, 02 Apr 2005 10:59:01 +0200 Subject: Re: panic: uhci_abort_xfer: not in process context (was Re: uplcom / ucom problems on RELENG_5) X-BeenThere: freebsd-usb@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: FreeBSD support for USB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Apr 2005 09:02:12 -0000 > > The > > kernel panics with "ehci_abort_xfer: not in process context" a few while > > after the transfer. Is it the same problem ? Is a software interrupt > > handler unsuitable for the abort xfer function ? How can I fix it, by > > using a task queue instead of a software interrupt handler ? > > Regards, > > Sebastien > > With the existing USB driver you cannot call usbd_abort_pipe() nor > usbd_bulk_transfer(), from an interrupt context or callback, because those > functions will sleep. Does a software interrupt handler run in interrupt context ? And what about task queue threads ? Anyway, it doesn't crash while my software interrupt handler is running, but later in the "usbtask" thread. > You can call usbd_transfer(), if the transfer is not > synchronous. But it is. To send network packets, I must perform two USB transfers on two different endpoints, and I must wait for the first one to complete before initiating the second.